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

Issue 1963823002: Dispatch middle click manually by tracking mouse (Closed)

Created:
4 years, 7 months ago by Navid Zolghadr
Modified:
4 years, 7 months ago
CC:
arv+watch_chromium.org, chromium-reviews, dbeam+watch-ntp_chromium.org, dbeam+watch-closure_chromium.org, jlklein+watch-closure_chromium.org, pedrosimonetti+watch_chromium.org, vitalyp+closure_chromium.org, dpapad
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Dispatch middle click manually by tracking mouse Tracking targets for middle button mousedown event and fire click event for it on mouse up if necessary. Note: The click is not finding the common parent of mousedown and up targets for simplicty and only sends the click to the target if both down and up happened on the same node. BUG=608697 CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:closure_compilation Committed: https://crrev.com/88eb1110baafcba070e750866a343e81b6bcc524 Cr-Commit-Position: refs/heads/master@{#395707}

Patch Set 1 #

Total comments: 2

Patch Set 2 : Applying comments #

Total comments: 6

Patch Set 3 : git cl try #

Total comments: 16

Patch Set 4 : Applying comments #

Total comments: 2

Patch Set 5 : Adding \n's #

Patch Set 6 : #

Total comments: 2

Patch Set 7 : Add length check #

Unified diffs Side-by-side diffs Delta from patch set Stats (+25 lines, -0 lines) Patch
M chrome/browser/resources/ntp4/new_tab.html View 1 1 chunk +1 line, -0 lines 0 comments Download
A chrome/browser/resources/ntp4/synthetic_middleclick.js View 1 2 3 4 5 6 1 chunk +24 lines, -0 lines 0 comments Download

Messages

