Re: UiBinder custom panel

2011-08-29 Thread Kurtt
Oh, brilliant. GWT should really develop an UiChild version what can
directly associate to a method like addWidgetToColomn( Widget w, int
i).
Thank you ~
:)

On Aug 28, 5:22 pm, Thomas Broyer t.bro...@gmail.com wrote:
 Yes, simply annotate a method with 
 @UiChildhttp://google-web-toolkit.googlecode.com/svn/javadoc/latest/com/googl
 In your case though, you'd have to have one method per tag name:

 @UiChild(tagname=column_1)
 void addWidthToFirstColumn(Widget w) { addWidgetToColumn(w, 0); }

 @UiChild(tagname=column_2)
 void addWidthToSecondColumn(Widget w) { addWidgetToColumn(w, 1); }

 and so on.

-- 
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-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.



Re: UiBinder custom panel

2011-08-28 Thread Thomas Broyer
Yes, simply annotate a method with 
@UiChildhttp://google-web-toolkit.googlecode.com/svn/javadoc/latest/com/google/gwt/uibinder/client/UiChild.html.
 
In your case though, you'd have to have one method per tag name:

@UiChild(tagname=column_1)
void addWidthToFirstColumn(Widget w) { addWidgetToColumn(w, 0); }

@UiChild(tagname=column_2)
void addWidthToSecondColumn(Widget w) { addWidgetToColumn(w, 1); }

and so on.

-- 
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/-/Hy41rj-75xcJ.
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.



UiBinder custom panel

2011-08-27 Thread Kurtt
Hi, all,

is it possible to create a custom panel, and use it just like the
usage of g:west:

my:MyPanel
 my:colomn_1
 g:Button/
 /my:colomn_1
 my:colomn_2
 g:Button/
 /my:colomn_2
/my:MyPanel

where my:colomn_1 is encountered , i want GWT to call
myPanel.addWidgetToColomn( Widget w, int i) method.

-- 
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-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.



Re: UiBinder custom panel

2010-02-17 Thread Thomas Broyer


On Feb 16, 11:24 am, Krzysztof Rosiński rose...@gmail.com wrote:
 Hi,

 is it possible to create custom panel like this:
 ControlPanel.ui.xml
         g:HTMLPanel
                 g:VerticalPanel styleName='{html.panel}'
                         g:HorizontalPanel
                                 g:Button ui:field='btnHide' 
 styleName='{button}' text='Hide'/
 g:Button
                                 g:Button ui:field='btnClose' 
 styleName='{button}' text='Close'/
 g:Button
                         /g:HorizontalPanel

                         g:ScrollPanel ui:field=panel width='100%'
                                 !-- add components here --
                         /g:ScrollPanel
                 /g:VerticalPanel
         /g:HTMLPanel

 and then use it in this way:
 Something.ui.xml
         g:HTMLPanel
                 c:ControlPanel ui:field='panel'
                         g:FlexTable ui:field='ftLogs' styleName='{table}'/
                 /c:ControlPanel
         /g:HTMLPanel

Yes (theoretically, I haven't tested).

Your ControlPanel has to implement HasWidgets (to probably delegate it
to the ScrollPanel).

Just beware that in this case, the FlexTable's parent
(ftLogs.getParent()) will be the ScrollPanel, not the ControlPanel.

-- 
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 custom panel

2010-02-17 Thread Krzysztof Rosiński
Thanks for the hint, it works as you said.


On 17 Lut, 11:56, Thomas Broyer t.bro...@gmail.com wrote:
 On Feb 16, 11:24 am, Krzysztof Rosiñski rose...@gmail.com wrote:





  Hi,

  is it possible to create custom panel like this:
  ControlPanel.ui.xml
          g:HTMLPanel
                  g:VerticalPanel styleName='{html.panel}'
                          g:HorizontalPanel
                                  g:Button ui:field='btnHide' 
  styleName='{button}' text='Hide'/
  g:Button
                                  g:Button ui:field='btnClose' 
  styleName='{button}' text='Close'/
  g:Button
                          /g:HorizontalPanel

                          g:ScrollPanel ui:field=panel width='100%'
                                  !-- add components here --
                          /g:ScrollPanel
                  /g:VerticalPanel
          /g:HTMLPanel

  and then use it in this way:
  Something.ui.xml
          g:HTMLPanel
                  c:ControlPanel ui:field='panel'
                          g:FlexTable ui:field='ftLogs' styleName='{table}'/
                  /c:ControlPanel
          /g:HTMLPanel

 Yes (theoretically, I haven't tested).

 Your ControlPanel has to implement HasWidgets (to probably delegate it
 to the ScrollPanel).

 Just beware that in this case, the FlexTable's parent
 (ftLogs.getParent()) will be the ScrollPanel, not the ControlPanel.

-- 
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.



UiBinder custom panel

2010-02-16 Thread Krzysztof Rosiński
Hi,

is it possible to create custom panel like this:
ControlPanel.ui.xml
g:HTMLPanel
g:VerticalPanel styleName='{html.panel}'
g:HorizontalPanel
g:Button ui:field='btnHide' 
styleName='{button}' text='Hide'/
g:Button
g:Button ui:field='btnClose' 
styleName='{button}' text='Close'/
g:Button
/g:HorizontalPanel

g:ScrollPanel ui:field=panel width='100%'
!-- add components here --
/g:ScrollPanel
/g:VerticalPanel
/g:HTMLPanel

and then use it in this way:
Something.ui.xml
g:HTMLPanel
c:ControlPanel ui:field='panel'
g:FlexTable ui:field='ftLogs' styleName='{table}'/
/c:ControlPanel
/g:HTMLPanel

BR,
Krzysiek

-- 
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.