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

Issue 2827803002: Make Interaction Media Features MQ dynamic on Linux. (Closed)

Created:
3 years, 8 months ago by darktears
Modified:
3 years, 7 months ago
CC:
chromium-reviews, jam, darin-cc_chromium.org, ozone-reviews_chromium.org, dtapuska+chromiumwatch_chromium.org, kalyank, Rick Byers
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Make Interaction Media Features MQ dynamic on Linux. With the new convertible and detachable form factors for laptops it is important to make sure the interaction media features are updated whenever the keyboard/trackpad combo is flipped (so inactive) or detached. This will allow content author to react to media query changes to adapt the user interface to better suit the new interaction method (often touch vs trackpad). The patch make sure that the detection works by verifying the touchpads and mouses from the input manager then make sure to update the input device change whenever the platforms detect changes. In order to propagate the changes a new "enabled" property has been added to InputDevice. The reason for that is because on ChromeOS even when the laptop is flipped the trackpad is not removed from the list of devices, it just doesn't propagate inputs to the UI (ASH turn it off). BUG=442418, 495634 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_site_isolation Review-Url: https://codereview.chromium.org/2827803002 Cr-Commit-Position: refs/heads/master@{#472536} Committed: https://chromium.googlesource.com/chromium/src/+/83f1b6d5641a294f5b1fb8d52e37e0a1f9ff08d5

Patch Set 1 : Make Interaction Media Features MQ dynamic on Linux. #

Patch Set 2 : Fix build + test #

Total comments: 2

Patch Set 3 : Fix comments by mustaq #

Patch Set 4 : Fix mac build #

Patch Set 5 : Rebase and fix test failures #

Total comments: 8

Patch Set 6 : Review feedback #

Patch Set 7 : Updated version #

Total comments: 4

