Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(345)

Issue 26112002: cc: Fix hit-testing in zero-opacity layers. (Closed)

Created:
7 years, 2 months ago by sadrul
Modified:
7 years, 1 month ago
CC:
chromium-reviews, cc-bugs_chromium.org, jamesr, awong
Visibility:
Public.

Description

cc: Fix hit-testing in zero-opacity layers. If a layer that accepts touch or wheel events, but the layer (or one of its ancestor layers) has zero opacity, then make sure the layer hit-tests correctly. BUG=295295 R=enne@chromium.org, rbyers@google.com Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=232881

Patch Set 1 #

Patch Set 2 : child is zero-opacity no-handler, grandchild has handler #

Total comments: 3

Patch Set 3 : . #

Total comments: 5

Patch Set 4 : . #

Total comments: 8

Patch Set 5 : . #

Patch Set 6 : . #

Total comments: 10

Patch Set 7 : test #

Total comments: 7

Patch Set 8 : . #

Patch Set 9 : . #

Patch Set 10 : . #

Patch Set 11 : . #

Patch Set 12 : . #

Patch Set 13 : . #

Patch Set 14 : . #

Total comments: 6

Patch Set 15 : skip-drawing #

Patch Set 16 : self-nit #

Total comments: 2

Patch Set 17 : . #

Patch Set 18 : . #

Unified diffs Side-by-side diffs Delta from patch set Stats (+404 lines, -33 lines) Patch
M cc/layers/draw_properties.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 2 chunks +8 lines, -1 line 0 comments Download
M cc/test/fake_picture_layer_impl.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 3 chunks +5 lines, -0 lines 0 comments Download
M cc/test/fake_picture_layer_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 2 chunks +11 lines, -2 lines 0 comments Download
M cc/trees/layer_tree_host.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +1 line, -1 line 0 comments Download
M cc/trees/layer_tree_host_common.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 14 chunks +37 lines, -13 lines 0 comments Download
M cc/trees/layer_tree_host_common_unittest.cc View 1 2 3 4 5 6 7 8 9 10 7 chunks +156 lines, -11 lines 0 comments Download
M cc/trees/layer_tree_host_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +2 lines, -1 line 0 comments Download
M cc/trees/layer_tree_host_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 2 chunks +73 lines, -1 line 0 comments Download
M cc/trees/layer_tree_host_unittest_picture.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 2 chunks +74 lines, -0 lines 0 comments Download
M cc/trees/layer_tree_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 2 chunks +4 lines, -2 lines 0 comments Download
M cc/trees/occlusion_tracker.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -1 line 0 comments Download
M cc/trees/occlusion_tracker_unittest.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +32 lines, -0 lines 0 comments Download

Messages

