- From: Ian Hickson <ian@hixie.ch>
- Date: Thu, 30 Apr 2009 16:58:18 +0000 (UTC)
- To: Anne van Kesteren <annevk@opera.com>
- Cc: WebApps WG <public-webapps@w3.org>
On Thu, 30 Apr 2009, Anne van Kesteren wrote: > > For environments where the global object is represented by the Window > object XMLHttpRequest needs to be associated with a Document object for > determining the origin and base URL. The problem is that the > XMLHttpRequest interface object can be copied around, e.g. > > var x = frames[0].XMLHttpRequest > > in that scenario x needs to be associated with Document object > associated with frames[0]. (If frames[0] is later navigated the Document > object would change, so it is important that this happens at this > point.) There is a 1:1 mapping from global object to Document object now that we have WindowProxy objects. So you can probably just say something like: "...the Document object associated with the Window object for which the XMLHttpRequest interface object was created..." > To be clear, assuming a and b are distinct global objects, in > > a.x = a.XMLHttpRequest > b.x = a.x > > the XMLHttpRequest interface object in b.x has a pointer to the Document > object associated with a. When the XMLHttpRequest constructor is invoked > this pointer needs to be somehow copied to the constructed object. I think that is covered by the incantation above. -- Ian Hickson U+1047E )\._.,--....,'``. fL http://ln.hixie.ch/ U+263A /, _.. \ _\ ;`._ ,. Things that are impossible just take longer. `._.-(,_..'--(,_..'`-.;.'
Received on Thursday, 30 April 2009 16:58:57 UTC