Re: UIBinder with code in earlier versions of GWT
Can you please direct me to any such tutorial and or blog regarding this. Or may be a list of things that I should take care while migrating to declarative UI with the programatic UI from the earlier version of GWT2.0 Suppose MyWidget class is in package com.old.uiuibinder template for WidgetContainer can look like this !DOCTYPE ui:UiBinder SYSTEM http://dl.google.com/gwt/DTD/xhtml.ent; ui:UiBinder xmlns:ui=urn:ui:com.google.gwt.uibinder xmlns:g=urn:import:com.google.gwt.user.client.ui xmlns:oldWidgets=urn:import:com.old.ui g:HTMLPanel h1WidgetContainer/h1 divbla bla /div divoldWidgets:MyWidget ui:field=widgetContainerFieldNameForOldWidget someOldWidgetProperty=haha //div /g:HTMLPanel /ui:UiBinder Notice xml namespace declaration: xmlns:oldWidgets=urn:import:com.old.ui Important things to remember: - MyWidget class must be accessible from WidgetContainer class so must have public or be in the same package and has default access. - In this example MyWidget has setter:public void setSomeOldWidgetProperty(String v) - MyWidget must have accessible noargs contructors or you have to create factory method annotated with @UIFactory in WidgetContainer or add provided=true @UiField(provided=true) MyWidget widgetContainerFieldNameForOldWidget ; and create instance of MyWidget in WidgetContainer All informations you can found here: http://code.google.com/intl/pl/webtoolkit/doc/latest/DevGuideUiBinder.html#Using_a_widget -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@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.
Re: UIBinder with code in earlier versions of GWT
On 13 Kwi, 15:30, San sandip.pati...@gmail.com wrote: Hi all, Can I use some of the widgets those are written in earlier versions of GWT2.0 directly in UIBinder classes. e.g.can I do something like suppose I am having MyWidget as a old class and I develop a new class as WidgetContainer with UIBinder and try to add MyWidget directly to WidgetContainer's ui.xml file without having ui.xml file for MyWidget? Yes. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@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.
Re: UIBinder with code in earlier versions of GWT
Hi, Thanks a lot for your reply? Can you please direct me to any such tutorial and or blog regarding this. Or may be a list of things that I should take care while migrating to declarative UI with the programatic UI from the earlier version of GWT2.0 -Thanks On Apr 14, 12:27 pm, MiSt m...@mist.pl wrote: On 13 Kwi, 15:30, San sandip.pati...@gmail.com wrote: Hi all, Can I use some of the widgets those are written in earlier versions of GWT2.0 directly in UIBinder classes. e.g.can I do something like suppose I am having MyWidget as a old class and I develop a new class as WidgetContainer with UIBinder and try to add MyWidget directly to WidgetContainer's ui.xml file without having ui.xml file for MyWidget? Yes. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-tool...@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.