I'm trying to wrap my head around the way History Management works.
I've taken the KitchenSink apart and I see how it's done, but my
application will be considerably more complex than that example - I
have multiple levels of pages.
Does anyone have an established model for a sensible way of managing
pages and history? There are more than a couple of requests for this on
the forum.
I've tried to look at GWT's Mail application, but I see nothing
regarding history management (contrary to it's page in the 'sample
projects' section of the website).
My current thinking is this:
Build a HistoryManager class that implements HistoryListener. The
HistoryManager class takes whatever is in the URL after the #, and
splits it into an array of different parameters, and then applies some
huge heirarchical function to it. So for example:
myURL#section=no1;page=page3;display=thing1,thing2,thing3,thing4
Would kick the HistoryManager into 'section 1' mode, make it display
page 3, containing things1 through 4.
I'm using the same 'lazy construction' of widgets as used in
KitchenSink, so the HistoryManager class would need to instantiate
whichever widgets were specified by the url, and then configure them
appropriately.
I think this could get quite complex. Can anyone suggest a better way
of doing things?