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

Issue 2467913002: Touch event flag should control only DOM event firing. (Closed)

Created:
4 years, 1 month ago by sunyunjia
Modified:
4 years ago
CC:
apavlov+blink_chromium.org, blink-layers+watch_chromium.org, blink-reviews, blink-reviews-api_chromium.org, blink-reviews-dom_chromium.org, blink-reviews-events_chromium.org, blink-reviews-layout_chromium.org, caseq+blink_chromium.org, chromium-reviews, creis+watch_chromium.org, darin-cc_chromium.org, devtools-reviews_chromium.org, dglazkov+blink, dtapuska+blinkwatch_chromium.org, eae+blinkwatch, jam, jchaffraix+rendering, kenneth.christiansen, kinuko+watch, kozyatinskiy+blink_chromium.org, leviw+renderwatch, lushnikov+blink_chromium.org, mlamouri+watch-content_chromium.org, nasko+codewatch_chromium.org, pdr+renderingwatchlist_chromium.org, pfeldman+blink_chromium.org, rwlbuis, sof, szager+layoutwatch_chromium.org, tfarina, zoltan1
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Touch event flag should control only DOM event firing. Currently there is no way to disable TouchEvent API support without affecting either PointerEvents (for touches) or touch support in browser UI. With PointerEvents shipping in M55, it now makes the most sense to turn on touch support in browser unconditionally and let the --touch-events flag control only the firing of DOM events. This CL also renames the flag to clarify its purpose. BUG=644318 Committed: https://crrev.com/7a880dd75bf766d22cbe4ba79bb168f7ea38c524 Cr-Commit-Position: refs/heads/master@{#434399}

Patch Set 1 #

Patch Set 2 : Finished #

Patch Set 3 : Complete #

Patch Set 4 : Change the string in "about://flags" #

Total comments: 5

Patch Set 5 : Change touch_enabled.cc #

Patch Set 6 : Format #

Patch Set 7 : windows side #

Patch Set 8 : Disable the hackernews test and change device_supports_touch. #

Patch Set 9 : Change the names and file a bug. #

Patch Set 10 : Change more names. #

Patch Set 11 : Merge branch 'master' of https://chromium.googlesource.com/chromium/src into patchtoflags #

Total comments: 10

Patch Set 12 : Bring the auto back. #

Total comments: 8

Patch Set 13 : nits #

Total comments: 3

Patch Set 14 : Change !(A && B) to !A || !B #

Total comments: 1

Patch Set 15 : Cleaner and clearer code. #

Total comments: 2

Patch Set 16 : more updates. #

Patch Set 17 : More updates. #

Patch Set 18 : Merge branch 'master' of https://chromium.googlesource.com/chromium/src into flags1 #

Total comments: 2

Patch Set 19 : Update the description in histograms.xml #

