google-code-export / mvp4g

Automatically exported from code.google.com/p/mvp4g
1 stars 0 forks source link

Splitter, ReverseResizeComposite, and LazyPresenter/View NullPointer #124

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
When using a Mvp4gSplitter and the ReverseResizeComposite, the 
ReverseResizeComposite doesn't have its Presenter injected.  So, caling 
getPresenter() results in a NullPointer exception.  

Can this be added to the framework somehow?

It looks like the presenters are injected when the module is started.  However, 
with the splitter, this is not done.  

What steps will reproduce the problem?
1. create a presenter/view using ReverseResizeComposite and LazyPresenter/View
2. add the above to a separate splitter
3. call getPresenter in some clickHandler in the view.  Get a NullPointer

What is the expected output? What do you see instead?
Expected the ReverseResizeComposite.presenter to be populated by the framework. 

What version of the product are you using? On what operating system?
mvp4g 1.4 with gwt2.5

Work Around...
I call view.setPresenter(this) manually in bindView();

Please provide any additional information below.

Original issue reported on code.google.com by mbaker.t...@gmail.com on 28 Feb 2013 at 4:56

GoogleCodeExporter commented 9 years ago
oops... ReverseResizeComposite  is one of my own classes 

public class ReverseResizeComposite<T> extends ResizeComposite implements 
ReverseViewInterface<T> {....

Original comment by mbaker.t...@gmail.com on 28 Feb 2013 at 6:33

GoogleCodeExporter commented 9 years ago
I believe this was fixed at the same time as issue 115. Can you try with the 
[https://code.google.com/p/mvp4g/source/browse/maven2/snapshots/com/googlecode/m
vp4g/mvp4g/1.5.0-SNAPSHOT/mvp4g-1.5.0-20121019.011853-3.jar latest 1.5.0 
SNAPSHOT jar] and let me know if you still have the issue.

Thanks  

Original comment by plcoir...@google.com on 28 Feb 2013 at 7:12

GoogleCodeExporter commented 9 years ago
I downloaded the jar and recompiled, but still receive the NullPointer from 
LazyPresenters/Views that have been downloaded via the Splitter.  Maybe I 
should also mention that these are in a child module to our main module.  I 
believe that some "magic" that happens when the module loads isn't happening 
for LazyPresenters when the split code is downloaded and loads.  

Thx,
m

Original comment by mbaker.t...@gmail.com on 28 Feb 2013 at 8:08

GoogleCodeExporter commented 9 years ago
I could reproduce the bug with mvp4g-1.5.0-SNAPSHOT if a lazy presenter is 
used. I'll look into it.

Original comment by plcoir...@google.com on 1 Mar 2013 at 2:39

GoogleCodeExporter commented 9 years ago

Original comment by frank.hossfeld on 16 Apr 2014 at 1:37