Total messages: 47 (8 generated)
Navid Zolghadr
4 years, 7 months ago (2016-05-09 21:02:08 UTC) #3
dtapuska
I'd probably call the code something like synthetic_middleclick.js https://codereview.chromium.org/1963823002/diff/1/chrome/browser/resources/ntp4/middleclick_gen.js File chrome/browser/resources/ntp4/middleclick_gen.js (right): https://codereview.chromium.org/1963823002/diff/1/chrome/browser/resources/ntp4/middleclick_gen.js#newcode12 chrome/browser/resources/ntp4/middleclick_gen.js:12: e.target.dispatchEvent(new ...
4 years, 7 months ago (2016-05-10 12:27:15 UTC) #4
Navid Zolghadr
https://codereview.chromium.org/1963823002/diff/1/chrome/browser/resources/ntp4/middleclick_gen.js File chrome/browser/resources/ntp4/middleclick_gen.js (right): https://codereview.chromium.org/1963823002/diff/1/chrome/browser/resources/ntp4/middleclick_gen.js#newcode12 chrome/browser/resources/ntp4/middleclick_gen.js:12: e.target.dispatchEvent(new MouseEvent('click', e)); On 2016/05/10 12:27:15, dtapuska wrote: > ...
4 years, 7 months ago (2016-05-10 13:17:40 UTC) #5
Navid Zolghadr
ptal
4 years, 7 months ago (2016-05-10 14:48:26 UTC) #7
Navid Zolghadr
4 years, 7 months ago (2016-05-10 17:45:32 UTC) #9
Lei Zhang
Deferring to ntp4 OWNERS https://codereview.chromium.org/1963823002/diff/20001/chrome/browser/resources/ntp4/compiled_resources.gyp File chrome/browser/resources/ntp4/compiled_resources.gyp (right): https://codereview.chromium.org/1963823002/diff/20001/chrome/browser/resources/ntp4/compiled_resources.gyp#newcode33 chrome/browser/resources/ntp4/compiled_resources.gyp:33: 'synthetic_middleclick.js', Can this entire list ...
4 years, 7 months ago (2016-05-10 19:01:42 UTC) #11
Navid Zolghadr
https://codereview.chromium.org/1963823002/diff/20001/chrome/browser/resources/ntp4/compiled_resources.gyp File chrome/browser/resources/ntp4/compiled_resources.gyp (right): https://codereview.chromium.org/1963823002/diff/20001/chrome/browser/resources/ntp4/compiled_resources.gyp#newcode33 chrome/browser/resources/ntp4/compiled_resources.gyp:33: 'synthetic_middleclick.js', On 2016/05/10 19:01:42, Lei Zhang wrote: > Can ...
4 years, 7 months ago (2016-05-10 19:28:26 UTC) #12
Dan Beam
I don't understand why we don't want to fix the platform issue. mouse up and ...
4 years, 7 months ago (2016-05-11 05:11:13 UTC) #13
Navid Zolghadr
On 2016/05/11 05:11:13, Dan Beam wrote: > I don't understand why we don't want to ...
4 years, 7 months ago (2016-05-11 12:31:53 UTC) #14
Rick Byers
On 2016/05/11 12:31:53, Navid Zolghadr wrote: > On 2016/05/11 05:11:13, Dan Beam wrote: > > ...
4 years, 7 months ago (2016-05-12 01:29:54 UTC) #15
Dan Beam
https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode17 chrome/browser/resources/ntp4/synthetic_middleclick.js:17: }, true); both of our code has all kind ...
4 years, 7 months ago (2016-05-12 02:06:24 UTC) #16
dtapuska
https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode17 chrome/browser/resources/ntp4/synthetic_middleclick.js:17: }, true); On 2016/05/12 02:06:24, Dan Beam wrote: > ...
4 years, 7 months ago (2016-05-12 02:12:50 UTC) #17
Navid Zolghadr
https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode17 chrome/browser/resources/ntp4/synthetic_middleclick.js:17: }, true); On 2016/05/12 02:12:50, dtapuska wrote: > On ...
4 years, 7 months ago (2016-05-12 13:56:01 UTC) #18
Dan Beam
https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode17 chrome/browser/resources/ntp4/synthetic_middleclick.js:17: }, true); On 2016/05/12 02:12:50, dtapuska wrote: > On ...
4 years, 7 months ago (2016-05-12 18:59:05 UTC) #19
Dan Beam
https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode17 chrome/browser/resources/ntp4/synthetic_middleclick.js:17: }, true); On 2016/05/12 18:59:05, Dan Beam wrote: > ...
4 years, 7 months ago (2016-05-12 19:08:21 UTC) #20
Navid Zolghadr
https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode17 chrome/browser/resources/ntp4/synthetic_middleclick.js:17: }, true); On 2016/05/12 19:08:21, Dan Beam wrote: > ...
4 years, 7 months ago (2016-05-12 20:53:59 UTC) #21
Navid Zolghadr
On 2016/05/12 20:53:59, Navid Zolghadr wrote: > https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js > File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): > > https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode17 ...
4 years, 7 months ago (2016-05-13 16:01:05 UTC) #22
Dan Beam
i'm worried that if we start adding imperfect polyfills, better fixes in the platform will ...
4 years, 7 months ago (2016-05-13 22:27:05 UTC) #23
Navid Zolghadr
On 2016/05/13 22:27:05, Dan Beam wrote: > i'm worried that if we start adding imperfect ...
4 years, 7 months ago (2016-05-13 23:06:34 UTC) #24
Dan Beam
On 2016/05/13 23:06:34, Navid Zolghadr wrote: > On 2016/05/13 22:27:05, Dan Beam wrote: > > ...
4 years, 7 months ago (2016-05-17 01:08:32 UTC) #25
Navid Zolghadr
On 2016/05/17 01:08:32, Dan Beam wrote: > On 2016/05/13 23:06:34, Navid Zolghadr wrote: > > ...
4 years, 7 months ago (2016-05-17 01:59:55 UTC) #26
Navid Zolghadr
On 2016/05/17 01:59:55, Navid Zolghadr wrote: > On 2016/05/17 01:08:32, Dan Beam wrote: > > ...
4 years, 7 months ago (2016-05-18 15:01:51 UTC) #27
Dan Beam
On 2016/05/18 15:01:51, Navid Zolghadr wrote: > On 2016/05/17 01:59:55, Navid Zolghadr wrote: > > ...
4 years, 7 months ago (2016-05-18 23:44:11 UTC) #28
Navid Zolghadr
On 2016/05/18 23:44:11, Dan Beam wrote: > On 2016/05/18 15:01:51, Navid Zolghadr wrote: > > ...
4 years, 7 months ago (2016-05-19 02:05:23 UTC) #29
Dan Beam
On 2016/05/19 02:05:23, Navid Zolghadr wrote: > On 2016/05/18 23:44:11, Dan Beam wrote: > > ...
4 years, 7 months ago (2016-05-19 18:04:43 UTC) #30
Navid Zolghadr
On 2016/05/19 18:04:43, Dan Beam wrote: > On 2016/05/19 02:05:23, Navid Zolghadr wrote: > > ...
4 years, 7 months ago (2016-05-19 18:07:25 UTC) #31
Navid Zolghadr
ping!
4 years, 7 months ago (2016-05-20 16:16:34 UTC) #32
Dan Beam
https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode5 chrome/browser/resources/ntp4/synthetic_middleclick.js:5: var middleButtonMouseDownTarget = null; wrap this in: (function() { ...
4 years, 7 months ago (2016-05-24 01:57:32 UTC) #33
Dan Beam
https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/compiled_resources.gyp File chrome/browser/resources/ntp4/compiled_resources.gyp (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/compiled_resources.gyp#newcode41 chrome/browser/resources/ntp4/compiled_resources.gyp:41: 'trash.js', why do you need to change this list ...
4 years, 7 months ago (2016-05-24 01:58:00 UTC) #34
Navid Zolghadr
https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/compiled_resources.gyp File chrome/browser/resources/ntp4/compiled_resources.gyp (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/compiled_resources.gyp#newcode41 chrome/browser/resources/ntp4/compiled_resources.gyp:41: 'trash.js', On 2016/05/24 01:58:00, Dan Beam wrote: > why ...
4 years, 7 months ago (2016-05-24 02:21:25 UTC) #35
Dan Beam
https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/compiled_resources.gyp File chrome/browser/resources/ntp4/compiled_resources.gyp (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/compiled_resources.gyp#newcode41 chrome/browser/resources/ntp4/compiled_resources.gyp:41: 'trash.js', On 2016/05/24 02:21:25, Navid Zolghadr wrote: > On ...
4 years, 7 months ago (2016-05-24 17:20:46 UTC) #36
Navid Zolghadr
ptal. https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/compiled_resources.gyp File chrome/browser/resources/ntp4/compiled_resources.gyp (right): https://codereview.chromium.org/1963823002/diff/30001/chrome/browser/resources/ntp4/compiled_resources.gyp#newcode41 chrome/browser/resources/ntp4/compiled_resources.gyp:41: 'trash.js', On 2016/05/24 17:20:46, Dan Beam wrote: > ...
4 years, 7 months ago (2016-05-24 17:51:14 UTC) #37
Dan Beam
lgtm w/nits I wanted to make this work for shadow DOM so synthetic_middleclick.js could be ...
4 years, 7 months ago (2016-05-24 18:17:26 UTC) #38
Navid Zolghadr
https://codereview.chromium.org/1963823002/diff/50001/chrome/browser/resources/ntp4/synthetic_middleclick.js File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): https://codereview.chromium.org/1963823002/diff/50001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode5 chrome/browser/resources/ntp4/synthetic_middleclick.js:5: (function() { On 2016/05/24 18:17:25, Dan Beam wrote: > ...
4 years, 7 months ago (2016-05-24 18:38:23 UTC) #39
Dan Beam
lgtm https://codereview.chromium.org/1963823002/diff/90001/chrome/browser/resources/ntp4/synthetic_middleclick.js File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): https://codereview.chromium.org/1963823002/diff/90001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode18 chrome/browser/resources/ntp4/synthetic_middleclick.js:18: if (e.path[0] == middleButtonMouseDownTarget) btw, it probably doesn't ...
4 years, 7 months ago (2016-05-24 18:48:01 UTC) #40
Navid Zolghadr
https://codereview.chromium.org/1963823002/diff/90001/chrome/browser/resources/ntp4/synthetic_middleclick.js File chrome/browser/resources/ntp4/synthetic_middleclick.js (right): https://codereview.chromium.org/1963823002/diff/90001/chrome/browser/resources/ntp4/synthetic_middleclick.js#newcode18 chrome/browser/resources/ntp4/synthetic_middleclick.js:18: if (e.path[0] == middleButtonMouseDownTarget) On 2016/05/24 18:48:00, Dan Beam ...
4 years, 7 months ago (2016-05-24 19:22:31 UTC) #41
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1963823002/110001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1963823002/110001
4 years, 7 months ago (2016-05-24 21:44:31 UTC) #44
commit-bot: I haz the power
Committed patchset #7 (id:110001)
4 years, 7 months ago (2016-05-24 21:56:04 UTC) #45
commit-bot: I haz the power
4 years, 7 months ago (2016-05-24 21:57:23 UTC) #47
Message was sent while issue was closed.
Patchset 7 (id:??) landed as
https://crrev.com/88eb1110baafcba070e750866a343e81b6bcc524
Cr-Commit-Position: refs/heads/master@{#395707}

Powered by Google App Engine
This is Rietveld 408576698