Given the absence of a vertical TabLayoutPanel in GWT, I was trying to
patch the TabLayoutPanel code in my local space by copying the
TabLayoutPanel source code and modifying it. However, when I use
UiBinder to construct my UI, I run into a problem that makes me wonder
how UiBinder works behind the scene.
First I have my locally modified TabLayoutPanel class, which I name it
"MyTabLayoutPanel".
Then I use it in a UiBinder template like this:
...
<g:MyTabLayoutPanel barUnit='PX' barHeight='35' ....>
<g:tab>
<g:header size='7'>ABC</g:header>
<g:Label>This is a test</g:Label>
</g:tab>
...
</g:MyTabLayoutPanel>
When running the program, I ran into the following issues:
- "Class MyTabLayoutPanel has no appropriate setBarUnit method... "
- "tab" not found, obviously UiBinder doesn't recognize the "<g:tab>"
thing
If I switch "MyTabLayoutPanel" back to the standard "TabLayoutPanel",
everything works. In fact, to trouble-shoot my problem, I merely copy
the original GWT TabLayoutPanel to my app code space and rename it
"MyTabLayoutPanel" without any other modification.
When I look at TabLayoutPanel code, I notice the constructor takes a
"barUnit" and a "barHeight" as arguments. I wonder why widgets in
GWT's own SDK do not need to follow the rule of providing an empty
constructor or using things like "@UiConstructor". Also, if I want to
natively write my own widget to support things like "<g:tab>",
"<g:cell>" etc in UiBinder, how should I do it?
Any advices would be highly appreciated.
--
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.