Bug 138122 - Transform-style should not kill position:fixed
Summary: Transform-style should not kill position:fixed
Status: RESOLVED FIXED
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:
: 138123 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-10-27 21:25 PDT by Simon Fraser (smfr)
Modified: 2022-07-13 00:54 PDT (History)
5 users (show)

See Also:


Attachments
Testcase (711 bytes, text/html)
2014-10-27 21:25 PDT, Simon Fraser (smfr)
no flags Details
Standalone testcase (1.04 KB, text/html)
2014-12-09 22:35 PST, Simon Fraser (smfr)
no flags Details
Patch (50.16 KB, patch)
2014-12-11 14:34 PST, Simon Fraser (smfr)
buildbot: commit-queue-
Details | Formatted Diff | Diff
Patch (50.16 KB, patch)
2014-12-11 14:54 PST, Simon Fraser (smfr)
dino: review+
buildbot: commit-queue-
Details | Formatted Diff | Diff
Archive of layout-test-results from ews106 for mac-mountainlion-wk2 (509.89 KB, application/zip)
2014-12-11 15:46 PST, Build Bot
no flags Details
Archive of layout-test-results from ews104 for mac-mountainlion-wk2 (512.00 KB, application/zip)
2014-12-11 15:49 PST, Build Bot
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Fraser (smfr) 2014-10-27 21:25:22 PDT
Created attachment 240523 [details]
Testcase

Attached testase scrolls incorrectly.
Comment 1 Simon Fraser (smfr) 2014-12-09 22:35:16 PST
Created attachment 242989 [details]
Standalone testcase
Comment 2 Simon Fraser (smfr) 2014-12-11 10:49:20 PST
We're generally confused about what hasTransform means. See https://www.w3.org/Bugs/Public/show_bug.cgi?id=27566
Comment 3 Simon Fraser (smfr) 2014-12-11 14:34:22 PST
Created attachment 243147 [details]
Patch
Comment 4 Simon Fraser (smfr) 2014-12-11 14:54:36 PST
Created attachment 243150 [details]
Patch
Comment 5 Dean Jackson 2014-12-11 14:59:50 PST
Comment on attachment 243147 [details]
Patch

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

> Source/WebCore/ChangeLog:9
> +        Various bits of rendering code checked RenderObject::hasTransform() for various
> +        reasons. Confusingly, this meant "has transform, or preserve-3d, or perspective".

First sentence sense make no.

> Source/WebCore/rendering/RenderBox.cpp:-1921
> -    bool hasTransform = hasLayer() && layer()->transform();

You're now calling hasTransform() three times in this method. I'm not sure removing the local variable is worth it.

> Source/WebCore/rendering/RenderObject.cpp:1651
> -    return (hasLayer() && downcast<RenderLayerModelObject>(*this).layer()->transform()) || (containerObject && containerObject->style().hasPerspective());
> +    return hasTransform() || (containerObject && containerObject->style().hasPerspective());

Why did we do it this way originally? ie. why were we going to the layer rather than looking at the style (the new way)?
Comment 6 Dean Jackson 2014-12-11 15:00:30 PST
Comment on attachment 243150 [details]
Patch

Already reviewed the first one. Although my first comment was wrong.
Comment 7 Dean Jackson 2014-12-11 15:01:02 PST
(In reply to comment #5)
> Comment on attachment 243147 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=243147&action=review
> 
> > Source/WebCore/ChangeLog:9
> > +        Various bits of rendering code checked RenderObject::hasTransform() for various
> > +        reasons. Confusingly, this meant "has transform, or preserve-3d, or perspective".
> 
> First sentence sense make no.

Ignore this comment. I read it again and it makes sense now :|
Comment 8 Simon Fraser (smfr) 2014-12-11 15:04:14 PST
(In reply to comment #5)
> Comment on attachment 243147 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=243147&action=review
> 
> > Source/WebCore/ChangeLog:9
> > +        Various bits of rendering code checked RenderObject::hasTransform() for various
> > +        reasons. Confusingly, this meant "has transform, or preserve-3d, or perspective".
> 
> First sentence sense make no.
> 
> > Source/WebCore/rendering/RenderBox.cpp:-1921
> > -    bool hasTransform = hasLayer() && layer()->transform();
> 
> You're now calling hasTransform() three times in this method. I'm not sure
> removing the local variable is worth it.

Actually only once. It's called twice in another function, but only once in each code path.

> > Source/WebCore/rendering/RenderObject.cpp:1651
> > -    return (hasLayer() && downcast<RenderLayerModelObject>(*this).layer()->transform()) || (containerObject && containerObject->style().hasPerspective());
> > +    return hasTransform() || (containerObject && containerObject->style().hasPerspective());
> 
> Why did we do it this way originally? ie. why were we going to the layer
> rather than looking at the style (the new way)?

I think we could have done style().hasTransform(), but the hasLayer() check is a bit check, so cheaper.
Comment 9 Simon Fraser (smfr) 2014-12-11 15:25:51 PST
*** Bug 138123 has been marked as a duplicate of this bug. ***
Comment 10 Build Bot 2014-12-11 15:46:06 PST
Comment on attachment 243147 [details]
Patch

Attachment 243147 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.appspot.com/results/6226423039655936

New failing tests:
compositing/tiling/rotated-tiled-preserve3d-clamped.html
Comment 11 Build Bot 2014-12-11 15:46:08 PST
Created attachment 243159 [details]
Archive of layout-test-results from ews106 for mac-mountainlion-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews106  Port: mac-mountainlion-wk2  Platform: Mac OS X 10.8.5
Comment 12 Build Bot 2014-12-11 15:49:55 PST
Comment on attachment 243150 [details]
Patch

Attachment 243150 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.appspot.com/results/5174337514504192

New failing tests:
compositing/tiling/rotated-tiled-preserve3d-clamped.html
Comment 13 Build Bot 2014-12-11 15:49:58 PST
Created attachment 243160 [details]
Archive of layout-test-results from ews104 for mac-mountainlion-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews104  Port: mac-mountainlion-wk2  Platform: Mac OS X 10.8.5
Comment 14 Simon Fraser (smfr) 2014-12-11 17:59:10 PST
https://trac.webkit.org/r177200