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

Side by Side Diff: cc/render_surface.cc

Issue 11308153: Migrate most of cc/ from WebKit::WebTransformationMatrix to gfx::Transform (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Patch for landing Created 8 years 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 | Annotate | Revision Log
« no previous file with comments | « cc/render_surface.h ('k') | cc/render_surface_impl.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2010 The Chromium Authors. All rights reserved. 1 // Copyright 2010 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 "cc/render_surface.h" 5 #include "cc/render_surface.h"
6 6
7 #include "cc/layer.h" 7 #include "cc/layer.h"
8 #include "cc/math_util.h" 8 #include "cc/math_util.h"
9 #include <public/WebTransformationMatrix.h> 9 #include "ui/gfx/transform.h"
10
11 using WebKit::WebTransformationMatrix;
12 10
13 namespace cc { 11 namespace cc {
14 12
15 RenderSurface::RenderSurface(Layer* owningLayer) 13 RenderSurface::RenderSurface(Layer* owningLayer)
16 : m_owningLayer(owningLayer) 14 : m_owningLayer(owningLayer)
17 , m_drawOpacity(1) 15 , m_drawOpacity(1)
18 , m_drawOpacityIsAnimating(false) 16 , m_drawOpacityIsAnimating(false)
19 , m_targetSurfaceTransformsAreAnimating(false) 17 , m_targetSurfaceTransformsAreAnimating(false)
20 , m_screenSpaceTransformsAreAnimating(false) 18 , m_screenSpaceTransformsAreAnimating(false)
21 , m_isClipped(false) 19 , m_isClipped(false)
22 , m_nearestAncestorThatMovesPixels(0) 20 , m_nearestAncestorThatMovesPixels(0)
23 { 21 {
24 } 22 }
25 23
26 RenderSurface::~RenderSurface() 24 RenderSurface::~RenderSurface()
27 { 25 {
28 } 26 }
29 27
30 gfx::RectF RenderSurface::drawableContentRect() const 28 gfx::RectF RenderSurface::drawableContentRect() const
31 { 29 {
32 gfx::RectF drawableContentRect = MathUtil::mapClippedRect(m_drawTransform, m _contentRect); 30 gfx::RectF drawableContentRect = MathUtil::mapClippedRect(m_drawTransform, m _contentRect);
33 if (m_owningLayer->hasReplica()) 31 if (m_owningLayer->hasReplica())
34 drawableContentRect.Union(MathUtil::mapClippedRect(m_replicaDrawTransfor m, m_contentRect)); 32 drawableContentRect.Union(MathUtil::mapClippedRect(m_replicaDrawTransfor m, m_contentRect));
35 return drawableContentRect; 33 return drawableContentRect;
36 } 34 }
37 35
38 } // namespace cc 36 } // namespace cc
OLDNEW
« no previous file with comments | « cc/render_surface.h ('k') | cc/render_surface_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698