tags:

views:

127

answers:

1

Hi all,

i am implementing my first GWT application currently, i just have a quick question about the differences between Extends Composite and Extend a specified widget when creating complex custom widgets, and the advantages of using "extends Composite".

Also, is it true that the widget created by extending Composite can be loaded faster that extending a real widget, and which of them has lighter weight?

Thanks,

+2  A: 

Widget Best Practices / Widget Building - this should get you started :)

As for the second part of your question - in most cases, your custom made, optimized for particular purpose Widget should be more lightweight than one of the ones provided by GWT (because they have to be more robust, etc). That being said, the widgets provided by GWT are quite lightweight IMHO (this is part of the whole concept of GWT - they give just the small/simple, but well built blocks to build your own application/framework).

One other thing worth noting is that the widgets provided by GWT sometimes have special implementation for a particular, ill-behaving browser (*cough*IE*cough*) - but that's not something you should be worrying about most of the time, since you should be building your Widgets one "level" higher (that is, your widgets should contain widgets provided by GWT), so that you won't have to deal with those incompatibilities between browsers.

Igor Klimer
Very good, Thanks!!!