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

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

Issue 112843002: Make calls to AtomicString(const String&) explicit in dom/ (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years 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: Source/core/dom/DatasetDOMStringMap.cpp
diff --git a/Source/core/dom/DatasetDOMStringMap.cpp b/Source/core/dom/DatasetDOMStringMap.cpp
index 921531948ca49d0f372263ce1972af4b43334950..ae798de84bf43709e3e4bd740c1f191ffcc6c7bd 100644
--- a/Source/core/dom/DatasetDOMStringMap.cpp
+++ b/Source/core/dom/DatasetDOMStringMap.cpp
@@ -107,7 +107,7 @@ static bool isValidPropertyName(const String& name)
return true;
}
-static String convertPropertyNameToAttributeName(const String& name)
+static AtomicString convertPropertyNameToAttributeName(const String& name)
{
StringBuilder builder;
builder.append("data-");
@@ -122,7 +122,7 @@ static String convertPropertyNameToAttributeName(const String& name)
builder.append(character);
}
- return builder.toString();
+ return builder.toAtomicString();
}
void DatasetDOMStringMap::ref()
@@ -185,7 +185,7 @@ void DatasetDOMStringMap::setItem(const String& name, const String& value, Excep
return;
}
- m_element->setAttribute(convertPropertyNameToAttributeName(name), value, exceptionState);
+ m_element->setAttribute(convertPropertyNameToAttributeName(name), AtomicString(value), exceptionState);
}
void DatasetDOMStringMap::deleteItem(const String& name, ExceptionState& exceptionState)

Powered by Google App Engine
This is Rietveld 408576698