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

Unified Diff: Source/core/svg/SVGURIReference.h

Issue 126443005: Use TreeScope::completeURL and baseURL instead of the Document versions (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased again, passes tests Created 6 years, 11 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 | « Source/core/svg/SVGImageLoader.cpp ('k') | Source/core/svg/SVGUseElement.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/SVGURIReference.h
diff --git a/Source/core/svg/SVGURIReference.h b/Source/core/svg/SVGURIReference.h
index c940502e53291d1c65f53e3d7120c1b234106fdd..944e06bf60e7a8b9db029437b9ce73a9d7a5ce6a 100644
--- a/Source/core/svg/SVGURIReference.h
+++ b/Source/core/svg/SVGURIReference.h
@@ -22,6 +22,7 @@
#define SVGURIReference_h
#include "core/dom/Document.h"
+#include "core/dom/TreeScope.h"
namespace WebCore {
@@ -39,15 +40,15 @@ public:
static AtomicString fragmentIdentifierFromIRIString(const String&, const Document&);
static Element* targetElementFromIRIString(const String&, const Document&, AtomicString* = 0, Document* = 0);
- static inline bool isExternalURIReference(const String& uri, const Document& document)
+ static inline bool isExternalURIReference(const String& uri, const TreeScope& treeScope)
{
// Fragment-only URIs are always internal
if (uri.startsWith('#'))
return false;
// If the URI matches our documents URL, we're dealing with a local reference.
- KURL url = document.completeURL(uri);
- return !equalIgnoringFragmentIdentifier(url, document.url());
+ KURL url = treeScope.completeURL(uri);
+ return !equalIgnoringFragmentIdentifier(url, treeScope.document().url());
}
protected:
« no previous file with comments | « Source/core/svg/SVGImageLoader.cpp ('k') | Source/core/svg/SVGUseElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698