[Bug 9560] [history] The line game example doesn't work properly

http://www.w3.org/Bugs/Public/show_bug.cgi?id=9560


HE Shi-Jun <johnhax@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |johnhax@gmail.com




--- Comment #1 from HE Shi-Jun <johnhax@gmail.com>  2010-05-28 08:33:54 ---
As my understandings of the intention of pushState/popstate and the
descriptions in the Mozilla site
(https://developer.mozilla.org/en/DOM/Manipulating_the_browser_history#State_information_for_history_entries),
this line of code seems broken:

function go(d) {
   history.pushState(currentPage, 'Line Game - ' + currentPage, '?x=' +
currentPage);
   setupPage(currentPage + d);
}


It should be:

function go(d) {
   setupPage(currentPage + d);
   history.pushState(currentPage, 'Line Game - ' + currentPage, '?x=' +
currentPage);
}

-- 
Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.

Received on Friday, 28 May 2010 08:33:56 UTC