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

Issue 2265393002: Refactor compositor event handling path to be callback-based (Closed)

Created:
4 years, 4 months ago by chongz
Modified:
4 years, 3 months ago
CC:
anandc+watch-blimp_chromium.org, chromium-reviews, darin-cc_chromium.org, dtapuska+chromiumwatch_chromium.org, dtrainor+watch-blimp_chromium.org, gcasto+watch-blimp_chromium.org, jam, jessicag+watch-blimp_chromium.org, khushalsagar+watch-blimp_chromium.org, kmarshall+watch-blimp_chromium.org, lethalantidote+watch-blimp_chromium.org, maniscalco+watch-blimp_chromium.org, marcinjb+watch-blimp_chromium.org, mlamouri+watch-content_chromium.org, nyquist+watch-blimp_chromium.org, shaktisahu+watch-blimp_chromium.org, sriramsr+watch-blimp_chromium.org, tdresser+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Refactor compositor event handling path to be callback-based (A pre-work for compositor VSync aligned input.) This CL adds |DidHandleInputEventAndOverscroll| method, and will be passed to |HandleInputEvent| as callback. (It's hard to use interface-based implementation as |CompositorMusConnection| already has callback-based method baked in.) New event path: 1. |InputEventFilter| |DidForwardToHandlerAndOverscroll| V ^ |InputHandlerManager| |DidHandleInputEventAndOverscroll| V ^ |InputHandlerProxy| -> (handle event) 2. |CompositorMusConnection| |DidHandle...AndOverscroll| V ^ |InputHandlerManager| |DidHandleInputEventAndOverscroll| V ^ |InputHandlerProxy| -> (handle event) 3. (other sources) ..Wrapper->..Manager->..Filter::DidOverscroll V ^ |InputHandlerProxy| -> (did overscroll) Note about overscroll: Only one of |DidOverscroll| or |DidHandleInputEventAndOverscroll| will be fired, and it's decided by whether it's caused by an InputEvent. Note about event queue: Events are still handled synchronously in |InputHandlerProxy|, following up CLs will support event queue. Design Doc: (@chromium.org) https://docs.google.com/a/chromium.org/document/d/1SUPPJkqxEYMRso3Jw1wZnqD3g1dmif0ic-x5aQkpHBo/edit?usp=sharing BUG=637393 Committed: https://crrev.com/78f276e96eac5a447149fafac0b4953eb5936979 Cr-Commit-Position: refs/heads/master@{#417788}

Patch Set 1 #

Total comments: 7

Patch Set 2 : dtapuska's review, rename to DidHandleInputEventAndOverScroll #

Total comments: 5

Patch Set 3 : dtapuska's review 2, use WeakPtr, tweak comments #

Total comments: 13

Patch Set 4 : tdresser's review #

Total comments: 2

Patch Set 5 : creis's review, rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+214 lines, -105 lines) Patch
M content/renderer/input/input_event_filter.h View 1 2 3 4 2 chunks +7 lines, -5 lines 0 comments Download
M content/renderer/input/input_event_filter.cc View 1 2 3 4 5 chunks +15 lines, -20 lines 0 comments Download
M content/renderer/input/input_event_filter_unittest.cc View 1 1 chunk +14 lines, -8 lines 0 comments Download
M content/renderer/input/input_handler_manager.h View 1 2 3 4 chunks +19 lines, -4 lines 0 comments Download
M content/renderer/input/input_handler_manager.cc View 1 2 3 4 chunks +25 lines, -8 lines 0 comments Download
M content/renderer/input/input_handler_manager_client.h View 1 2 3 2 chunks +5 lines, -5 lines 0 comments Download
M content/renderer/input/input_handler_wrapper.h View 1 1 chunk +4 lines, -5 lines 0 comments Download
M content/renderer/mus/compositor_mus_connection.h View 1 2 3 4 3 chunks +10 lines, -1 line 0 comments Download
M content/renderer/mus/compositor_mus_connection.cc View 1 2 3 4 4 chunks +31 lines, -8 lines 0 comments Download
M content/renderer/mus/compositor_mus_connection_unittest.cc View 1 2 3 4 5 chunks +22 lines, -17 lines 0 comments Download
M content/renderer/mus/render_widget_mus_connection.h View 1 chunk +1 line, -1 line 0 comments Download
M content/renderer/mus/render_widget_mus_connection.cc View 1 chunk +1 line, -1 line 0 comments Download
M ui/events/blink/input_handler_proxy.h View 1 2 3 4 chunks +21 lines, -6 lines 0 comments Download
M ui/events/blink/input_handler_proxy.cc View 1 2 3 4 7 chunks +36 lines, -16 lines 0 comments Download
M ui/events/blink/input_handler_proxy_client.h View 1 2 3 1 chunk +3 lines, -0 lines 0 comments Download

Messages

Total messages: 63 (43 generated)
chongz
dtapuska@ PTAL, thanks! https://codereview.chromium.org/2265393002/diff/1/content/renderer/input/input_event_filter.h File content/renderer/input/input_event_filter.h (left): https://codereview.chromium.org/2265393002/diff/1/content/renderer/input/input_event_filter.h#oldcode127 content/renderer/input/input_event_filter.h:127: std::unique_ptr<ui::DidOverscrollParams>* current_overscroll_params_; |DidOverscrollParams| handling moved to ...
4 years, 4 months ago (2016-08-23 04:35:24 UTC) #8
dtapuska
https://codereview.chromium.org/2265393002/diff/1/content/renderer/input/input_handler_manager.h File content/renderer/input/input_handler_manager.h (right): https://codereview.chromium.org/2265393002/diff/1/content/renderer/input/input_handler_manager.h#newcode91 content/renderer/input/input_handler_manager.h:91: void DidOverscroll(int routing_id, I find this DidOverscroll vs DidHandleInputEvent ...
4 years, 4 months ago (2016-08-23 19:34:11 UTC) #10
chongz
https://codereview.chromium.org/2265393002/diff/1/content/renderer/input/input_handler_manager.h File content/renderer/input/input_handler_manager.h (right): https://codereview.chromium.org/2265393002/diff/1/content/renderer/input/input_handler_manager.h#newcode91 content/renderer/input/input_handler_manager.h:91: void DidOverscroll(int routing_id, On 2016/08/23 19:34:10, dtapuska wrote: > ...
4 years, 4 months ago (2016-08-23 23:40:34 UTC) #12
chongz
dtapuska@ I've made a compromise solution to our last discussion and updated CL description, PTAL, ...
4 years, 3 months ago (2016-08-30 17:58:03 UTC) #33
dtapuska
seems reasonable to me. https://codereview.chromium.org/2265393002/diff/60001/content/renderer/input/input_handler_manager.cc File content/renderer/input/input_handler_manager.cc (right): https://codereview.chromium.org/2265393002/diff/60001/content/renderer/input/input_handler_manager.cc#newcode224 content/renderer/input/input_handler_manager.cc:224: base::Unretained(this), callback)); What is the ...
4 years, 3 months ago (2016-08-30 18:33:50 UTC) #34
chongz
dtapuska@ I've updated as per your comments, PTAL again, thanks! https://codereview.chromium.org/2265393002/diff/60001/content/renderer/input/input_handler_manager.cc File content/renderer/input/input_handler_manager.cc (right): https://codereview.chromium.org/2265393002/diff/60001/content/renderer/input/input_handler_manager.cc#newcode224 ...
4 years, 3 months ago (2016-08-30 19:47:04 UTC) #37
chongz
tdresser@ PTAL, thanks!
4 years, 3 months ago (2016-08-31 14:56:47 UTC) #40
tdresser
This LGTM to me at a high level, but wait for Dave's more thorough review. ...
4 years, 3 months ago (2016-09-01 16:58:45 UTC) #41
chongz
dtapuska@ PTAL, thanks! https://codereview.chromium.org/2265393002/diff/80001/content/renderer/input/input_handler_manager.h File content/renderer/input/input_handler_manager.h (right): https://codereview.chromium.org/2265393002/diff/80001/content/renderer/input/input_handler_manager.h#newcode129 content/renderer/input/input_handler_manager.h:129: using EventDisposition = ui::InputHandlerProxy::EventDisposition; On 2016/09/01 ...
4 years, 3 months ago (2016-09-01 20:13:13 UTC) #44
tdresser
https://codereview.chromium.org/2265393002/diff/80001/ui/events/blink/input_handler_proxy.cc File ui/events/blink/input_handler_proxy.cc (right): https://codereview.chromium.org/2265393002/diff/80001/ui/events/blink/input_handler_proxy.cc#newcode64 ui/events/blink/input_handler_proxy.cc:64: const bool kBundleAckWithTriggeringEvent = true; On 2016/09/01 20:13:13, chongz ...
4 years, 3 months ago (2016-09-01 21:08:11 UTC) #47
dtapuska
lgtm
4 years, 3 months ago (2016-09-02 15:20:52 UTC) #48
chongz
ben@ PTAL, thanks!
4 years, 3 months ago (2016-09-02 15:34:24 UTC) #50
chongz
ben@ can you take a look at this CL please? Thanks!
4 years, 3 months ago (2016-09-07 17:16:21 UTC) #51
chongz
creis@ PTAL, thanks! (Seems Ben is not available)
4 years, 3 months ago (2016-09-09 17:25:08 UTC) #53
Charlie Reis
RS LGTM. https://codereview.chromium.org/2265393002/diff/100001/content/renderer/mus/compositor_mus_connection.h File content/renderer/mus/compositor_mus_connection.h (right): https://codereview.chromium.org/2265393002/diff/100001/content/renderer/mus/compositor_mus_connection.h#newcode95 content/renderer/mus/compositor_mus_connection.h:95: std::unique_ptr<ui::DidOverscrollParams>); nit: Please name parameters.
4 years, 3 months ago (2016-09-09 20:57:57 UTC) #54
Ben Goodger (Google)
Sorry I didn't see this until now (sometimes I aggressively archive too much + vacation). ...
4 years, 3 months ago (2016-09-09 21:08:21 UTC) #55
chongz
https://codereview.chromium.org/2265393002/diff/100001/content/renderer/mus/compositor_mus_connection.h File content/renderer/mus/compositor_mus_connection.h (right): https://codereview.chromium.org/2265393002/diff/100001/content/renderer/mus/compositor_mus_connection.h#newcode95 content/renderer/mus/compositor_mus_connection.h:95: std::unique_ptr<ui::DidOverscrollParams>); On 2016/09/09 20:57:57, Charlie Reis (slow) wrote: > ...
4 years, 3 months ago (2016-09-10 00:03:04 UTC) #56
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2265393002/120001
4 years, 3 months ago (2016-09-10 00:03:59 UTC) #59
commit-bot: I haz the power
Committed patchset #5 (id:120001)
4 years, 3 months ago (2016-09-10 01:09:20 UTC) #61
commit-bot: I haz the power
4 years, 3 months ago (2016-09-10 01:11:39 UTC) #63
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/78f276e96eac5a447149fafac0b4953eb5936979
Cr-Commit-Position: refs/heads/master@{#417788}

Powered by Google App Engine
This is Rietveld 408576698