New issue
Advanced search Search tips

Issue 873119 link

Starred by 1 user

Issue metadata

Status: Assigned
Merged: issue 806562
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 2
Type: Bug-Regression



Sign in to add a comment

Middle-click locked autoscroll sporadically quits

Reported by martin.l...@gmail.com, Aug 10

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.106 Safari/537.36

Steps to reproduce the problem:
1. Visit a scrollable page; e.g. www.google.com/chrome
2. Middle-click on page (press and release middle-button) to enter locked autoscroll-mode
3. Try scrolling in autoscroll-mode just by moving mouse

What is the expected behavior?
Page automatically scrolls with constant speed and cursor shows autoscroll-icon.

What went wrong?
Mouse movement does not results in scrolling, but behaves as normal mouse pointer, and the cursor changed from autoscroll-icon to default; hence autoscroll-mode quit. 

Did this work before? Yes long ago...

Chrome version: 68.0.3440.106  Channel: stable
OS Version: 10.0
Flash Version: 

- Occasionally works with trackpoint and mouse (1/3) but never works with touchpad three-finger-click win gesture.  
- It consistently works if you keep the middle-button pressed.
 
Labels: Needs-Triage-M68 Needs-Bisect
Cc: swarnasree.mukkala@chromium.org
Labels: Triaged-ET Needs-Feedback
Unable to reproduce the issue on reported chrome version #68.0.3440.106 and latest chrome #70.0.3519.0 using Windows 10 by following below steps.

Steps:
=====
1.Launched chrome.
2.Opened the link www.google.com/chrome.
3.Unlocked the auto scroll mode (by presing and releasing the middle button) and tried scrolling down.
4.Able to observe page automatically scrolling down with autoscroll icon.

Attached screencast for reference.

@Reporter: Could you please review the attached screen-cast and confirm if anything being missed here and request you to retry this issue with fresh profile without any extensions/apps or reset all the flags and let us know if issue still persists.

Thanks.!
873119.mp4
15.3 MB Download
- I did as you said and still have the issue; so its not related to profile, extensions or flags.
- I also tried it in Chrome Beta 69.0.3497.42 with same results. 
- Concerning your screen-cast: You are right, that issue does not appear on other systems; I too tried another WinPc. Although it seems you did only one middle-click and not multiple ones (since it does not fail/work every time you would have to do that). 

Thing is: on my system other browsers work absolutely fine (Edge & Firefox). So it must be Chrome related and not my systems fault per se!? My conculsion: its a Chrome bug and it only surfaces on some machines, e.g. my Thinkpad X1 Yoga system. 
Project Member

Comment 4 by sheriffbot@chromium.org, Aug 21

Labels: -Needs-Feedback
Thank you for providing more feedback. Adding the requester to the cc list.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: -Needs-Bisect
Unable to reproduce the issue on #69.0.3497.42 using Windows10 by following the steps as per comment#0.
Note: Tried multiple times(~8 times) but unable to reproduce the issue.

Hence removing the Needs-Bisect label as the issue is not getting reproduced from TE end and requesting anyone from UI to look into the issue.


Thanks.!
Components: Blink>Scroll
Labels: TE-NeedsTriageHelp
As per comment #2 and #5, as this issue is not reproducible at TE end, adding 'TE-NeedsTriageHelp' label. Tentatively adding 'Blink>Scroll' component and requesting the team to look into the issue and help in further triaging.

Thanks..
Cc: bokan@chromium.org
martin.lichtblau@: How often does the issue occur? If possible, it would be very helpful if you could capture a trace while you're autoscrolling and it "quits". If you could attach a trace here it would be very helpful for fixing. Here are instructions on how to grab a trace: https://www.chromium.org/developers/how-tos/submitting-a-performance-bug
Hmm, I just found a way this can happen - if you start the autoscroll over a cross-site iframe, the autoscroll will exit as soon as the mouse leaves the iframe. It can be hard to tell sometimes iframes are.

If you go to http://csreis.github.io/tests/cross-site-iframe.html
1) Click on "complex page"
2) Wait for it to load
3) Middle click on the iframe to start auto scroll
4) Move the cursor outside the iframe

The autoscroll will disengage. Is this what you're seeing? The google.com/chrome page doesn't seem to have any cross-site iframes though so it wouldn't explain if you're seeing it there. Are you sure you came across it there?  
- Iframe has nothing to do with it. Issue happens on any scrollable page.
- I made two traces: with web dev settings and with all selected. 

Another description of the phenomenon: I do a middle-click and the cursor turns into the autoscroll icon and stays like that. But the moment I move the mouse in order to autoscroll, the cursor turns back into the default arrow and autoscroll doesn't work.
trace_Middle-Click_Autoscroll_touchpad&trackpoint_(web-dev).json.gz
4.3 MB Download
trace_Middle-Click_Autoscroll_touchpad&trackpoint_(full).json.gz
13.1 MB Download
I can reproduce the issue on Windows 10 by moving the mouse out of the content area for scrolling. I.e. to reproduce:

