Seth_G
29 Nov 2008, 10:31 AM
Hi there - I am extending the functionality of the Portal class inside of GXT . . . and want to add a Save/Restore button.
I know that there's the singleton StateManager which collects state information, but it seems to not work with the Portal or anything that I try.
Here's an example of what I'm trying to do: (I have the following menu item in the north section of a border layout, where the center is a Portal object containing a bunch of widgets. The following lines of code are placed in the class that sets up the menu and does all of the layout of the objects.)
menuItem = new MenuItem("Save", new SelectionListener<MenuEvent>() {
@Override
public void componentSelected(MenuEvent ce) {
componentPanel.saveState();
}
});
I know I'm doing something wrong, but I'm not really sure how to go about saving and restoring states . . . and there's not much on this topic for GXT.
I know that there's the singleton StateManager which collects state information, but it seems to not work with the Portal or anything that I try.
Here's an example of what I'm trying to do: (I have the following menu item in the north section of a border layout, where the center is a Portal object containing a bunch of widgets. The following lines of code are placed in the class that sets up the menu and does all of the layout of the objects.)
menuItem = new MenuItem("Save", new SelectionListener<MenuEvent>() {
@Override
public void componentSelected(MenuEvent ce) {
componentPanel.saveState();
}
});
I know I'm doing something wrong, but I'm not really sure how to go about saving and restoring states . . . and there's not much on this topic for GXT.