Total messages: 41 (0 generated)
sadrul
I have added an obvious test case to make sure the hit-testing happens correctly. It ...
7 years, 2 months ago (2013-10-05 07:57:32 UTC) #1
enne (OOO)
https://codereview.chromium.org/26112002/diff/4001/cc/trees/layer_tree_host_common.cc File cc/trees/layer_tree_host_common.cc (right): https://codereview.chromium.org/26112002/diff/4001/cc/trees/layer_tree_host_common.cc#newcode73 cc/trees/layer_tree_host_common.cc:73: static bool LayerSubtreeCanAcceptInput(LayerType* layer) { On 2013/10/05 07:57:32, sadrul ...
7 years, 2 months ago (2013-10-05 16:40:18 UTC) #2
sadrul
https://codereview.chromium.org/26112002/diff/4001/cc/trees/layer_tree_host_common.cc File cc/trees/layer_tree_host_common.cc (right): https://codereview.chromium.org/26112002/diff/4001/cc/trees/layer_tree_host_common.cc#newcode73 cc/trees/layer_tree_host_common.cc:73: static bool LayerSubtreeCanAcceptInput(LayerType* layer) { On 2013/10/05 16:40:18, enne ...
7 years, 2 months ago (2013-10-05 21:09:05 UTC) #3
WRONG-USE-chromium
I don't know this cc code very well, but this LGTM. Dana?
7 years, 2 months ago (2013-10-07 16:01:09 UTC) #4
danakj
Can you skip painting/drawing layers that have a draw_properties().opacity() of 0 the same way you ...
7 years, 2 months ago (2013-10-07 16:29:13 UTC) #5
sadrul
https://codereview.chromium.org/26112002/diff/10001/cc/trees/layer_tree_host_common.cc File cc/trees/layer_tree_host_common.cc (right): https://codereview.chromium.org/26112002/diff/10001/cc/trees/layer_tree_host_common.cc#newcode465 cc/trees/layer_tree_host_common.cc:465: On 2013/10/07 16:29:13, danakj wrote: > Can you add ...
7 years, 2 months ago (2013-10-07 17:16:48 UTC) #6
enne (OOO)
https://codereview.chromium.org/26112002/diff/20001/cc/trees/layer_tree_host_common.cc File cc/trees/layer_tree_host_common.cc (right): https://codereview.chromium.org/26112002/diff/20001/cc/trees/layer_tree_host_common.cc#newcode468 cc/trees/layer_tree_host_common.cc:468: return !layer->draw_opacity() && !layer->draw_opacity_is_animating(); I'm not sure this is ...
7 years, 2 months ago (2013-10-07 17:27:23 UTC) #7
danakj
https://codereview.chromium.org/26112002/diff/10001/cc/trees/layer_tree_host_common.cc File cc/trees/layer_tree_host_common.cc (right): https://codereview.chromium.org/26112002/diff/10001/cc/trees/layer_tree_host_common.cc#newcode465 cc/trees/layer_tree_host_common.cc:465: On 2013/10/07 17:16:49, sadrul wrote: > On 2013/10/07 16:29:13, ...
7 years, 2 months ago (2013-10-07 17:37:35 UTC) #8
enne (OOO)
https://codereview.chromium.org/26112002/diff/20001/cc/trees/layer_tree_host_common.cc File cc/trees/layer_tree_host_common.cc (right): https://codereview.chromium.org/26112002/diff/20001/cc/trees/layer_tree_host_common.cc#newcode468 cc/trees/layer_tree_host_common.cc:468: return !layer->draw_opacity() && !layer->draw_opacity_is_animating(); On 2013/10/07 17:37:35, danakj wrote: ...
7 years, 2 months ago (2013-10-07 17:45:51 UTC) #9
danakj
On 2013/10/07 17:45:51, enne wrote: > https://codereview.chromium.org/26112002/diff/20001/cc/trees/layer_tree_host_common.cc > File cc/trees/layer_tree_host_common.cc (right): > > https://codereview.chromium.org/26112002/diff/20001/cc/trees/layer_tree_host_common.cc#newcode468 > ...
7 years, 2 months ago (2013-10-07 17:49:07 UTC) #10
sadrul
https://codereview.chromium.org/26112002/diff/10001/cc/trees/layer_tree_host_common.cc File cc/trees/layer_tree_host_common.cc (right): https://codereview.chromium.org/26112002/diff/10001/cc/trees/layer_tree_host_common.cc#newcode465 cc/trees/layer_tree_host_common.cc:465: On 2013/10/07 17:37:35, danakj wrote: > On 2013/10/07 17:16:49, ...
7 years, 2 months ago (2013-10-07 18:37:24 UTC) #11
danakj
https://codereview.chromium.org/26112002/diff/10001/cc/trees/layer_tree_host_common.cc File cc/trees/layer_tree_host_common.cc (right): https://codereview.chromium.org/26112002/diff/10001/cc/trees/layer_tree_host_common.cc#newcode465 cc/trees/layer_tree_host_common.cc:465: On 2013/10/07 18:37:24, sadrul wrote: > On 2013/10/07 17:37:35, ...
7 years, 2 months ago (2013-10-07 19:02:35 UTC) #12
sadrul
ping
7 years, 2 months ago (2013-10-08 18:13:19 UTC) #13
danakj
https://codereview.chromium.org/26112002/diff/37001/cc/trees/layer_tree_host_common.cc File cc/trees/layer_tree_host_common.cc (right): https://codereview.chromium.org/26112002/diff/37001/cc/trees/layer_tree_host_common.cc#newcode425 cc/trees/layer_tree_host_common.cc:425: bool visit_for_event_handler_only) { how about bool "layer_has_zero_opacity"? only is ...
7 years, 2 months ago (2013-10-08 18:32:32 UTC) #14
danakj
Some more combinatorially different cases to cover - the layer having a child, the layer ...
7 years, 2 months ago (2013-10-09 19:14:59 UTC) #15
sadrul
https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc File cc/trees/layer_tree_host_common_unittest.cc (right): https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc#newcode5596 cc/trees/layer_tree_host_common_unittest.cc:5596: zero_opacity_raw->render_surface()->layer_list().size()); One of the issues I ran into is ...
7 years, 2 months ago (2013-10-10 17:08:45 UTC) #16
danakj
https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc File cc/trees/layer_tree_host_common_unittest.cc (right): https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc#newcode5596 cc/trees/layer_tree_host_common_unittest.cc:5596: zero_opacity_raw->render_surface()->layer_list().size()); On 2013/10/10 17:08:46, sadrul wrote: > One of ...
7 years, 2 months ago (2013-10-10 17:16:38 UTC) #17
sadrul
https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc File cc/trees/layer_tree_host_common_unittest.cc (right): https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc#newcode5596 cc/trees/layer_tree_host_common_unittest.cc:5596: zero_opacity_raw->render_surface()->layer_list().size()); On 2013/10/10 17:16:38, danakj wrote: > On 2013/10/10 ...
7 years, 2 months ago (2013-10-10 17:41:39 UTC) #18
sadrul
https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc File cc/trees/layer_tree_host_common_unittest.cc (right): https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc#newcode5587 cc/trees/layer_tree_host_common_unittest.cc:5587: EXPECT_EQ(kRootId, render_surface_layer_list[0]->id()); The other issue I am hitting is, ...
7 years, 2 months ago (2013-10-10 18:01:30 UTC) #19
enne (OOO)
https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc File cc/trees/layer_tree_host_common_unittest.cc (right): https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc#newcode5587 cc/trees/layer_tree_host_common_unittest.cc:5587: EXPECT_EQ(kRootId, render_surface_layer_list[0]->id()); On 2013/10/10 18:01:31, sadrul wrote: > The ...
7 years, 2 months ago (2013-10-15 17:56:49 UTC) #20
sadrul
On 2013/10/15 17:56:49, enne wrote: > https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc > File cc/trees/layer_tree_host_common_unittest.cc (right): > > https://codereview.chromium.org/26112002/diff/46001/cc/trees/layer_tree_host_common_unittest.cc#newcode5587 > ...
7 years, 2 months ago (2013-10-17 20:40:10 UTC) #21
enne (OOO)
On 2013/10/17 20:40:10, sadrul wrote: > > One alternative that Dana and I talked out ...
7 years, 2 months ago (2013-10-17 21:09:51 UTC) #22
danakj
On Thu, Oct 17, 2013 at 5:09 PM, <enne@chromium.org> wrote: > On 2013/10/17 20:40:10, sadrul ...
7 years, 2 months ago (2013-10-17 21:16:18 UTC) #23
enne (OOO)
+jamesr, ajwong for surface implications FYI sadrul/danakj/enne had a talk yesterday about how to handle ...
7 years, 2 months ago (2013-10-18 19:09:10 UTC) #24
jamesr
Option #3 is to be more conservative and map an inflated version of an invisible-layer-with-hit-regions ...
7 years, 2 months ago (2013-10-18 19:13:24 UTC) #25
danakj
On Fri, Oct 18, 2013 at 3:13 PM, <jamesr@chromium.org> wrote: > Option #3 is to ...
7 years, 2 months ago (2013-10-18 19:30:52 UTC) #26
sadrul
> > (2) Disable early-outs for layers and subtrees in CalcDrawProperties. > > Once the ...
7 years, 1 month ago (2013-10-26 04:05:37 UTC) #27
enne (OOO)
On 2013/10/26 04:05:37, sadrul wrote: > > > > (2) Disable early-outs for layers and ...
7 years, 1 month ago (2013-10-26 05:00:50 UTC) #28
sadrul
On 2013/10/26 05:00:50, enne wrote: > On 2013/10/26 04:05:37, sadrul wrote: > > > > ...
7 years, 1 month ago (2013-10-29 22:06:18 UTC) #29
enne (OOO)
https://codereview.chromium.org/26112002/diff/339001/cc/trees/layer_tree_host.cc File cc/trees/layer_tree_host.cc (right): https://codereview.chromium.org/26112002/diff/339001/cc/trees/layer_tree_host.cc#newcode1061 cc/trees/layer_tree_host.cc:1061: bool zero_opacity = !it->draw_opacity() && Zero opacity is not ...
7 years, 1 month ago (2013-10-29 23:54:21 UTC) #30
sadrul
https://codereview.chromium.org/26112002/diff/339001/cc/trees/layer_tree_host_common.cc File cc/trees/layer_tree_host_common.cc (right): https://codereview.chromium.org/26112002/diff/339001/cc/trees/layer_tree_host_common.cc#newcode464 cc/trees/layer_tree_host_common.cc:464: if (layer->draw_properties().layer_or_descendant_has_event_handler) On 2013/10/29 23:54:22, enne wrote: > I ...
7 years, 1 month ago (2013-10-30 05:20:20 UTC) #31
sadrul
https://codereview.chromium.org/26112002/diff/339001/cc/trees/layer_tree_host.cc File cc/trees/layer_tree_host.cc (right): https://codereview.chromium.org/26112002/diff/339001/cc/trees/layer_tree_host.cc#newcode1061 cc/trees/layer_tree_host.cc:1061: bool zero_opacity = !it->draw_opacity() && On 2013/10/29 23:54:22, enne ...
7 years, 1 month ago (2013-10-30 15:44:41 UTC) #32
enne (OOO)
On 2013/10/30 05:20:20, sadrul wrote: > To explain with an example: > > Root > ...
7 years, 1 month ago (2013-10-30 22:20:49 UTC) #33
sadrul
On 2013/10/30 22:20:49, enne wrote: > On 2013/10/30 05:20:20, sadrul wrote: > > > To ...
7 years, 1 month ago (2013-10-30 22:25:57 UTC) #34
enne (OOO)
> Right. Perhaps DataForRecursion is not the right place for this, and this should > ...
7 years, 1 month ago (2013-10-31 18:15:12 UTC) #35
sadrul
> > Right. Perhaps DataForRecursion is not the right place for this, and this > ...
7 years, 1 month ago (2013-10-31 22:49:54 UTC) #36
enne (OOO)
On 2013/10/31 22:49:54, sadrul wrote: > > I think there needs to be some more ...
7 years, 1 month ago (2013-11-01 18:38:21 UTC) #37
enne (OOO)
Also, I think that the iteration over layers to UpdateTilePriorities inside of LayerTreeImpl::UpdateDrawProperties should respect ...
7 years, 1 month ago (2013-11-04 19:49:20 UTC) #38
sadrul
On 2013/11/01 18:38:21, enne wrote: > On 2013/10/31 22:49:54, sadrul wrote: > > > > ...
7 years, 1 month ago (2013-11-04 21:52:59 UTC) #39
enne (OOO)
lgtm, thanks! jamesr/awong FYI: when the site isolation folks want to start hit-testing in the ...
7 years, 1 month ago (2013-11-04 23:28:42 UTC) #40
sadrul
7 years, 1 month ago (2013-11-05 02:08:36 UTC) #41
Message was sent while issue was closed.
Committed patchset #18 manually as r232881 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698