W3C home > Mailing lists > Public > www-style@w3.org > July 2008

Re: Opera's Proposal for :context Selector

From: Lachlan Hunt <lachlan.hunt@lachy.id.au>
Date: Mon, 14 Jul 2008 00:59:49 +0200
Message-ID: <487A88E5.1050109@lachy.id.au>
To: Andrew Fedoniouk <news@terrainformatica.com>
Cc: www-style <www-style@w3.org>

Andrew Fedoniouk wrote:
> Am I correct in my understanding that:
> 
>   localRoot.querySelector("div")
> 
> will mean precisely:
> 
>   localRoot.querySelector(":context div")

In that particular case, yes, because the results are restricted to 
elements contained within the context node.  But not in this case:

foo.querySelector("div div");

That is not the same as either

foo.querySelector(":context div div")

And similarly when using other combinators.  This is all clearly 
explained in that email I linked to before.

-- 
Lachlan Hunt - Opera Software
http://lachy.id.au/
http://www.opera.com/
Received on Sunday, 13 July 2008 23:00:27 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 27 April 2009 13:55:10 GMT