Patch Set 8 : Patch for landing, added the mojo bits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+100 lines, -52 lines) Patch
M content/browser/frame_host/frame_tree_browsertest.cc View 1 2 3 4 5 2 chunks +4 lines, -6 lines 0 comments Download
M content/browser/renderer_host/input/input_device_change_observer.cc View 1 2 chunks +6 lines, -0 lines 0 comments Download
M content/browser/renderer_host/input/interaction_mq_dynamic_browsertest.cc View 1 1 chunk +1 line, -1 line 0 comments Download
M ui/base/BUILD.gn View 1 2 3 3 chunks +3 lines, -0 lines 0 comments Download
M ui/base/touch/touch_device.h View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M ui/base/touch/touch_device_linux.cc View 1 2 3 4 5 2 chunks +26 lines, -13 lines 0 comments Download
A ui/base/touch/touch_device_util.cc View 1 2 3 4 5 1 chunk +30 lines, -0 lines 0 comments Download
M ui/base/touch/touch_device_win.cc View 1 2 3 chunks +2 lines, -20 lines 0 comments Download
M ui/events/devices/device_data_manager.cc View 1 chunk +1 line, -1 line 0 comments Download
M ui/events/devices/input_device.h View 1 2 3 4 5 6 1 chunk +3 lines, -0 lines 0 comments Download
M ui/events/devices/mojo/input_device_struct_traits.h View 1 2 3 4 5 6 7 1 chunk +2 lines, -0 lines 0 comments Download
M ui/events/devices/mojo/input_devices.mojom View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M ui/events/ozone/evdev/event_converter_evdev.h View 1 2 3 4 5 2 chunks +2 lines, -3 lines 0 comments Download
M ui/events/ozone/evdev/event_converter_evdev.cc View 1 2 3 4 5 2 chunks +6 lines, -2 lines 0 comments Download
M ui/events/ozone/evdev/event_converter_evdev_impl.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M ui/events/ozone/evdev/gamepad_event_converter_evdev.cc View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M ui/events/ozone/evdev/input_device_factory_evdev.cc View 1 2 3 4 5 2 chunks +5 lines, -0 lines 0 comments Download
M ui/events/ozone/evdev/libgestures_glue/event_reader_libevdev_cros.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M ui/events/ozone/evdev/tablet_event_converter_evdev.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M ui/events/ozone/evdev/touch_event_converter_evdev.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 74 (54 generated)
darktears
First patch. Tested on ChromeOS, I need to install regular Linux desktop on a convertible/detachable ...
3 years, 8 months ago (2017-04-21 22:49:50 UTC) #10
mustaq
Thanks for picking this up. Here are my comments on MQs and the test code. ...
3 years, 8 months ago (2017-04-24 17:58:04 UTC) #16
darktears
On 2017/04/24 17:58:04, mustaq wrote: > Thanks for picking this up. Here are my comments ...
3 years, 8 months ago (2017-04-24 18:23:09 UTC) #17
darktears
On 2017/04/24 18:23:09, darktears wrote: > On 2017/04/24 17:58:04, mustaq wrote: > > Thanks for ...
3 years, 7 months ago (2017-05-09 20:35:11 UTC) #36
sadrul
https://codereview.chromium.org/2827803002/diff/120001/content/browser/frame_host/frame_tree_browsertest.cc File content/browser/frame_host/frame_tree_browsertest.cc (right): https://codereview.chromium.org/2827803002/diff/120001/content/browser/frame_host/frame_tree_browsertest.cc#newcode712 content/browser/frame_host/frame_tree_browsertest.cc:712: // frame initiating the navigation. We disable those checks ...
3 years, 7 months ago (2017-05-10 01:47:54 UTC) #39
spang
https://codereview.chromium.org/2827803002/diff/120001/ui/events/ozone/evdev/input_device_factory_evdev.cc File ui/events/ozone/evdev/input_device_factory_evdev.cc (right): https://codereview.chromium.org/2827803002/diff/120001/ui/events/ozone/evdev/input_device_factory_evdev.cc#newcode335 ui/events/ozone/evdev/input_device_factory_evdev.cc:335: UpdateDirtyFlags(converter); Please update dirtiness conservatively - that's the purpose ...
3 years, 7 months ago (2017-05-10 16:03:41 UTC) #41
darktears
On 2017/05/10 01:47:54, sadrul wrote: > https://codereview.chromium.org/2827803002/diff/120001/content/browser/frame_host/frame_tree_browsertest.cc > File content/browser/frame_host/frame_tree_browsertest.cc (right): > > https://codereview.chromium.org/2827803002/diff/120001/content/browser/frame_host/frame_tree_browsertest.cc#newcode712 > ...
3 years, 7 months ago (2017-05-15 15:48:38 UTC) #46
darktears
On 2017/05/10 16:03:41, spang wrote: > https://codereview.chromium.org/2827803002/diff/120001/ui/events/ozone/evdev/input_device_factory_evdev.cc > File ui/events/ozone/evdev/input_device_factory_evdev.cc (right): > > https://codereview.chromium.org/2827803002/diff/120001/ui/events/ozone/evdev/input_device_factory_evdev.cc#newcode335 > ...
3 years, 7 months ago (2017-05-15 15:48:55 UTC) #47
Rick Byers
FYI: Moved myself to cc as you've already got the real experts in this code ...
3 years, 7 months ago (2017-05-16 13:53:15 UTC) #55
darktears
jam@chromium.org: Please review changes in content/
3 years, 7 months ago (2017-05-16 15:01:42 UTC) #58
spang
ui/events/ozone lgtm Is there any plan to support this on X11?
3 years, 7 months ago (2017-05-16 15:27:43 UTC) #59
darktears
On 2017/05/16 15:27:43, spang wrote: > ui/events/ozone lgtm > > Is there any plan to ...
3 years, 7 months ago (2017-05-16 15:31:16 UTC) #60
mustaq
Pointer/hover media query values lgtm.
3 years, 7 months ago (2017-05-16 16:33:44 UTC) #61
jam
lgtm
3 years, 7 months ago (2017-05-17 01:21:20 UTC) #62
sadrul
lgtm https://codereview.chromium.org/2827803002/diff/160001/ui/base/touch/touch_device_linux.cc File ui/base/touch/touch_device_linux.cc (right): https://codereview.chromium.org/2827803002/diff/160001/ui/base/touch/touch_device_linux.cc#newcode18 ui/base/touch/touch_device_linux.cc:18: bool isMouseOrTouchpadPresent() { IsMouseOrTouchpadPresent() https://codereview.chromium.org/2827803002/diff/160001/ui/base/touch/touch_device_linux.cc#newcode52 ui/base/touch/touch_device_linux.cc:52: available_hover_types |= ...
3 years, 7 months ago (2017-05-17 15:32:17 UTC) #63
mustaq
Still lgtm: https://codereview.chromium.org/2827803002/diff/160001/ui/base/touch/touch_device_linux.cc File ui/base/touch/touch_device_linux.cc (right): https://codereview.chromium.org/2827803002/diff/160001/ui/base/touch/touch_device_linux.cc#newcode52 ui/base/touch/touch_device_linux.cc:52: available_hover_types |= HOVER_TYPE_HOVER; On 2017/05/17 15:32:17, sadrul ...
3 years, 7 months ago (2017-05-17 16:46:55 UTC) #64
darktears
On 2017/05/17 16:46:55, mustaq wrote: > Still lgtm: > > https://codereview.chromium.org/2827803002/diff/160001/ui/base/touch/touch_device_linux.cc > File ui/base/touch/touch_device_linux.cc (right): ...
3 years, 7 months ago (2017-05-17 17:09:34 UTC) #67
Robert Sesek
mojom lgtm
3 years, 7 months ago (2017-05-17 17:11:15 UTC) #68
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/2827803002/180001
3 years, 7 months ago (2017-05-17 17:13:20 UTC) #71
commit-bot: I haz the power
3 years, 7 months ago (2017-05-17 19:37:55 UTC) #74
Message was sent while issue was closed.
Committed patchset #8 (id:180001) as
https://chromium.googlesource.com/chromium/src/+/83f1b6d5641a294f5b1fb8d52e37...

Powered by Google App Engine
This is Rietveld 408576698