Patch Set 20 : Deprecate the histogram. #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+79 lines, -182 lines) Patch
M chrome/app/generated_resources.grd View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/about_flags.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +5 lines, -7 lines 1 comment Download
M chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 1 chunk +3 lines, -7 lines 0 comments Download
M content/browser/renderer_host/legacy_render_widget_host_win.cc View 1 2 3 4 5 6 2 chunks +1 line, -3 lines 0 comments Download
M content/browser/renderer_host/render_view_host_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +7 lines, -5 lines 0 comments Download
M content/public/common/common_param_traits_macros.h 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 content/public/common/web_preferences.h 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 content/public/common/web_preferences.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 content/renderer/render_view_impl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +1 line, -1 line 0 comments Download
M content/test/test_blink_web_unit_test_support.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/dom/Document.idl View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/dom/GlobalEventHandlers.idl View 1 2 3 4 5 6 7 8 1 chunk +4 lines, -4 lines 0 comments Download
M third_party/WebKit/Source/core/events/EventAliases.in View 1 2 3 4 5 6 7 8 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/core/input/TouchEventManager.cpp View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +4 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp View 1 2 3 4 5 6 7 8 21 chunks +27 lines, -27 lines 0 comments Download
M third_party/WebKit/Source/platform/RuntimeEnabledFeatures.in View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/web/DevToolsEmulator.h View 1 2 3 4 5 6 7 8 12 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/web/DevToolsEmulator.cpp View 1 2 3 4 5 6 7 8 12 3 chunks +5 lines, -4 lines 0 comments Download
M third_party/WebKit/Source/web/WebRuntimeFeatures.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/WebKit/public/web/WebRuntimeFeatures.h 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 tools/metrics/histograms/histograms.xml View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 2 chunks +3 lines, -3 lines 0 comments Download
M tools/perf/page_sets/system_health/browsing_stories.py 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 ui/base/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +0 lines, -2 lines 0 comments Download
M ui/base/touch/touch_enabled.h View 1 2 3 4 5 6 1 chunk +0 lines, -18 lines 0 comments Download
M ui/base/touch/touch_enabled.cc View 1 2 3 4 5 6 1 chunk +0 lines, -59 lines 0 comments Download
M ui/events/devices/x11/touch_factory_x11.h View 1 2 3 4 5 6 7 8 12 13 14 15 1 chunk +0 lines, -4 lines 0 comments Download
M ui/events/devices/x11/touch_factory_x11.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 5 chunks +2 lines, -20 lines 0 comments Download
M ui/views/win/hwnd_message_handler.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +1 line, -3 lines 0 comments Download

Messages

