Closed
Bug 1467688
Opened 6 years ago
Closed 6 years ago
Style changes to perspective get their change hints ignored if the frame isn't also transformed.
Categories
(Core :: CSS Parsing and Computation, defect)
Core
CSS Parsing and Computation
Tracking
()
RESOLVED
FIXED
mozilla63
People
(Reporter: mattwoodrow, Assigned: mattwoodrow)
References
(Blocks 1 open bug)
Details
Attachments
(2 files)
163 bytes,
text/html
|
Details | |
59 bytes,
text/x-review-board-request
|
dbaron
:
review+
lizzard
:
approval-mozilla-beta+
|
Details |
nsStyleDisplay::CalcDifference set 'hint |= nsChangeHint_NeutralChange;' if HasTransformStyle returns false (which is the case for just perspective), and so ignores any change hints we generated for a new/different perspective value. Looks like this bug has existed since I first implemented perspective, the change hint checks were initially in an if (HasTransformStyle()) block.
Assignee | ||
Comment 1•6 years ago
|
||
Bug 1466954 has a crashtest that triggers this (and hits an RDL assertion).
See Also: → 1466954
Comment 2•6 years ago
|
||
Comment 3•6 years ago
|
||
FWIW, this is a crash report caused by the same reason. bp-16522335-6c5b-495b-928e-97fe40180613
Assignee | ||
Comment 4•6 years ago
|
||
Actually, the original description isn't quite right. The check for a changed value of HasPerspectiveStyle() sets the value of 'hint' and not 'transformHint', so it always applied. The bug here is that we only generate nsChangeHint_UpdateContainingBlock in that case (since the check for changes to mChildPerspective *is* scoped to transformed frame) and not nsChangeHint_RepaintFrame. The broken testcases are applying the new perspective to the document element (which is already a containing block for fixed elements), so it ends up being a no-op, and nothing invalidates for the newly added perspective. We do have an existing testcase for the normal case of this (layout/reftests/w3c-css/submitted/transforms/perspective-containing-block-dynamic-1b.html) and that passes already.
Comment hidden (mozreview-request) |
Comment 6•6 years ago
|
||
mozreview-review |
Comment on attachment 8986079 [details] Bug 1467688 - Make sure we invalidate for perspective changes even if the frame isn't otherwise transformed. https://reviewboard.mozilla.org/r/251528/#review257800 ::: layout/style/nsStyleStruct.cpp:3879 (Diff revision 1) > + if (HasPerspectiveStyle() != aNewData.HasPerspectiveStyle()) { > + // A change from/to being a containing block for position:fixed. > + hint |= nsChangeHint_UpdateContainingBlock | > + nsChangeHint_UpdateOverflow | > + nsChangeHint_RepaintFrame; > + } else if (mChildPerspective != aNewData.mChildPerspective) { > + hint |= nsChangeHint_UpdateOverflow | > + nsChangeHint_RepaintFrame; > + } > + I did now mostly same fix for this bug. :) I think we can rewrite this if-else block like this; ```c++ if (mChildPerspective != anewData.mChildPerspective) { hint |= nsChangeHint_UpdateOverflow | nsChangeHint_RepaintFrame; if (HasPerspectiveStyle()! = aNewData.HasPerspectiveStyle()) { hint |= nsChangeHint_UpdateContainingBlock; } } ```
Assignee | ||
Updated•6 years ago
|
Assignee: nobody → matt.woodrow
Comment 7•6 years ago
|
||
mozreview-review |
Comment on attachment 8986079 [details] Bug 1467688 - Make sure we invalidate for perspective changes even if the frame isn't otherwise transformed. https://reviewboard.mozilla.org/r/251528/#review258936 Seems like it might be good to add a reftest rather than just a crashtest?
Attachment #8986079 -
Flags: review?(dbaron) → review+
Comment 8•6 years ago
|
||
We're sorry, Autoland could not rebase your commits for you automatically. Please manually rebase your commits and try again. hg error in cmd: hg rebase -s 09fe2c0b64bbf5f7856e3216d1746ffd971f62f1 -d 5a560404cf9e: rebasing 470889:09fe2c0b64bb "Bug 1467688 - Make sure we invalidate for perspective changes even if the frame isn't otherwise transformed. r=dbaron" (tip) merging layout/base/crashtests/crashtests.list merging layout/style/nsStyleStruct.cpp warning: conflicts while merging layout/base/crashtests/crashtests.list! (edit, then use 'hg resolve --mark') unresolved conflicts (see hg resolve, then hg rebase --continue)
Comment hidden (mozreview-request) |
Comment 10•6 years ago
|
||
Pushed by mwoodrow@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/b976829f826a Make sure we invalidate for perspective changes even if the frame isn't otherwise transformed. r=dbaron
Comment 11•6 years ago
|
||
Backout by aciure@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/3446bd708e60 Backed out 1 changesets for reftest failures crashtests/1467688.html CLOSED TREE
Comment 12•6 years ago
|
||
Backed out 1 changesets (bug 1467688) for reftest failures crashtests/1467688.html push that caused the backout: https://treeherder.mozilla.org/#/jobs?repo=autoland&revision=b976829f826a7fba883fe1a088f5500a80c6441b&filter-resultStatus=testfailed&filter-resultStatus=busted&filter-resultStatus=exception&filter-classifiedState=unclassified failure: https://treeherder.mozilla.org/#/jobs?repo=autoland&filter-resultStatus=testfailed&filter-resultStatus=busted&filter-resultStatus=exception&filter-classifiedState=unclassified&selectedJob=186073241&filter-searchStr=Windows+10+x64+debug+Reftests+with+e10s+test-windows10-64%2Fdebug-crashtest-e10s+R-e10s%28C%29 log: https://treeherder.mozilla.org/logviewer.html#?job_id=186073241&repo=autoland backout: https://hg.mozilla.org/integration/autoland/rev/3446bd708e60fbe242415a6d44ea77c15f5ee8f6
Flags: needinfo?(matt.woodrow)
Comment hidden (mozreview-request) |
Comment 14•6 years ago
|
||
Pushed by mwoodrow@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/08ad3e81d9af Make sure we invalidate for perspective changes even if the frame isn't otherwise transformed. r=dbaron
Comment 15•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/08ad3e81d9af
Status: NEW → RESOLVED
Closed: 6 years ago
status-firefox63:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla63
Assignee | ||
Comment 16•6 years ago
|
||
Comment on attachment 8986079 [details] Bug 1467688 - Make sure we invalidate for perspective changes even if the frame isn't otherwise transformed. Approval Request Comment [Feature/Bug causing the regression]: RDL [User impact if declined]: Assertion crashes on Nightly/Dev Edition, potentially incorrect z-ordering on release (though usually temporary). [Is this code covered by automated tests?]: Crashtest added. [Has the fix been verified in Nightly?]: By me, yes [Needs manual test from QE? If yes, steps to reproduce]: No [List of other uplifts needed for the feature/fix]: None [Is the change risky?]: No [Why is the change risky/not risky?]: Just adds extra style change hints to make sure we invalidate. Should never be a problem to hint too many changes. [String changes made/needed]: None.
Flags: needinfo?(matt.woodrow)
Attachment #8986079 -
Flags: approval-mozilla-beta?
Comment 17•6 years ago
|
||
Comment on attachment 8986079 [details] Bug 1467688 - Make sure we invalidate for perspective changes even if the frame isn't otherwise transformed. Crash fix, adds new tests, let's uplift for beta 8.
Attachment #8986079 -
Flags: approval-mozilla-beta? → approval-mozilla-beta+
Comment 18•6 years ago
|
||
bugherder uplift |
https://hg.mozilla.org/releases/mozilla-beta/rev/2b3b18d4f22d
Flags: in-testsuite+
You need to log in
before you can comment on or make changes to this bug.
Description
•