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

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

Issue 2935413002: [Typed OM] Add comments and consistent structure to all the CSSTransformComponent subclasses (Closed)
Patch Set: Created 3 years, 6 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/CSSTranslation.h
diff --git a/third_party/WebKit/Source/core/css/cssom/CSSTranslation.h b/third_party/WebKit/Source/core/css/cssom/CSSTranslation.h
index db649400ab90ac1404eaa36332bf0413f94d034c..9e54dea76b0e564f5ad843c6bf0ffa22e07fa531 100644
--- a/third_party/WebKit/Source/core/css/cssom/CSSTranslation.h
+++ b/third_party/WebKit/Source/core/css/cssom/CSSTranslation.h
@@ -13,11 +13,15 @@ class CSSNumericValue;
class DOMMatrix;
class ExceptionState;
+// Represents a translation value in a CSSTransformValue used for properties
+// like "transform".
+// See CSSTranslation.idl for more information about this class.
class CORE_EXPORT CSSTranslation final : public CSSTransformComponent {
WTF_MAKE_NONCOPYABLE(CSSTranslation);
DEFINE_WRAPPERTYPEINFO();
public:
+ // Constructors defined in the IDL.
static CSSTranslation* Create(CSSNumericValue* x,
CSSNumericValue* y,
ExceptionState&) {
@@ -28,21 +32,22 @@ class CORE_EXPORT CSSTranslation final : public CSSTransformComponent {
CSSNumericValue* z,
ExceptionState&);
+ // Blink-internal ways of creating CSSTranslations.
static CSSTranslation* FromCSSValue(const CSSFunctionValue& value) {
return nullptr;
}
+ // Getters and setters for attributes defined in the IDL.
CSSNumericValue* x() const { return x_; }
CSSNumericValue* y() const { return y_; }
CSSNumericValue* z() const { return z_; }
+ // Internal methods - from CSSTransformComponent.
TransformComponentType GetType() const override {
return Is2D() ? kTranslationType : kTranslation3DType;
}
-
// TODO: Implement AsMatrix for CSSTranslation.
DOMMatrix* AsMatrix() const override { return nullptr; }
-
CSSFunctionValue* ToCSSValue() const override;
DEFINE_INLINE_VIRTUAL_TRACE() {

Powered by Google App Engine
This is Rietveld 408576698