Index: third_party/WebKit/Source/core/dom/Attribute.h |
diff --git a/third_party/WebKit/Source/core/dom/Attribute.h b/third_party/WebKit/Source/core/dom/Attribute.h |
index f207741ae562d9bcfaaa79571e73627833076dd6..1ba868c37c8a3b7d88cf7435f95328e85327f60d 100644 |
--- a/third_party/WebKit/Source/core/dom/Attribute.h |
+++ b/third_party/WebKit/Source/core/dom/Attribute.h |
@@ -53,6 +53,7 @@ class Attribute { |
bool isEmpty() const { return m_value.isEmpty(); } |
bool matches(const QualifiedName&) const; |
+ bool matchesCaseInsensitive(const QualifiedName&) const; |
void setValue(const AtomicString& value) { m_value = value; } |
@@ -79,6 +80,14 @@ inline bool Attribute::matches(const QualifiedName& qualifiedName) const { |
qualifiedName.namespaceURI() == namespaceURI(); |
} |
+inline bool Attribute::matchesCaseInsensitive( |
+ const QualifiedName& qualifiedName) const { |
+ if (qualifiedName.localNameUpper() != m_name.localNameUpper()) |
sashab
2016/11/11 00:16:52
You could move this into the return statement :)
rune
2016/11/11 09:49:23
Done.
|
+ return false; |
+ return qualifiedName.prefix() == starAtom || |
+ qualifiedName.namespaceURI() == namespaceURI(); |
+} |
+ |
} // namespace blink |
#endif // Attribute_h |