Presenter vs. PresenterWidget

206 views
Skip to first unread message

SteffiM

unread,
May 1, 2015, 8:54:10 AM5/1/15
to gwt-pl...@googlegroups.com
Is there a logical difference between a Presenter which has no place, i.e., has only a Proxy instead of a ProxyPlace and a PresenterWidget?

Richard Wallis

unread,
May 1, 2015, 9:02:15 AM5/1/15
to gwt-pl...@googlegroups.com
The only real difference is that a Presenter has a Proxy but a PresenterWidget doesn't.

But that's quite a big difference, since proxies allow codesplitting / proxyevents & gatekeepers.

Also you can use a Presenter with @ContentSlots or NestedSlot if you're using gwtp 1.5 snapshot.

On Fri, May 1, 2015 at 2:54 PM, SteffiM <dr.steff...@gmail.com> wrote:
Is there a logical difference between a Presenter which has no place, i.e., has only a Proxy instead of a ProxyPlace and a PresenterWidget?

--
You received this message because you are subscribed to the Google Groups "GWTP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gwt-platform...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Clay Harris

unread,
May 1, 2015, 9:07:33 AM5/1/15
to gwt-pl...@googlegroups.com
If I recall correctly, Presenters are inherently Singletons, whereas for PresenterWidgets, that is optional. 

SteffiM

unread,
May 1, 2015, 9:12:55 AM5/1/15
to gwt-pl...@googlegroups.com
Well apart from the Singleton difference. Is there any reason to use the one or the other?

SteffiM

unread,
May 1, 2015, 9:18:48 AM5/1/15
to gwt-pl...@googlegroups.com
@Richard What are NestedSlots?

Clay Harris

unread,
May 1, 2015, 9:23:56 AM5/1/15
to gwt-pl...@googlegroups.com
This may reflect my usage more than anything, but as I see it Presenters are for layout and page objects, whereas PresenterWidgets are so that you can have MVP widgets (eg you could have one per twitter post, with all the logic inherent for each in the PresenterWidget, with a dozen of them on a page).  

Richard Wallis

unread,
May 1, 2015, 9:32:22 AM5/1/15
to gwt-pl...@googlegroups.com
Nested Slots are an upcoming feature in Snapshot.

They replace the old @ContentSlot slots and are a bit simpler.  You can see how to use all the new slot types in with my first 3 comments at this PR: https://github.com/ArcBees/GWTP/pull/672

Christian Goudreau

unread,
May 1, 2015, 12:06:46 PM5/1/15
to gwt-pl...@googlegroups.com
Richard, it would really be awesome to have some documentation about that. Christopher is planning to release 1.5 end of may beginning of June and we started to rework all the documentation. I feel that this part will be left over if you don't lead a bit the documentation about the changes you introduced.

Christian Goudreau | CEO - Président

Richard Wallis

unread,
May 1, 2015, 12:28:25 PM5/1/15
to gwt-pl...@googlegroups.com
Ok will do.  Can you enable issues on the dev-site project?

Christian Goudreau

unread,
May 1, 2015, 12:34:02 PM5/1/15
to gwt-pl...@googlegroups.com
Done

Christian Goudreau | CEO - Président

Drew Spencer

unread,
Jun 3, 2015, 7:02:46 AM6/3/15
to gwt-pl...@googlegroups.com
Pretty excited about this upcoming slots feature, I have to say. setInSlot() was always a little horrible to maintain so looking forward to cleaner code :)

Quick question guys: should I use able to use the current 1.4 release with the gwt 2.8.0-SNAPSHOT? I tried it the other day but got a whole host of errors but wasn't sure what was causing them.

Might give 1.5-SNAPSHOT a go later this week if I have time.
Reply all
Reply to author
Forward
0 new messages