- Enter locked scrolling mode by pressing and releasing the middle mouse button
- Move the mouse to scroll
- Move the mouse outside of the content area (for me it's often the bookmarks or address bar because I frequently use this way of quickly scrolling to the very top with the mouse)

Expected behaviour:

The mode stays active as the mouse is captured during the gesture until clicking again. This would be consistent with how other applications behave (and I think Chrome wasn't broken before either).

Observed behavior:

Locked scrolling mode disengages as soon as the mouse leaves the content area in any direction.

Chrome 68 and 69 on Windows 10 1803.
@hypft your issue might be related to mine, but it's not the same. In my case autoscroll disengages no matter the circumstances.
martin.lichtblau@: In the trace, I'm seeing multiple autoscroll regions about 2-3 seconds each. In all those, the autoscroll disengaged by itself?

If that's the case, it looks like the cause is that we're getting a left mouse button click event from Windows. I'm assuming you weren't actually pressing it. Do you have some kind of non-standard mouse/driver?

hypftier@: please file a new bug - we can look at that separately. Thanks
Yes, in ~3/4 of the cases it disengaged by itself. The delay of 2-3 seconds could be the time it took me to move the mouse. But, I never did a left-click; neither on trackP nor touchP and certainly not with mouse.

About driver: I have trackpad so it could be that I have some non-standard configuration, but not intentionally. Also I must admit that the trackpad has a known issue with recalibration, which could be related, but I assume not. 

Strange thing is that it works in other browsers.
The following issues are already known:

1- Inside an out of process iframe if you middle click to start autoscrolling and move your mouse outside of the iframe, the moment that the mouse leaves the iframe the icon changes back to normal.

2- In a normal scrollable page if you leave the content area autoscrolling stops.

3- If you do a middle click to start autoscrolling and at any point during the autoscroll try to scroll in a direction that is not scrollable and the change the direction toward a scrollable direction, the icon will stay the same but no autoscroll will happen. (We have a fix for this bug that will land soon.)
Cc: sahel@chromium.org
Labels: Needs-Feedback
 martin.lichtblau@ if what you see is different from issues in comment #14 please record a demo video and attach it here.
sahel@ do we have bugs for the other issues? Can you mark this one as duplicate of one of those since reporter doesn't seem to disagree with your comment.
Mergedinto: 806562
Status: Duplicate (was: Unconfirmed)
-crbug.com/806562 is the bug for  issue 2  and I believe it is also the root cause
of the issue 1. I will file a bug for issue 1 if it still exists after fixing this bug.

- crbug.com/870726  is the bug for  issue 3  and it is fixed.
I am 90% sure it's not a duplicate. But it's such a nasty issue which takes so much time looking into, that I wanted to wait and see whether the fixes for those other bugs will change the behavior of this one. 
 
Still, I invested some more time to pin down the issue.

Look at the screen recording > https://drive.google.com/open?id=1ToBMcWf7D0anvXjDDvsyGD8lqMDwI89j
- I thought you can't detect a "foul" autoscroll without moving the mouse. But as you see, a normal autoscroll stops when left clicking. On the other hand in a foul state I can left click, and by that select text, all while the cursor still shows the autoscroll icon; seeming like it's stuck in a dead state. I assume the function StopMiddleClickAutoscroll() is never called, but sth. else made it disengage.
- Outstanding is the fact that it never works with touchpad.

My hunch is that something unforseen is happening and the bug arises in HandleMouseMoveForMiddleClickAutoscroll() or more likely in HandleMouseReleaseForMiddleClickAutoscroll(). There are some lines which make me worry. Could it be that something happens in a different order than it should and thus variables/flags lead to a unanticipated states. Just with the code I can't tell. I would need to debug step by step. But my firt try would be to insert an "else" in line 266 after this: "if (middle_click_mode_ == kMiddleClickInitial && is_middle_button)
    middle_click_mode_ = kMiddleClickToggled;
  else if (middle_click_mode_ == kMiddleClickHolding)
    StopMiddleClickAutoscroll(frame);" 
Because with the current if construct some unanticipated cases could slip through, since it lacks a default catch-it-all. If that's the case the symptoms of this bug could show up. Because then autoscroll wouldn't be stopped and neither work, since not toggled, and yet the cursor icon would still show up. 

But perphaps you can replicate my issue: 
I used autohotkey to simulate different middle clicks. Interestingly some didn't work, but only in Chrome; going in line with my exp.
- those work: "SendInput {MButton down} SendInput {MButton up}" or "Click, Middle,," or "Send {MButton down}{MButton up}"
- those don't: "SendInput {MButton down}{MButton up}" or "SendInput {MButton}"
Common difference is that the working versions give slower input.

P.S.: Sorry for the inconvenience.... :-/ 

@sahel@chromium.org It seems I am too late. All the work for nothing?
Owner: sahel@chromium.org
Status: Assigned (was: Duplicate)
Removing the duplication because of comment #18.

>I used autohotkey to simulate different middle clicks. Interestingly some didn't work, but only in Chrome; going in line with my exp.

Autoscroll does not work in some cases since the positions of the event that we send to the renderer is not set properly. This is in particular the root cause for crbug.com/829775 that I am working on. Let's wait till the fix lands in Canary and see if it fixes this issue as well or not. 

Sign in to add a comment