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

Unified Diff: third_party/WebKit/Source/core/css/cssom/CSSSimpleLength.h

Issue 2005683002: Typed CSSOM: Rename SimpleLength to CSSSimpleLength (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix SimpleLengthType compile errors Created 4 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/CSSSimpleLength.h
diff --git a/third_party/WebKit/Source/core/css/cssom/SimpleLength.h b/third_party/WebKit/Source/core/css/cssom/CSSSimpleLength.h
similarity index 70%
rename from third_party/WebKit/Source/core/css/cssom/SimpleLength.h
rename to third_party/WebKit/Source/core/css/cssom/CSSSimpleLength.h
index 645822c8dd3f943040dff26bb85aa6b1f43ddf17..7a3a153abb0da5dddc3000622f9745aa6b5f6432 100644
--- a/third_party/WebKit/Source/core/css/cssom/SimpleLength.h
+++ b/third_party/WebKit/Source/core/css/cssom/CSSSimpleLength.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef SimpleLength_h
-#define SimpleLength_h
+#ifndef CSSSimpleLength_h
+#define CSSSimpleLength_h
#include "bindings/core/v8/ExceptionState.h"
#include "core/css/cssom/CSSLengthValue.h"
@@ -12,23 +12,23 @@ namespace blink {
class CSSPrimitiveValue;
-class CORE_EXPORT SimpleLength final : public CSSLengthValue {
- WTF_MAKE_NONCOPYABLE(SimpleLength);
+class CORE_EXPORT CSSSimpleLength final : public CSSLengthValue {
+ WTF_MAKE_NONCOPYABLE(CSSSimpleLength);
DEFINE_WRAPPERTYPEINFO();
public:
- static SimpleLength* create(double value, const String& type, ExceptionState& exceptionState)
+ static CSSSimpleLength* create(double value, const String& type, ExceptionState& exceptionState)
{
CSSPrimitiveValue::UnitType unit = unitFromName(type);
if (!isSupportedLengthUnit(unit)) {
- exceptionState.throwTypeError("Invalid unit for SimpleLength: " + type);
+ exceptionState.throwTypeError("Invalid unit for CSSSimpleLength: " + type);
return nullptr;
}
- return new SimpleLength(value, unit);
+ return new CSSSimpleLength(value, unit);
}
- static SimpleLength* create(double value, CSSPrimitiveValue::UnitType type)
+ static CSSSimpleLength* create(double value, CSSPrimitiveValue::UnitType type)
{
- return new SimpleLength(value, type);
+ return new CSSSimpleLength(value, type);
}
bool containsPercent() const override;
@@ -50,14 +50,14 @@ protected:
virtual CSSLengthValue* divideInternal(double, ExceptionState&);
private:
- SimpleLength(double value, CSSPrimitiveValue::UnitType unit) : CSSLengthValue(), m_unit(unit), m_value(value) {}
+ CSSSimpleLength(double value, CSSPrimitiveValue::UnitType unit) : CSSLengthValue(), m_unit(unit), m_value(value) {}
CSSPrimitiveValue::UnitType m_unit;
double m_value;
};
#define DEFINE_SIMPLE_LENGTH_TYPE_CASTS(argumentType) \
- DEFINE_TYPE_CASTS(SimpleLength, argumentType, value, \
+ DEFINE_TYPE_CASTS(CSSSimpleLength, argumentType, value, \
value->type() == CSSLengthValue::StyleValueType::SimpleLengthType, \
value.type() == CSSLengthValue::StyleValueType::SimpleLengthType)

Powered by Google App Engine
This is Rietveld 408576698