On 29 mar, 18:34, Ian Bambury <[email protected]> wrote:
> Hi Thomas,
>
> This doesn't overwrite the existing history entry (http://mydomain.com/) it
> just adds another entry with a bookmark. I'm trying not to have two entries
> added when a user first goes to my site because the back button will take
> them to http://mydomain.com and that will immediately take them back to 
> http://mydomain.com#Home (or whatever the default bookmark happens to be).

I understood your use case. My code snippet was about treating
http://example.com/ and http://example.com/#Home the same; i.e. do
*not* use History.newItem("Home") when History.getToken() is the empty
string but rather *behave* as if it were "Home".

...but because you cannot use History.newItem("") reliably to return
back to your "home", you cannot just use the empty-string token and
still have to use a "Home" token; so: when you get the empty string,
behave as if it is "Home", and when navigating, use History.newItem
("Home").

Am I clearer?


--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to