Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Where is more Documentation on History (synthetic history) creation

    I have only found some brief links in the forums about issues using history, this brief link referring to using history

    http://stackoverflow.com/questions/5...rowser-history

    and brief coverage of a few methods in http://www.smartclient.com/docs/7.0r...rowser-history.

    Please, be so kind as to direct me to a guide or example in a showcase of how to set up synthetic history to use browser forward and back buttons. Extensive searches provided me with nothing so far. Thank you!!!

    I am using SmartGwt Pro 2.5 and our data is serialized.

    #2
    AFAIK, history in SmartGWT is the same as it is in any other GWT app. The stackoverflow responses seem to point you in the right direction.

    IIRC, the showcase itself uses the GWT history mechanism. Check out it's source in the SmartGWT sdk.

    Comment


      #3
      bbruyn is correct - you can use the GWT history mechanism and there's nothing specific to SmartGWT here, except to say, we see some people try to capture the *entire application state* (eg down to which tab was selected and where keyboard focus is) in the URL - that's very complicated and not especially valuable to users, in fact it can be more information than they intended to share when they send around a URL.

      It's more than enough to do capture information at the level of what record is being viewed or edited on what screen, and only for selected screens where users are likely to want to share URLs.

      Comment


        #4
        Thank you for pointing me in the right direction. I must admit that I still have many questions about how to register pages and various datasource so that a specific page is properly connected to a widget in a page. Does saving created history for the page save all the widgets? How do I associated the datasource and the page?

        Comment


          #5
          Sounds like you just need to spend some more time with GWT's docs on this. GWT's History API does not know about DataSources - it just saves whatever you choose to save, and gives it back to you when the user arrives at the bookmarked page. From this simple mechanism, you need to add logic that will allow you to navigate your application to the right place.

          Comment


            #6
            Thank you for you earlier response. I have found documentation here:
            http://code.google.com/webtoolkit/do...csHistory.html

            HTML widgets (com.google.gwt.user.client.ui.Hyperlink) are recommended for saving internal application states in the history token. Will this work? I have always read that mixing GWT widgets in smartgwt apps is a bad idea.

            Comment


              #7
              I have recently downloaded SmartGWT Pro 2.5 and I was suprized to find the signature for the EE Showcase using the depreciated HistoryListener:

              public class Showcase implements EntryPoint, HistoryListener {

              This was depreciated in GWT Version 1.6. Currently the ValueChangeHandler Class is used for History event creation control. Is there a reason for using the depreciated HistoryListener Class? Is ValueChangeHandler supported in SmartGWT?

              Comment


                #8
                The GWT documentation that I could find was not clear enough for me:
                http://code.google.com/webtoolkit/doc/latest/DevGuideCodingBasicsHistory.html

                but this example at BlueCoders was very straightforward and answered my questions so that I could implement it:
                http://www.bluecoders.com/tutorials/gwthistory2.html

                Comment

                Working...
                X