W3C home > Mailing lists > Public > public-webapps@w3.org > January to March 2012

Re: Selection of a document that doesn't have a window

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Fri, 13 Jan 2012 12:34:59 -0500
Message-ID: <4F106B43.9030205@mit.edu>
To: Aryeh Gregor <ayg@aryeh.name>
CC: Ojan Vafai <ojan@chromium.org>, Simon Pieters <simonp@opera.com>, Ryosuke Niwa <rniwa@webkit.org>, Ehsan Akhgari <ehsan@mozilla.com>, Stig Halvorsen <stighal@opera.com>, W3C WebApps WG <public-webapps@w3.org>
On 1/13/12 12:18 PM, Aryeh Gregor wrote:
> Actually, defaultView is defined to return the Document's browsing
> context's WindowProxy object, if it has one, and null otherwise.

Hmm.  I guess the spec doesn't really define what happens to the 
association between a document and its browsing context in the 
interesting cases (window close, navigation away from document, removal 
of an iframe from the DOM, etc).  In practice, UAs are all over the map 
in terms of nulling out defaultView for some but not others of the above.

> For now I'm inclined to go with defaultView being null, just because
> that's at least readily testable.  If defaultView isn't defined well
> enough, that should be fixed in the HTML spec.

I would prefer a definition that doesn't involve defaultView, actually. 
  I don't expect browsers to converge defaultView behavior any time in 
the near or medium future, so the testability would be illusory: tests 
would just depend on whether browsers implement defaultView "correctly"...

Received on Friday, 13 January 2012 17:35:40 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:26:38 UTC