In special cases (where just the url of the page can not determine state - because of some internal in-page dynamic functionality), We need to implement the history handling for ourselves.
Setting History tokens – Whenever the user takes an action that changes the “screen” in a way that you want to save, you should store a token
History.newItem("someLinkTarget", false);
- Responding to History tokens
Whenever the URL ends in #someToken, that token is passed to the onValueChange
method of the History’s ValueChangeHandler
public void onValueChange (ValueChangeEvent<String> event) {
String linkTarget = event.getValue();
if (checkForYourSavedToken(linkTarget)) {
... your code displays your expected results;
} else { … }
This knowledge is from GWT
reading though, I did not test this at its core. Please ignore if this does not help you anyway. (Also please find w3schools which suggests that There is no public standard that applies to the history object, but all major browsers support it.