Check out this documentation on history. http://code.google.com/webtoolkit/articles/mvp-architecture.html#history
You want to set the 'state' of you application with your URL. You append to the URL some data such as page to display and state of the page and then call a method that will read the URL and display the correct page with the correct state. In this way you can copy and paste the URL into a different browser and it will show the current page and state (bookmarked). Also make the method choose a default page if no URL info has been appended. http://myapp.com AppController called AppController checks the URL has no appended so appends "#home" AppContoller calls fireCurrentHistoryState fireCurrentHistoryState sees #home so displays home page user clicks on setup link (use Hyperlink with "setup" as target history token) fireCurrentHistoryState sees #home so displays setup page If someone bookmarks the setup page the AppController will call fireCurrentHistoryState on load and display the setup page. On Sep 13, 11:40 am, Bill Morrison <[email protected]> wrote: > This is in response to the user pressing a 'Bookmark' button on the > page of course. > > I'll dig into the Javascript side, thanks for the hint. If anyone has > any JSNI that shows this I'd love to not reinvent the wheel! > > On Sep 13, 9:37 am, Jens <[email protected]> wrote: > > > > > > > > > You should let the user decide to bookmark a page or not. > > > In general you have to use GWT's JSNI feature and wrap some native > > JavaScript to add a bookmark. As far as I know, Chrome and Opera do not > > support adding bookmarks via JavaScript. > > > -- J. -- 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.
