On Thu, Apr 19, 2012 at 22:33, Boris Zbarsky <bzbarsky@mit.edu> wrote: > On 4/20/12 1:26 AM, Sreeram Ramachandran wrote: >> >> Right, but this is for an iframe. Sorry, I should've been clearer that >> I was asking about top level documents. > > It should work the same exact way for toplevel documents. Certainly does in > Gecko. > >> contrast, a top-level document that is navigated away from does have >> its visibilitystate changed, but I haven't been able to find a way to >> script it. > > Just do the same exact thing as my testcase, but use window.open() to get > the window, instead of an iframe's contentWindow. And make sure to wait for > that window to load. I've tried, and it doesn't work. See the attached test page (pagecache-test.html). Here's what happens: 1. In Page A (pagecache-test.html), I open a new window to Page B (another copy of pagecache-test.html), by clicking on "newwin". I confirm that I can observe Page B by clicking "checkwin" on Page A. 2. In Page B, I navigate to a different page, by clicking on "same origin". Call this Page C. 3. In Page A, I click "checkwin", but I no longer see the frozen document (B). Instead, I see C. 4. Okay, maybe the "window" object is live-updating. How about if I "store" the document object after step 1 (and before step 2) and then try to use it after step 2? Nope. "checkdoc" shows me C too. I've tried the above on both Firefox and Safari. Is there another way to put a page into the pagecache instead of through regular (or back/forward) navigations?
This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 23 April 2012 16:12:41 GMT