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

Unified Diff: third_party/WebKit/Source/core/css/cssom/CSSKeywordValue.cpp

Issue 2893823002: [CSS Typed OM] Make CSSKeywordValue's value attribute mutable (Closed)
Patch Set: rebase Created 3 years, 7 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/css/cssom/CSSKeywordValue.cpp
diff --git a/third_party/WebKit/Source/core/css/cssom/CSSKeywordValue.cpp b/third_party/WebKit/Source/core/css/cssom/CSSKeywordValue.cpp
index ad71d36bba0aa9ef76b3f508f5b40f417f2f9ea5..5dabdc822ca0de85959bdc9cd0aa511a2a71982d 100644
--- a/third_party/WebKit/Source/core/css/cssom/CSSKeywordValue.cpp
+++ b/third_party/WebKit/Source/core/css/cssom/CSSKeywordValue.cpp
@@ -11,10 +11,11 @@
#include "core/css/CSSInitialValue.h"
#include "core/css/CSSUnsetValue.h"
#include "core/css/parser/CSSPropertyParser.h"
+#include "platform/wtf/text/AtomicString.h"
namespace blink {
-CSSKeywordValue* CSSKeywordValue::Create(const AtomicString& keyword,
+CSSKeywordValue* CSSKeywordValue::Create(const String& keyword,
ExceptionState& exception_state) {
if (keyword.IsEmpty()) {
exception_state.ThrowTypeError(
@@ -48,12 +49,12 @@ CSSKeywordValue* CSSKeywordValue::FromCSSValue(const CSSValue& value) {
return nullptr;
}
-CSSKeywordValue* CSSKeywordValue::Create(const AtomicString& keyword) {
+CSSKeywordValue* CSSKeywordValue::Create(const String& keyword) {
DCHECK(!keyword.IsEmpty());
return new CSSKeywordValue(keyword);
}
-const AtomicString& CSSKeywordValue::keywordValue() const {
+const String& CSSKeywordValue::value() const {
return keyword_value_;
}
@@ -71,7 +72,7 @@ CSSValue* CSSKeywordValue::ToCSSValue() const {
case (CSSValueUnset):
return CSSUnsetValue::Create();
case (CSSValueInvalid):
- return CSSCustomIdentValue::Create(keyword_value_);
+ return CSSCustomIdentValue::Create(AtomicString(keyword_value_));
default:
return CSSIdentifierValue::Create(keyword_id);
}

Powered by Google App Engine
This is Rietveld 408576698