Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(637)

Unified Diff: Source/core/dom/Element.cpp

Issue 697693003: Add a UseCounter for when xml:base takes effect in Element.baseURI (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/core/frame/UseCounter.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Element.cpp
diff --git a/Source/core/dom/Element.cpp b/Source/core/dom/Element.cpp
index bbeda432053a4e4191fe25cf66ad145ba8cfee27..2e663af766630c0cf0857f530902a5e5d913ca64 100644
--- a/Source/core/dom/Element.cpp
+++ b/Source/core/dom/Element.cpp
@@ -1212,6 +1212,9 @@ const AtomicString& Element::locateNamespacePrefix(const AtomicString& namespace
KURL Element::baseURI() const
{
const AtomicString& baseAttribute = fastGetAttribute(baseAttr);
+ if (!baseAttribute.isEmpty())
+ UseCounter::count(document(), UseCounter::ElementBaseURIFromXMLBase);
+
KURL base(KURL(), baseAttribute);
if (!base.protocol().isEmpty())
return base;
« no previous file with comments | « no previous file | Source/core/frame/UseCounter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698