Bug 1509425 - Undo an optimization that unexpectedly affected hit testing. r=bas
authorMarkus Stange <mstange@themasta.com>
Wed, 23 Jan 2019 03:53:11 +0000
changeset 514951 519c1045b51e55ece9e463d38412fbf93a37a3d3
parent 514950 e0ff6bf01a9f82c228a6890026d78c34a1bc95d9
child 514952 8dee9d61a77b4613be713577873eac447c1a5ece
push id1953
push userffxbld-merge
push dateMon, 11 Mar 2019 12:10:20 +0000
treeherdermozilla-release@9c35dcbaa899 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbas
bugs1509425
milestone66.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1509425 - Undo an optimization that unexpectedly affected hit testing. r=bas Differential Revision: https://phabricator.services.mozilla.com/D16912
gfx/src/FilterSupport.cpp
layout/reftests/bugs/1509425-1-ref.html
layout/reftests/bugs/1509425-1.html
layout/reftests/bugs/reftest.list
--- a/gfx/src/FilterSupport.cpp
+++ b/gfx/src/FilterSupport.cpp
@@ -1597,19 +1597,16 @@ nsIntRegion FilterSupport::PostFilterExt
       if (ResultOfZeroUnderTransferFunction(aComponentTransfer, kChannelA) >
           0.0f) {
         return mDescription.PrimitiveSubregion();
       }
       return mInputExtents[0];
     }
 
     nsIntRegion match(const OpacityAttributes& aOpacity) {
-      if (aOpacity.mOpacity == 0.0f) {
-        return IntRect();
-      }
       return ResultChangeRegionForPrimitive(mDescription, mInputExtents);
     }
 
     nsIntRegion match(const ConvolveMatrixAttributes& aConvolveMatrix) {
       return ResultChangeRegionForPrimitive(mDescription, mInputExtents);
     }
 
     nsIntRegion match(const OffsetAttributes& aOffset) {
new file mode 100644
--- /dev/null
+++ b/layout/reftests/bugs/1509425-1-ref.html
@@ -0,0 +1,7 @@
+<!DOCTYPE html>
+<html lang="en">
+<meta charset="utf-8">
+
+<title>Reference for bug 1271714: should say PASS</title>
+
+<p>PASS</p>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/bugs/1509425-1.html
@@ -0,0 +1,28 @@
+<!DOCTYPE html>
+<html lang="en">
+<meta charset="utf-8">
+
+<title>Bug 1271714: Hit testing should be able to find the .opacityFilter element</title>
+
+<style type="text/css">
+
+#opacityFilter {
+  border: 1px solid black;
+  height: 200px;
+  width: 200px;
+  filter: opacity(0);
+}
+
+</style>
+
+<p id="output">FAIL</p>
+
+<div id="opacityFilter"></div>
+
+<script>
+
+if (document.elementFromPoint(100, 100).id == "opacityFilter") {
+  document.getElementById("output").textContent = "PASS";
+}
+
+</script>
--- a/layout/reftests/bugs/reftest.list
+++ b/layout/reftests/bugs/reftest.list
@@ -2103,9 +2103,10 @@ fuzzy(0-1,0-625) == 1466638-1.html 14666
 == bug1472465-1.html bug1472465-1-ref.html
 == 1475971-1.html 1475971-1-ref.html
 == 1483649-1.xul 1483649-1-ref.xul
 test-pref(layout.css.contain.enabled,true) == 1483946.html 1483946-ref.html
 test-pref(layout.css.visited_links_enabled,false) == 1488155.html 1488155-ref.html
 == 1492660-1.html 1492660-1-ref.html
 pref(layout.css.supports-selector.enabled,true) == 1499386.html 1499386-ref.html
 pref(layout.css.supports-selector.enabled,false) != 1499386.html 1499386-ref.html
+== 1509425-1.html 1509425-1-ref.html
 == 1511570.html 1511570-ref.html