Chromium Code Reviews| Index: Source/core/dom/shadow/ElementShadow.cpp |
| diff --git a/Source/core/dom/shadow/ElementShadow.cpp b/Source/core/dom/shadow/ElementShadow.cpp |
| index ad449159c82d820e2b629b0609037e6acb4b7aa4..a34db2133d1929af90d15a7ac22627b9d1062906 100644 |
| --- a/Source/core/dom/shadow/ElementShadow.cpp |
| +++ b/Source/core/dom/shadow/ElementShadow.cpp |
| @@ -31,6 +31,7 @@ |
| #include "core/dom/ElementTraversal.h" |
| #include "core/dom/NodeTraversal.h" |
| #include "core/dom/shadow/DistributedNodes.h" |
| +#include "core/frame/UseCounter.h" |
| #include "core/html/HTMLContentElement.h" |
| #include "core/html/HTMLShadowElement.h" |
| #include "core/inspector/InspectorInstrumentation.h" |
| @@ -149,6 +150,8 @@ ShadowRoot& ElementShadow::addShadowRoot(Element& shadowHost, ShadowRoot::Shadow |
| if (type == ShadowRoot::OpenShadowRoot && (!youngestShadowRoot() || youngestShadowRoot()->type() == ShadowRoot::UserAgentShadowRoot)) |
| shadowHost.willAddFirstOpenShadowRoot(); |
| + else |
|
hayato
2015/05/20 02:10:04
Will this count UserAgent ShadowRoot also?
kochi
2015/05/20 02:26:25
Good catch. fixed.
|
| + UseCounter::count(shadowHost.document(), UseCounter::DeprecatedMultipleElementCreateShadowRoot); |
| for (ShadowRoot* root = youngestShadowRoot(); root; root = root->olderShadowRoot()) |
| root->lazyReattachIfAttached(); |