panel.add(widget,2,2);
Shape shapeWrapper = new Shape(widget);
shapeWrapper.showOnDiagram(diagram);
At some point in my app I will need to access that widget again to
change some of its properties. However it no longer is part of my
panel, but rather a shape on the diagram now. How can I get at the
widget to update it?
thanks
panel.add(widget,2,2);
Window.alert(panel.getWidgetIndex(widget)+"");
Shape shapeWrapper = new Shape(widget);
shapeWrapper.showOnDiagram(diagram);
Window.alert(panel.getWidgetIndex(widget)+"");
The first alert will return a valid index and the second alert returns
-1. So at some point the widget gets removed from panel and placed
somewhere else. Saying that, how can I get access to the widget after.
thanks
final AbsolutePanel boundaryPanel = new AbsolutePanel();
boundaryPanel.getWidget(windowPanel1);
I know I can click ont the retrieved widget and remove it with that
function
shape.showOnDiagram(diagram);
connectionPointsPanel.add(widget, CP_MARGIN, CP_MARGIN);
This line of code adds the widget to another panel in this Shape class
and also removes it from its parent panel (my panel). Thats why I
couldnt access it.