Closed
Bug 1319825
Opened 8 years ago
Closed 8 years ago
Click event not fired in Firefox 50
Categories
(Core :: Layout, defect)
Tracking
()
People
(Reporter: lorenzo.benvenuti, Assigned: mattwoodrow)
References
Details
(Keywords: regression)
Attachments
(1 file)
4.58 KB,
patch
|
tnikkel
:
review+
gchang
:
approval-mozilla-aurora+
jcristau
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
User Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/51.0.2704.103 Safari/537.36
Steps to reproduce:
Hi,
after updating to Firefox 50 my web application started behaving in a strange way: some clicks were lost. I was able to isolate the behaviour in a simple case; consider the following code:
HTML
<div id="myButton" tabindex="0" role="button" class="v-button v-widget">
<span class="v-button-wrap">
<img class="v-icon" src="https://encrypted-tbn2.gstatic.com/images?q=tbn:ANd9GcRWnTfnFJJkFy1YBmaZNX4jp3emkdGD0XJdT7A4sE246CJ1kBRs" alt="">
<span class="v-button-caption">A button</span>
</span>
</div>
Javascript:
document.getElementById("myButton").addEventListener("click", function(event) { alert("Hi!");});
CSS:
.v-button {
height: 150px;
width: 150px;
}
.v-button {
-webkit-transform-style: preserve-3d;
-moz-transform-style: preserve-3d;
transform-style: preserve-3d;
}
.v-button-wrap {
display: block;
position: relative;
top: 50%;
-webkit-transform: translateY(-50%);
-ms-transform: translateY(-50%);
transform: translateY(-50%);
}
.v-button:active {
opacity: 0.7;
}
If you try to click on the image you can see two strange behaviours:
- The image disappears (instead of becoming semi-transparent)
- The alert (opened via click event listener) is not shown
The issue disappears if one of these conditions is satisfied:
- The "transform-style" properties are not set
- The ".v-button-wrapper" "display" property is not set to "block"
- The "opacity" property is not set
The application used to work correctly in Firefox 49 and previous (and still works in Chrome, IE11 and Edge).
Actual results:
When clicking on the image, image disappears and click event is not fired
Expected results:
Image should become slightly transparent and a fire event should be triggered
Reporter | ||
Comment 1•8 years ago
|
||
You can check this fiddle:
https://jsfiddle.net/tabhtu61/3/
Regression range:
https://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=067521
ccd17907843e1db644ca0f02a1f5a6520a&tochange=eac0c056235ee1174fc092fe159d2d571033
1fbd
Matt Woodrow — Bug 1283827 - Flatten transform-style:preserve-3d when combined with opacity. r=dbaron
Matt, could you check if it's normal that's the event is not fired after the spec change in bug 1283827.
Blocks: 1283827
Component: Untriaged → Layout
Flags: needinfo?(matt.woodrow)
Keywords: regression
OS: Unspecified → All
Product: Firefox → Core
Hardware: Unspecified → All
Updated•8 years ago
|
status-firefox50:
--- → wontfix
status-firefox51:
--- → affected
status-firefox52:
--- → affected
status-firefox53:
--- → affected
tracking-firefox51:
--- → ?
tracking-firefox52:
--- → ?
tracking-firefox53:
--- → ?
Comment 3•8 years ago
|
||
Too late for 51, but we can still take patches for 52/53.
Assignee | ||
Comment 4•8 years ago
|
||
Having the opacity property disables preserve-3d (making that change was what regressed this).
Preserve-3d frames do crazy things with overflow areas, so when we transition in/out of having opacity, we need to make sure we recompute the overflow areas.
Are you ok with reviewing this Timothy? Dbaron isn't accepting review requests at the moment.
Assignee: nobody → matt.woodrow
Flags: needinfo?(matt.woodrow)
Attachment #8825596 -
Flags: review?(tnikkel)
Updated•8 years ago
|
Attachment #8825596 -
Flags: review?(tnikkel) → review+
Pushed by mwoodrow@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/38a92c2df699
Update the overflow areas of all descendants when we toggle opacity on a preserve-3d frame. r=tnikkel
Pushed by philringnalda@gmail.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/3d13ed042963
followup, fix rebasing oops
Comment 7•8 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/38a92c2df699
https://hg.mozilla.org/mozilla-central/rev/3d13ed042963
Status: UNCONFIRMED → RESOLVED
Closed: 8 years ago
status-firefox54:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla54
Comment 8•8 years ago
|
||
Please request Aurora/Beta approval on this when you get a chance.
Assignee | ||
Comment 9•8 years ago
|
||
Comment on attachment 8825596 [details] [diff] [review]
Update overflow areas when opacity toggles
Approval Request Comment
[Feature/Bug causing the regression]: Bug 1283827
[User impact if declined]: Invalid rendering when dynamically toggling opacity in the presence of preserve-3d, relatively rare.
[Is this code covered by automated tests?]: Yes, new reftest added.
[Has the fix been verified in Nightly?]:
[Needs manual test from QE? If yes, steps to reproduce]: No
[List of other uplifts needed for the feature/fix]: Just this patch
[Is the change risky?]: No
[Why is the change risky/not risky?]: Just increases the work when we do when we detect an opacity style change. It should never be dangerous to do more than necessary.
[String changes made/needed]: None
Flags: needinfo?(matt.woodrow)
Attachment #8825596 -
Flags: approval-mozilla-beta?
Attachment #8825596 -
Flags: approval-mozilla-aurora?
Comment 10•8 years ago
|
||
Hi Brindusa,
Could you help find someone to verify if this issue was fixed as expected on a latest Nightly build? Thanks!
Flags: needinfo?(brindusa.tot)
Comment 11•8 years ago
|
||
Verified as fixed on 54.0a1 20170215110151 on Ubuntu 16.04 x64, Windows 10 x64, OSX 10.10.
Updated•8 years ago
|
Flags: needinfo?(brindusa.tot)
Comment 12•8 years ago
|
||
Comment on attachment 8825596 [details] [diff] [review]
Update overflow areas when opacity toggles
Fix a rendering issue when dynamically toggling opacity in the presence of preserve-3d. Aurora53+.
Attachment #8825596 -
Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Comment 13•8 years ago
|
||
Comment on attachment 8825596 [details] [diff] [review]
Update overflow areas when opacity toggles
fix opacity vs preserve-3d interaction, beta52+
Attachment #8825596 -
Flags: approval-mozilla-beta? → approval-mozilla-beta+
Comment 14•8 years ago
|
||
Matt, seems this still hit conflicts in layout/reftests/transform-3d/reftest.list for aurora
could you take a look, thanks!
Flags: needinfo?(matt.woodrow)
Comment 15•8 years ago
|
||
bugherder uplift |
Updated•8 years ago
|
Flags: needinfo?(matt.woodrow)
Comment 16•8 years ago
|
||
bugherder uplift |
Comment 17•8 years ago
|
||
bugherder uplift |
status-firefox-esr52:
--- → fixed
You need to log in
before you can comment on or make changes to this bug.
Description
•