On Tuesday, October 25, 2011 10:33:55 PM UTC+2, Cristian Rinaldi wrote:
>
> Thomas, thanks for the fast responce. I will see if this is causing the 
> error.
>  
> AddressWidget implements AddressView and Editor for AddressProxy, you say 
> that the AddressView must be extend Editor?
>

I'm saying that the type of the "address" field in type TerceroEditor does 
not implement Editor (or IsEditor), so the Editor framework does not treat 
it as an editor. You'll either have to change it to AddressWidget, or make 
AddressView extend Editor.

Now, one design question. 
>
> I love MVP, this pattern is very powerfull but, with Activities and Place 
> some thing are dificult.
>
> Activities are for when you need navigation, but if want each view has a 
> Presenter, I thought the following:
>   
>    One interface Presenter for each View, where "View" delegate the logic 
> in the presenter implementation.
>    Now, presenter is not Activity. When I need navigation, I make a 
> Activity that inject the presenter and delegate in this the logic of View.
>
>    I want keep separate in the best forms the concepts of view and 
> presenter, but I want to know if inject the presenter in view is ok.
>   The presenter have a method called onCreate(T) where T is a View. That 
> method is called when View is initialized after make UiBinder interface.
>   In the onCreate(T) I inicialize the editor driver, etc.
>
>   When I precise a Activity, in the start method I obtain the view, by 
> example, with AsyncProvider, how the View inject Presenter, the Activity 
> delegate logic to Presenter.
>
>  I started think this for nested complex widget, for example, load 
> Employees associated with bank accounts, where the Widgets for list of 
> selection and creation bank account is a widget that delegate logic in a 
> presenter that is not Activity.
>  But, i can use this widget alone in other view where is necesary one 
> Activity.
>
>   All this is fine or I've gone crazy?
>

I'm not sure I understood what you're coming with. All I can say is that my 
activities are presenters, and in a few cases where a complex "component" 
is to be reused, I have a presenter and view for it that's not an activity. 
I also inject my views within my presenters in their constructors, and the 
presenters "inject themselves" into their view when needed (when the 
activity starts, in my case); this allows the views to have longer lifetime 
as the presenters, because I use short-lived presenters and singleton views.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-web-toolkit/-/bmgNK-epWLoJ.
To post to this group, send email to google-web-toolkit@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to