diff options
Diffstat (limited to 'chromium/third_party/WebKit/Source/core/rendering/PaintInfo.h')
-rw-r--r-- | chromium/third_party/WebKit/Source/core/rendering/PaintInfo.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/chromium/third_party/WebKit/Source/core/rendering/PaintInfo.h b/chromium/third_party/WebKit/Source/core/rendering/PaintInfo.h index be99ec39407..50b6463a1a4 100644 --- a/chromium/third_party/WebKit/Source/core/rendering/PaintInfo.h +++ b/chromium/third_party/WebKit/Source/core/rendering/PaintInfo.h @@ -40,7 +40,6 @@ namespace WebCore { class RenderInline; class RenderLayerModelObject; class RenderObject; -class RenderRegion; class RenderWidget; typedef HashMap<RenderWidget*, IntRect> OverlapTestRequestMap; @@ -51,14 +50,13 @@ typedef HashMap<RenderWidget*, IntRect> OverlapTestRequestMap; */ struct PaintInfo { PaintInfo(GraphicsContext* newContext, const IntRect& newRect, PaintPhase newPhase, PaintBehavior newPaintBehavior, - RenderObject* newPaintingRoot = 0, RenderRegion* region = 0, ListHashSet<RenderInline*>* newOutlineObjects = 0, + RenderObject* newPaintingRoot = 0, ListHashSet<RenderInline*>* newOutlineObjects = 0, OverlapTestRequestMap* overlapTestRequests = 0, const RenderLayerModelObject* newPaintContainer = 0) : context(newContext) , rect(newRect) , phase(newPhase) , paintBehavior(newPaintBehavior) , paintingRoot(newPaintingRoot) - , renderRegion(region) , overlapTestRequests(overlapTestRequests) , m_paintContainer(newPaintContainer) , m_outlineObjects(newOutlineObjects) @@ -87,9 +85,9 @@ struct PaintInfo { bool skipRootBackground() const { return paintBehavior & PaintBehaviorSkipRootBackground; } bool paintRootBackgroundOnly() const { return paintBehavior & PaintBehaviorRootBackgroundOnly; } - void applyTransform(const AffineTransform& localToAncestorTransform) + void applyTransform(const AffineTransform& localToAncestorTransform, bool identityStatusUnknown = true) { - if (localToAncestorTransform.isIdentity()) + if (identityStatusUnknown && localToAncestorTransform.isIdentity()) return; context->concatCTM(localToAncestorTransform); @@ -97,7 +95,10 @@ struct PaintInfo { if (rect == infiniteRect()) return; - rect = localToAncestorTransform.inverse().mapRect(rect); + if (localToAncestorTransform.isInvertible()) + rect = localToAncestorTransform.inverse().mapRect(rect); + else + rect.setSize(IntSize(0, 0)); } static IntRect infiniteRect() { return IntRect(LayoutRect::infiniteRect()); } @@ -112,7 +113,6 @@ struct PaintInfo { PaintPhase phase; PaintBehavior paintBehavior; RenderObject* paintingRoot; // used to draw just one element and its visual kids - RenderRegion* renderRegion; OverlapTestRequestMap* overlapTestRequests; private: |