Bug 118765 - Allow RenderGeometryMap to map using layers more often
Summary: Allow RenderGeometryMap to map using layers more often
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Simon Fraser (smfr)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-07-16 20:06 PDT by Simon Fraser (smfr)
Modified: 2014-02-13 04:10 PST (History)
6 users (show)

See Also:


Attachments
Patch (2.21 KB, patch)
2013-07-17 09:43 PDT, Simon Fraser (smfr)
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Fraser (smfr) 2013-07-16 20:06:55 PDT
I think we can do this:

diff --git a/Source/WebCore/rendering/RenderGeometryMap.cpp b/Source/WebCore/rendering/RenderGeometryMap.cpp
index 4513ef6a16ca306cdcbe4cb3009642f113cbcf05..9cef31041780fc82788de0872b4beae42f824891 100644
--- a/Source/WebCore/rendering/RenderGeometryMap.cpp
+++ b/Source/WebCore/rendering/RenderGeometryMap.cpp
@@ -165,9 +165,12 @@ static bool canMapBetweenRenderers(const RenderObject* renderer, const RenderObj
         if (style->position() == FixedPosition || style->isFlippedBlocksWritingMode())
             return false;
         
-        if (current->hasColumns() || current->hasTransform() || current->isRenderFlowThread())
+        if (current->hasColumns() || current->isRenderFlowThread())
             return false;
 
+        if (current->hasTransform() && toRenderLayerModelObject(current)->layer()->transform() && !toRenderLayerModelObject(current)->layer()->transform()->isIdentity())
+             return false;
+
     #if ENABLE(SVG)
         if (current->isSVGRoot())
             return false;
Comment 1 Simon Fraser (smfr) 2013-07-17 09:43:07 PDT
Created attachment 206893 [details]
Patch
Comment 2 Tim Horton 2013-07-17 09:48:18 PDT
Comment on attachment 206893 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=206893&action=review

> Source/WebCore/rendering/RenderGeometryMap.cpp:171
> +        if (current->hasTransform() && toRenderLayerModelObject(current)->layer()->transform() && !toRenderLayerModelObject(current)->layer()->transform()->isIdentity())

Could totally factor out "toRenderLayerModelObject(current)->layer()->transform()".
Comment 3 Simon Fraser (smfr) 2013-07-17 15:14:52 PDT
Comment on attachment 206893 [details]
Patch

Hmm, not sure this will do the correct thing if the transform is being animated.
Comment 4 Csaba Osztrogonác 2014-02-13 04:10:49 PST
Comment on attachment 206893 [details]
Patch

Cleared Tim Horton's review+ from obsolete attachment 206893 [details] so that this bug does not appear in http://webkit.org/pending-commit.