[whatwg] pagehide vs pagevis
beidson at apple.com
Thu May 30 11:26:07 PDT 2013
On May 30, 2013, at 10:38 AM, Boris Zbarsky <bzbarsky at mit.edu> wrote:
> On 5/30/13 1:04 PM, Brady Eidson wrote:
>> The long standing design goals and implementation of our page cache
>> prevents us from delivering these events to a page that was just sent
>> “pagehide with persisted set to true”.
> Actually, let me try to clarify this a bit.
> The way I would imagine logic like this being implemented is something like:
> with the flagPageFrozen() call making it so that further event dispatch is impossible.
> If that is in fact the case, then logic like this:
> setVisibility("hidden"); // happens to fire an event
> should generally work fine; this is in fact more or less what Gecko does, if we ignore the "pagehide makes the page not cacheable" complication.
> So how does your setup differ in a way that actually makes this impossible to implement?
The design is that after pagehide returns, if the traversal is still taking place and the page is going into the cache, no further events take place.
More information about the whatwg