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

Side by Side Diff: Source/core/paint/DeprecatedPaintLayer.h

Issue 1030323005: Simplify application of perspective origin. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: with new TestExpectations Created 5 years, 8 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003, 2009, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2003, 2009, 2012 Apple Inc. All rights reserved.
3 * Copyright (C) 2013 Intel Corporation. All rights reserved. 3 * Copyright (C) 2013 Intel Corporation. All rights reserved.
4 * 4 *
5 * Portions are Copyright (C) 1998 Netscape Communications Corporation. 5 * Portions are Copyright (C) 1998 Netscape Communications Corporation.
6 * 6 *
7 * Other contributors: 7 * Other contributors:
8 * Robert O'Callahan <roc+@cs.cmu.edu> 8 * Robert O'Callahan <roc+@cs.cmu.edu>
9 * David Baron <dbaron@fas.harvard.edu> 9 * David Baron <dbaron@fas.harvard.edu>
10 * Christian Biesinger <cbiesinger@web.de> 10 * Christian Biesinger <cbiesinger@web.de>
(...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after
270 void clearTransform() { m_transform.clear(); } 270 void clearTransform() { m_transform.clear(); }
271 271
272 // currentTransform computes a transform which takes accelerated animations into account. The 272 // currentTransform computes a transform which takes accelerated animations into account. The
273 // resulting transform has transform-origin baked in. If the layer does not have a transform, 273 // resulting transform has transform-origin baked in. If the layer does not have a transform,
274 // returns the identity matrix. 274 // returns the identity matrix.
275 TransformationMatrix currentTransform(ComputedStyle::ApplyTransformOrigin = ComputedStyle::IncludeTransformOrigin) const; 275 TransformationMatrix currentTransform(ComputedStyle::ApplyTransformOrigin = ComputedStyle::IncludeTransformOrigin) const;
276 TransformationMatrix renderableTransform(PaintBehavior) const; 276 TransformationMatrix renderableTransform(PaintBehavior) const;
277 277
278 // Get the perspective transform, which is applied to transformed sublayers. 278 // Get the perspective transform, which is applied to transformed sublayers.
279 // Returns true if the layer has a -webkit-perspective. 279 // Returns true if the layer has a -webkit-perspective.
280 // Note that this transform has the perspective-origin baked in. 280 // Note that this transform does not have the perspective-origin baked in.
281 TransformationMatrix perspectiveTransform() const; 281 TransformationMatrix perspectiveTransform() const;
282 FloatPoint perspectiveOrigin() const; 282 FloatPoint perspectiveOrigin() const;
283 bool preserves3D() const { return layoutObject()->style()->transformStyle3D( ) == TransformStyle3DPreserve3D; } 283 bool preserves3D() const { return layoutObject()->style()->transformStyle3D( ) == TransformStyle3DPreserve3D; }
284 bool has3DTransform() const { return m_transform && !m_transform->isAffine() ; } 284 bool has3DTransform() const { return m_transform && !m_transform->isAffine() ; }
285 285
286 // FIXME: reflections should force transform-style to be flat in the style: https://bugs.webkit.org/show_bug.cgi?id=106959 286 // FIXME: reflections should force transform-style to be flat in the style: https://bugs.webkit.org/show_bug.cgi?id=106959
287 bool shouldPreserve3D() const { return !layoutObject()->hasReflection() && l ayoutObject()->style()->transformStyle3D() == TransformStyle3DPreserve3D; } 287 bool shouldPreserve3D() const { return !layoutObject()->hasReflection() && l ayoutObject()->style()->transformStyle3D() == TransformStyle3DPreserve3D; }
288 288
289 void filterNeedsPaintInvalidation(); 289 void filterNeedsPaintInvalidation();
290 bool hasFilter() const { return layoutObject()->hasFilter(); } 290 bool hasFilter() const { return layoutObject()->hasFilter(); }
(...skipping 432 matching lines...) Expand 10 before | Expand all | Expand 10 after
723 723
724 } // namespace blink 724 } // namespace blink
725 725
726 #ifndef NDEBUG 726 #ifndef NDEBUG
727 // Outside the WebCore namespace for ease of invocation from gdb. 727 // Outside the WebCore namespace for ease of invocation from gdb.
728 void showLayerTree(const blink::DeprecatedPaintLayer*); 728 void showLayerTree(const blink::DeprecatedPaintLayer*);
729 void showLayerTree(const blink::LayoutObject*); 729 void showLayerTree(const blink::LayoutObject*);
730 #endif 730 #endif
731 731
732 #endif // Layer_h 732 #endif // Layer_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698