Index: third_party/WebKit/Source/core/dom/DOMMatrixReadOnly.cpp |
diff --git a/third_party/WebKit/Source/core/dom/DOMMatrixReadOnly.cpp b/third_party/WebKit/Source/core/dom/DOMMatrixReadOnly.cpp |
index 0b34d8bf78ff3d29f3704b555fc54322095281db..7c7f2ede94b480e8a5869fa9af2897653f5a6e82 100644 |
--- a/third_party/WebKit/Source/core/dom/DOMMatrixReadOnly.cpp |
+++ b/third_party/WebKit/Source/core/dom/DOMMatrixReadOnly.cpp |
@@ -85,6 +85,10 @@ bool DOMMatrixReadOnly::validateAndFixup(DOMMatrixInit& other, |
return true; |
} |
+DOMMatrixReadOnly* DOMMatrixReadOnly::create(ExceptionState& exceptionState) { |
+ return new DOMMatrixReadOnly(TransformationMatrix()); |
+} |
+ |
DOMMatrixReadOnly* DOMMatrixReadOnly::create(Vector<double> sequence, |
ExceptionState& exceptionState) { |
if (sequence.size() != 6 && sequence.size() != 16) { |
@@ -249,6 +253,12 @@ DOMPoint* DOMMatrixReadOnly::transformPoint(const DOMPointInit& point) { |
return DOMPoint::create(x, y, z, w); |
} |
+DOMMatrixReadOnly::DOMMatrixReadOnly(const TransformationMatrix& matrix, |
+ bool is2D) { |
+ m_matrix = TransformationMatrix::create(matrix); |
+ m_is2D = is2D; |
+} |
+ |
DOMFloat32Array* DOMMatrixReadOnly::toFloat32Array() const { |
float array[] = { |
static_cast<float>(m_matrix->m11()), static_cast<float>(m_matrix->m12()), |