Node::containingShadowRoot should be constant time
https://bugs.webkit.org/show_bug.cgi?id=106494

Patch by Elliott Sprehn <esprehn@gmail.com> on 2013-01-09
Reviewed by Dimitri Glazkov.

There's no reason to traverse up the tree to find the containing
ShadowRoot when we already know if we're in a ShadowRoot by looking at
the treeScope().

No new tests, just refactoring.

* dom/Node.cpp:
(WebCore::Node::containingShadowRoot):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@139273 268f45cc-cd09-0410-ab3c-d52691b4dbfc