Hi,
I am beginning to work on a big app created in GWT and I have a
question regarding the MVP pattern in GWT.

I have read http://code.google.com/webtoolkit/articles/mvp-architecture.html,
and I understand that the AppController creates Presenters, and
provides them a rpcService, an eventBus, and a view.

This makes it easy (among other things) to target mobile phones or
desktop computers by submitting different views to the Presenters

However, if one of the Presenter creates some widget, also programmed
in a VP fashion, it will be the Presenter's responsibility to
instantiate the view for the widget :-(
How can I make it so the Presenter knows what kind of view (mobile
phone/desktop) it has to create?

Should I submit to all my Presenters a Factory with the methods
newViewForWidgetA(), newViewForWidgetB(), etc... ? Or maybe I
completely misunderstood everything from the start, in which case
please explain me if you have time :-)

Thanks in advance.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to