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

Unified Diff: third_party/WebKit/Source/core/html/HTMLEmbedElement.cpp

Issue 2623513005: Introduce Element::AttributeModificationParams (Closed)
Patch Set: Created 3 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
Index: third_party/WebKit/Source/core/html/HTMLEmbedElement.cpp
diff --git a/third_party/WebKit/Source/core/html/HTMLEmbedElement.cpp b/third_party/WebKit/Source/core/html/HTMLEmbedElement.cpp
index 545079324e980157260bbc6fde2c6edd032ea3be..dd201c94b210a22b043e84f5e16e05f3d74d9fa4 100644
--- a/third_party/WebKit/Source/core/html/HTMLEmbedElement.cpp
+++ b/third_party/WebKit/Source/core/html/HTMLEmbedElement.cpp
@@ -92,11 +92,10 @@ void HTMLEmbedElement::collectStyleForPresentationAttribute(
}
}
-void HTMLEmbedElement::parseAttribute(const QualifiedName& name,
- const AtomicString& oldValue,
- const AtomicString& value) {
- if (name == typeAttr) {
- m_serviceType = value.lower();
+void HTMLEmbedElement::parseAttribute(
+ const AttributeModificationParams& params) {
+ if (params.name == typeAttr) {
+ m_serviceType = params.newValue.lower();
size_t pos = m_serviceType.find(";");
if (pos != kNotFound)
m_serviceType = m_serviceType.left(pos);
@@ -107,12 +106,12 @@ void HTMLEmbedElement::parseAttribute(const QualifiedName& name,
} else {
requestPluginCreationWithoutLayoutObjectIfPossible();
}
- } else if (name == codeAttr) {
+ } else if (params.name == codeAttr) {
// TODO(schenney): Remove this branch? It's not in the spec and we're not in
// the HTMLAppletElement hierarchy.
- m_url = stripLeadingAndTrailingHTMLSpaces(value);
- } else if (name == srcAttr) {
- m_url = stripLeadingAndTrailingHTMLSpaces(value);
+ m_url = stripLeadingAndTrailingHTMLSpaces(params.newValue);
+ } else if (params.name == srcAttr) {
+ m_url = stripLeadingAndTrailingHTMLSpaces(params.newValue);
if (layoutObject() && isImageType()) {
if (!m_imageLoader)
m_imageLoader = HTMLImageLoader::create(this);
@@ -127,7 +126,7 @@ void HTMLEmbedElement::parseAttribute(const QualifiedName& name,
requestPluginCreationWithoutLayoutObjectIfPossible();
}
} else {
- HTMLPlugInElement::parseAttribute(name, oldValue, value);
+ HTMLPlugInElement::parseAttribute(params);
}
}
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLEmbedElement.h ('k') | third_party/WebKit/Source/core/html/HTMLFormControlElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698