OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. | 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. |
5 * | 5 * |
6 * Other contributors: | 6 * Other contributors: |
7 * Robert O'Callahan <roc+@cs.cmu.edu> | 7 * Robert O'Callahan <roc+@cs.cmu.edu> |
8 * David Baron <dbaron@fas.harvard.edu> | 8 * David Baron <dbaron@fas.harvard.edu> |
9 * Christian Biesinger <cbiesinger@web.de> | 9 * Christian Biesinger <cbiesinger@web.de> |
10 * Randall Jesup <rjesup@wgate.com> | 10 * Randall Jesup <rjesup@wgate.com> |
(...skipping 486 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
497 | 497 |
498 bool hadTransform = m_transform; | 498 bool hadTransform = m_transform; |
499 if (hasTransform != hadTransform) { | 499 if (hasTransform != hadTransform) { |
500 if (hasTransform) | 500 if (hasTransform) |
501 m_transform = adoptPtr(new TransformationMatrix); | 501 m_transform = adoptPtr(new TransformationMatrix); |
502 else | 502 else |
503 m_transform.clear(); | 503 m_transform.clear(); |
504 | 504 |
505 // Layers with transforms act as clip rects roots, so clear the cached c lip rects here. | 505 // Layers with transforms act as clip rects roots, so clear the cached c lip rects here. |
506 m_clipper.clearClipRectsIncludingDescendants(); | 506 m_clipper.clearClipRectsIncludingDescendants(); |
507 } else if (hasTransform) { | |
508 m_clipper.clearClipRectsIncludingDescendants(AbsoluteClipRects); | |
Ian Vollick
2014/06/17 15:57:28
Doesn't this mean that even if we call updateTrans
ajuma
2014/06/17 16:01:50
The caller of updateTransform (RenderLayer::styleC
Ian Vollick
2014/06/17 16:07:25
Ah, thanks. In that case, maybe we could add an AS
ajuma
2014/06/17 17:10:40
Adding an ASSERT is a good idea, but we don't have
| |
507 } | 509 } |
508 | 510 |
509 if (hasTransform) { | 511 if (hasTransform) { |
510 RenderBox* box = renderBox(); | 512 RenderBox* box = renderBox(); |
511 ASSERT(box); | 513 ASSERT(box); |
512 m_transform->makeIdentity(); | 514 m_transform->makeIdentity(); |
513 box->style()->applyTransform(*m_transform, box->pixelSnappedBorderBoxRec t().size(), RenderStyle::IncludeTransformOrigin); | 515 box->style()->applyTransform(*m_transform, box->pixelSnappedBorderBoxRec t().size(), RenderStyle::IncludeTransformOrigin); |
514 makeMatrixRenderable(*m_transform, compositor()->hasAcceleratedCompositi ng()); | 516 makeMatrixRenderable(*m_transform, compositor()->hasAcceleratedCompositi ng()); |
515 } | 517 } |
516 | 518 |
(...skipping 3347 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
3864 } | 3866 } |
3865 } | 3867 } |
3866 | 3868 |
3867 void showLayerTree(const WebCore::RenderObject* renderer) | 3869 void showLayerTree(const WebCore::RenderObject* renderer) |
3868 { | 3870 { |
3869 if (!renderer) | 3871 if (!renderer) |
3870 return; | 3872 return; |
3871 showLayerTree(renderer->enclosingLayer()); | 3873 showLayerTree(renderer->enclosingLayer()); |
3872 } | 3874 } |
3873 #endif | 3875 #endif |
OLD | NEW |