I have the following situation:
class WidgetA extends Composite {
public WidgetA() {
initWidget(new VerticalPanel());
}
public void add(Widget w) {
((VerticalPanel) getWidget()).add(w);
}
}
And somewhere else I make a call like:
WidgetA a = new WidgetA();
WidgetB b = new WidgetB();
a.add(b);
Later on I need to get the WidgetA object that WidgetB belongs to (was
added to), so naturally I think to call b.getParent(). However, this
will return a VerticalPanel.
I can't come up with a good generic way of being able to return the
corresponding WidgetA object for any Widget that may be added to it
(not just type WidgetB). Any suggestions?
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---