Total messages: 218 (167 generated)
sunyunjia
Hi Mustaq, Here is the patch I'm working. I'm trying to fix the broken tests ...
4 years, 1 month ago (2016-11-03 15:33:04 UTC) #10
mustaq
Thanks Sandra for going through the setting-flow, this looks close. There are two kinds of ...
4 years, 1 month ago (2016-11-03 18:10:49 UTC) #11
mustaq
Here are a few more comments. Please address all comments, also disable the hackernews telemetry ...
4 years, 1 month ago (2016-11-11 16:24:23 UTC) #76
sunyunjia
Hi Mustaq, Please take a look at this patch, and let me know if it's ...
4 years, 1 month ago (2016-11-14 16:26:10 UTC) #87
mustaq
Here are my initial comments: https://codereview.chromium.org/2467913002/diff/400001/chrome/app/generated_resources.grd File chrome/app/generated_resources.grd (right): https://codereview.chromium.org/2467913002/diff/400001/chrome/app/generated_resources.grd#newcode5481 chrome/app/generated_resources.grd:5481: + Support for the ...
4 years, 1 month ago (2016-11-15 20:33:58 UTC) #109
mustaq
Thanks, this is almost done. Marked a few nits, should be quick & easy, will ...
4 years, 1 month ago (2016-11-16 14:54:16 UTC) #116
sunyunjia
PTAL, thanks! https://codereview.chromium.org/2467913002/diff/400001/chrome/app/generated_resources.grd File chrome/app/generated_resources.grd (right): https://codereview.chromium.org/2467913002/diff/400001/chrome/app/generated_resources.grd#newcode5481 chrome/app/generated_resources.grd:5481: + Support for the Touch Events API. ...
4 years, 1 month ago (2016-11-16 16:39:58 UTC) #121
mustaq
LGTM, thanks.
4 years, 1 month ago (2016-11-16 16:57:52 UTC) #122
dtapuska
On 2016/11/16 16:57:52, mustaq wrote: > LGTM, thanks. lgtm
4 years, 1 month ago (2016-11-16 17:09:47 UTC) #123
sunyunjia
PTAL, thanks!
4 years, 1 month ago (2016-11-16 19:21:03 UTC) #129
tkent
third_party/WebKit lgtm
4 years, 1 month ago (2016-11-16 23:00:32 UTC) #132
dcheng
https://codereview.chromium.org/2467913002/diff/440001/content/browser/renderer_host/render_view_host_impl.cc File content/browser/renderer_host/render_view_host_impl.cc (right): https://codereview.chromium.org/2467913002/diff/440001/content/browser/renderer_host/render_view_host_impl.cc#newcode459 content/browser/renderer_host/render_view_host_impl.cc:459: switches::kTouchEventsDisabled); I'm a bit confused why the pref is ...
4 years, 1 month ago (2016-11-17 11:25:11 UTC) #133
mustaq
Still LGTM. https://codereview.chromium.org/2467913002/diff/440001/content/browser/renderer_host/render_view_host_impl.cc File content/browser/renderer_host/render_view_host_impl.cc (right): https://codereview.chromium.org/2467913002/diff/440001/content/browser/renderer_host/render_view_host_impl.cc#newcode459 content/browser/renderer_host/render_view_host_impl.cc:459: switches::kTouchEventsDisabled); On 2016/11/17 11:25:11, dcheng wrote: > ...
4 years, 1 month ago (2016-11-17 13:44:31 UTC) #134
dcheng
Thanks for clarifying: I definitely missed there grouping. https://codereview.chromium.org/2467913002/diff/460001/content/browser/renderer_host/render_view_host_impl.cc File content/browser/renderer_host/render_view_host_impl.cc (right): https://codereview.chromium.org/2467913002/diff/460001/content/browser/renderer_host/render_view_host_impl.cc#newcode459 content/browser/renderer_host/render_view_host_impl.cc:459: switches::kTouchEventsDisabled); ...
4 years, 1 month ago (2016-11-17 16:35:18 UTC) #139
dcheng
Also, lgtm
4 years, 1 month ago (2016-11-17 16:35:53 UTC) #140
mustaq
sadrul@: Need approval in ui/*
4 years, 1 month ago (2016-11-17 18:16:51 UTC) #148
Avi (use Gerrit)
ui lgtm
4 years, 1 month ago (2016-11-17 20:58:23 UTC) #149
sunyunjia
aiolos@: Could you please review the change in tools/perf? Thanks!
4 years, 1 month ago (2016-11-17 22:19:50 UTC) #155
aiolos (Not reviewing)
https://codereview.chromium.org/2467913002/diff/480001/tools/perf/page_sets/system_health/browsing_stories.py File tools/perf/page_sets/system_health/browsing_stories.py (right): https://codereview.chromium.org/2467913002/diff/480001/tools/perf/page_sets/system_health/browsing_stories.py#newcode139 tools/perf/page_sets/system_health/browsing_stories.py:139: # crbug.com/657665 for win, #crbug.com/665007 for linux The change ...
4 years, 1 month ago (2016-11-17 22:27:13 UTC) #156
aiolos (Not reviewing)
https://codereview.chromium.org/2467913002/diff/480001/tools/perf/page_sets/system_health/browsing_stories.py File tools/perf/page_sets/system_health/browsing_stories.py (right): https://codereview.chromium.org/2467913002/diff/480001/tools/perf/page_sets/system_health/browsing_stories.py#newcode139 tools/perf/page_sets/system_health/browsing_stories.py:139: # crbug.com/657665 for win, #crbug.com/665007 for linux Talked to ...
4 years, 1 month ago (2016-11-17 22:54:07 UTC) #158
nednguyen
On 2016/11/17 22:54:07, aiolos wrote: > https://codereview.chromium.org/2467913002/diff/480001/tools/perf/page_sets/system_health/browsing_stories.py > File tools/perf/page_sets/system_health/browsing_stories.py (right): > > https://codereview.chromium.org/2467913002/diff/480001/tools/perf/page_sets/system_health/browsing_stories.py#newcode139 > ...
4 years, 1 month ago (2016-11-17 22:59:43 UTC) #159
sadrul
I think you should also update TouchFactoryX11 to make sure we follow the same behaviour ...
4 years, 1 month ago (2016-11-18 15:50:31 UTC) #162
mustaq
On 2016/11/17 22:59:43, nednguyen wrote: > On 2016/11/17 22:54:07, aiolos wrote: > > > https://codereview.chromium.org/2467913002/diff/480001/tools/perf/page_sets/system_health/browsing_stories.py ...
4 years, 1 month ago (2016-11-18 15:53:20 UTC) #163
mustaq
On 2016/11/18 15:50:31, sadrul wrote: > I think you should also update TouchFactoryX11 to make ...
4 years, 1 month ago (2016-11-18 16:05:32 UTC) #164
sadrul
On 2016/11/18 16:05:32, mustaq wrote: > On 2016/11/18 15:50:31, sadrul wrote: > > I think ...
4 years, 1 month ago (2016-11-18 16:13:54 UTC) #165
mustaq
On 2016/11/18 16:13:54, sadrul wrote: > On 2016/11/18 16:05:32, mustaq wrote: > > On 2016/11/18 ...
4 years, 1 month ago (2016-11-18 16:27:11 UTC) #166
mustaq
Also update chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc RecordTouchEventState() too.
4 years, 1 month ago (2016-11-18 16:45:28 UTC) #167
sunyunjia
In this hackernews test, chrome cannot detect whether there is a touch screen or not. ...
4 years, 1 month ago (2016-11-21 15:53:16 UTC) #168
mustaq
On 2016/11/21 15:53:16, sunyunjia wrote: > In this hackernews test, chrome cannot detect whether there ...
4 years, 1 month ago (2016-11-21 17:04:04 UTC) #169
sadrul
Can you look into moving the kTouchEvents and relevant flags out of ui/events/ into content/, ...
4 years, 1 month ago (2016-11-21 18:29:58 UTC) #170
nednguyen
On 2016/11/21 17:04:04, mustaq wrote: > On 2016/11/21 15:53:16, sunyunjia wrote: > > In this ...
4 years, 1 month ago (2016-11-21 19:17:35 UTC) #171
mustaq
On 2016/11/21 19:17:35, nednguyen wrote: > On 2016/11/21 17:04:04, mustaq wrote: > > On 2016/11/21 ...
4 years, 1 month ago (2016-11-21 21:06:17 UTC) #172
mustaq
On 2016/11/21 21:06:17, mustaq wrote: > On 2016/11/21 19:17:35, nednguyen wrote: > > On 2016/11/21 ...
4 years, 1 month ago (2016-11-21 21:21:53 UTC) #173
mustaq
On 2016/11/21 21:21:53, mustaq wrote: > On 2016/11/21 21:06:17, mustaq wrote: > > On 2016/11/21 ...
4 years, 1 month ago (2016-11-21 21:37:24 UTC) #174
nednguyen
On 2016/11/21 21:37:24, mustaq wrote: > On 2016/11/21 21:21:53, mustaq wrote: > > On 2016/11/21 ...
4 years, 1 month ago (2016-11-22 13:49:24 UTC) #175
mustaq
On 2016/11/22 13:49:24, nednguyen wrote: > On 2016/11/21 21:37:24, mustaq wrote: > > On 2016/11/21 ...
4 years ago (2016-11-23 21:32:30 UTC) #180
nednguyen
On 2016/11/23 21:32:30, mustaq wrote: > On 2016/11/22 13:49:24, nednguyen wrote: > > On 2016/11/21 ...
4 years ago (2016-11-23 22:20:01 UTC) #183
nednguyen
On 2016/11/23 22:20:01, nednguyen wrote: > On 2016/11/23 21:32:30, mustaq wrote: > > On 2016/11/22 ...
4 years ago (2016-11-23 22:22:06 UTC) #184
sunyunjia
Thanks! The test passes locally with the flag "use-live-sites".
4 years ago (2016-11-23 23:05:51 UTC) #185
nednguyen
lgtm
4 years ago (2016-11-23 23:25:15 UTC) #186
sunyunjia
rkaplow@, Could you please review the code for approval in chrome/browser/metrics? Thanks!
4 years ago (2016-11-24 14:41:34 UTC) #198
rkaplow
https://codereview.chromium.org/2467913002/diff/540001/chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc File chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc (right): https://codereview.chromium.org/2467913002/diff/540001/chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc#newcode277 chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc:277: UMA_HISTOGRAM_ENUMERATION("Touchscreen.TouchEventsEnabled", state, since this is changing what Touchscreen.TouchEventsEnabled will ...
4 years ago (2016-11-24 15:46:02 UTC) #199
sunyunjia
PTAL. Thanks! https://codereview.chromium.org/2467913002/diff/540001/chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc File chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc (right): https://codereview.chromium.org/2467913002/diff/540001/chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc#newcode277 chrome/browser/metrics/chrome_browser_main_extra_parts_metrics.cc:277: UMA_HISTOGRAM_ENUMERATION("Touchscreen.TouchEventsEnabled", state, On 2016/11/24 15:46:02, rkaplow (slow ...
4 years ago (2016-11-24 16:52:20 UTC) #200
rkaplow
Can you also mark any enum entries which are no longer used as deprecated (in ...
4 years ago (2016-11-24 18:51:21 UTC) #201
sunyunjia
On 2016/11/24 18:51:21, rkaplow (slow and travelling) wrote: > Can you also mark any enum ...
4 years ago (2016-11-24 19:44:33 UTC) #202
rkaplow
lgtm
4 years ago (2016-11-24 21:47:27 UTC) #205
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/2467913002/580001
4 years ago (2016-11-24 22:00:57 UTC) #210
commit-bot: I haz the power
Committed patchset #20 (id:580001)
4 years ago (2016-11-24 22:06:01 UTC) #213
commit-bot: I haz the power
Patchset 20 (id:??) landed as https://crrev.com/7a880dd75bf766d22cbe4ba79bb168f7ea38c524 Cr-Commit-Position: refs/heads/master@{#434399}
4 years ago (2016-11-24 22:07:51 UTC) #215
Rick Byers
https://codereview.chromium.org/2467913002/diff/580001/chrome/browser/about_flags.cc File chrome/browser/about_flags.cc (right): https://codereview.chromium.org/2467913002/diff/580001/chrome/browser/about_flags.cc#newcode138 chrome/browser/about_flags.cc:138: { IDS_GENERIC_EXPERIMENT_CHOICE_ENABLED, "", "" }, Does this mean that ...
4 years ago (2016-11-24 23:53:07 UTC) #217
mustaq
4 years ago (2016-11-25 15:43:32 UTC) #218
Message was sent while issue was closed.
On 2016/11/24 23:53:07, Rick Byers wrote:
>
https://codereview.chromium.org/2467913002/diff/580001/chrome/browser/about_f...
> File chrome/browser/about_flags.cc (right):
> 
>
https://codereview.chromium.org/2467913002/diff/580001/chrome/browser/about_f...
> chrome/browser/about_flags.cc:138: { IDS_GENERIC_EXPERIMENT_CHOICE_ENABLED,
"",
> "" },
> Does this mean that "enabled" is now the default, instead of "auto"
(determined
> based on the presence of a touchscreen)?  That's going to be a problem for web
> compat due to http://crbug.com/392584.  Basically there are still a bunch of
> websites on which mouse support is broken when the TouchEvents API is present.

> So IMHO we need to retain this hacky "auto" behavior as the default for the
> touch event API status.
> 
> The rest of the patch looks great though - thanks especially for the renames /
> clarifications!

We will bring back the original AUTO behavior through a separate CL asap.

Powered by Google App Engine
This is Rietveld 408576698