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

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

Issue 2867883003: [CSS Typed OM] Delete obsolete number and length classes from Typed OM (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
« no previous file with comments | « third_party/WebKit/Source/core/css/cssom/StylePropertyMapReadonly.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/css/cssom/StyleValueFactory.cpp
diff --git a/third_party/WebKit/Source/core/css/cssom/StyleValueFactory.cpp b/third_party/WebKit/Source/core/css/cssom/StyleValueFactory.cpp
index 825fffafc6b0b538a125fec23de4e570a28b462b..2fd1ac86528c055de16b32a7c2812c320255d1dc 100644
--- a/third_party/WebKit/Source/core/css/cssom/StyleValueFactory.cpp
+++ b/third_party/WebKit/Source/core/css/cssom/StyleValueFactory.cpp
@@ -6,11 +6,8 @@
#include "core/css/CSSImageValue.h"
#include "core/css/CSSValue.h"
-#include "core/css/cssom/CSSCalcLength.h"
#include "core/css/cssom/CSSKeywordValue.h"
-#include "core/css/cssom/CSSNumberValue.h"
#include "core/css/cssom/CSSOMTypes.h"
-#include "core/css/cssom/CSSSimpleLength.h"
#include "core/css/cssom/CSSStyleValue.h"
#include "core/css/cssom/CSSStyleVariableReferenceValue.h"
#include "core/css/cssom/CSSTransformValue.h"
@@ -24,10 +21,6 @@ namespace {
CSSStyleValue* CreateStyleValueFromPrimitiveValue(
const CSSPrimitiveValue& primitive_value) {
- if (primitive_value.IsNumber())
- return CSSNumberValue::Create(primitive_value.GetDoubleValue());
- if (primitive_value.IsLength() || primitive_value.IsPercentage())
- return CSSSimpleLength::FromCSSValue(primitive_value);
return nullptr;
}
@@ -40,13 +33,6 @@ CSSStyleValue* CreateStyleValueWithPropertyInternal(CSSPropertyID property_id,
// TODO(meade): Implement other properties.
break;
}
- if (value.IsPrimitiveValue() && ToCSSPrimitiveValue(value).IsCalculated()) {
- // TODO(meade): Handle other calculated types, e.g. angles here.
- if (CSSOMTypes::PropertyCanTakeType(property_id,
- CSSStyleValue::kCalcLengthType)) {
- return CSSCalcLength::FromCSSValue(ToCSSPrimitiveValue(value));
- }
- }
return nullptr;
}
« no previous file with comments | « third_party/WebKit/Source/core/css/cssom/StylePropertyMapReadonly.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698