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

Side by Side Diff: Source/core/dom/DOMMatrix.cpp

Issue 539923002: [WIP] DOMMatrixReadOnly::m_matrix is changed to OwnPtr<>. Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: trigger bug Created 6 years, 3 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 #include "core/dom/DOMMatrix.h" 6 #include "core/dom/DOMMatrix.h"
7 7
8 namespace blink { 8 namespace blink {
9 9
10 DOMMatrix* DOMMatrix::create() 10 DOMMatrix* DOMMatrix::create()
(...skipping 16 matching lines...) Expand all
27 { 27 {
28 if (m_is2D) 28 if (m_is2D)
29 m_is2D = value; 29 m_is2D = value;
30 } 30 }
31 31
32 DOMMatrix* DOMMatrix::multiplySelf(DOMMatrix* other) 32 DOMMatrix* DOMMatrix::multiplySelf(DOMMatrix* other)
33 { 33 {
34 if (!other->is2D()) 34 if (!other->is2D())
35 m_is2D = false; 35 m_is2D = false;
36 36
37 m_matrix = m_matrix * other->matrix(); 37 m_matrix.multiply(other->matrix());
zino 2014/09/04 14:18:52 I think this sentence is reasonable but it makes a
38 38
39 return this; 39 return this;
40 } 40 }
41 41
42 DOMMatrix* DOMMatrix::preMultiplySelf(DOMMatrix* other) 42 DOMMatrix* DOMMatrix::preMultiplySelf(DOMMatrix* other)
43 { 43 {
44 if (!other->is2D()) 44 if (!other->is2D())
45 m_is2D = false; 45 m_is2D = false;
46 46
47 m_matrix = other->matrix() * m_matrix; 47 m_matrix = other->matrix() * m_matrix;
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 else 94 else
95 m_matrix.scale3d(sx, sy, sz); 95 m_matrix.scale3d(sx, sy, sz);
96 96
97 if (hasTranslation) 97 if (hasTranslation)
98 translateSelf(-ox, -oy, -oz); 98 translateSelf(-ox, -oy, -oz);
99 99
100 return this; 100 return this;
101 } 101 }
102 102
103 } // namespace blink 103 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698