Open Bug 1507150 Opened 5 years ago Updated 2 years ago

Scrolling inside a .div using the touchpad causes the whole page to scroll on google graphs

Categories

(Core :: DOM: UI Events & Focus Handling, defect, P3)

Desktop
All
defect

Tracking

()

Tracking Status
firefox63 --- wontfix
firefox64 --- wontfix
firefox65 --- wontfix
firefox66 --- wontfix
firefox87 --- affected
firefox88 --- affected
firefox89 --- affected
firefox92 --- affected
firefox93 --- affected
firefox94 --- affected
firefox95 --- affected
firefox105 --- affected

People

(Reporter: obotisan, Unassigned)

References

Details

(Keywords: webcompat:site-wait)

Attachments

(1 file)

[Notes]:
- You need a MacBook.

[Affected versions]:
- Latest Nightly 65.0a1
- Beta 64.0b9
- Firefox 63.0.1

[Affected platforms]:
- macOS 10.14
- macOS 10.13
- Windows 10 x64

[Steps to reproduce]:
1. Go to https://www.google.com/search?q=sqrt(x*x%2By*y)%2B3*cos(sqrt(x*x%2By*y))%2B5&cad=h
2. Click inside the .div.
3. Scroll using the touchpad.

[Expected result]:
- The graph is zoom in and out.
- The page doesn't scroll down and up.

[Actual result]:
- The graph is zoom in and out.
- The page scrolls down and up.

[Regression range]:
- I am not sure if it's a regression, but if it is, I will leave the pushlog in a comment.
- Please look at the attached gif. 

[Additional notes]:
- The issue is not reproducing on Chrome.
I can still reproduce the issue using older versions of Nightly from 2014-01-02 and on older versions the browser doesn't open the graphic, so I can't test the issue. If this is a regression it's an old one.
Thanks for the clear bug report.

To move this forward, someone (not saying it has to be you, Oana!) needs to dig into whether the events Firefox is sending on scrolling differ from other browsers or if the site is interpreting what Firefox sends incorrectly.
Flags: webcompat?
Priority: -- → P3
Marking fix-optional for 65 and 66 so that these already triaged issues don't show up repeatedly in weekly regression triage. Happy to take a patch in nightly.
Component: Event Handling → User events and focus handling

See bug 1547409. Moving webcompat whiteboard tags to project flags.

Webcompat Priority: --- → ?

Ksenia, can you take a look at this please?

Flags: needinfo?(kberezina)

In this file:

The following event listener is added to a div with the graph:

this.$ = s_s(this.Ya, s_k.eh ? "DOMMouseScroll" : "mousewheel", this, b),

where s_k.eh is a check for a User Agent, so DOMMouseScroll is added in Firefox and mousewheel in Chrome.

When the event is firing there is a call to preventDefault in this file:

  s_Gd.prototype.preventDefault = function () {
    s_Gd.Ua.preventDefault.call(this);
    var a = this.zd;
    if (a.preventDefault) a.preventDefault();
     else if (a.returnValue = !1, s_wda) try {
      if (a.ctrlKey || 112 <= a.keyCode && 123 >= a.keyCode) a.keyCode = - 1
    } catch (b) {
    }

While preventDefault works for mousewheel, it doesn't work for DOMMouseScroll (need to call preventDefault() of wheel events). So the page scrolls up and down because of that.

I think both of those legacy events listeners can be replaced by wheel, though it will require some changes in the event handler code.

Flags: needinfo?(kberezina)

Here is a related bug https://bugzilla.mozilla.org/show_bug.cgi?id=1529953 about mousewheel support

See Also: → 1529953

ni? myself to reach out to Google here.

Flags: needinfo?(miket)

I sent an email to our partner list.

Flags: needinfo?(miket)
Webcompat Priority: ? → -
OS: macOS → All

No response so far, reaching out to our Google search mailing list.

Summary: Scrolling inside a .div using the touchpad causes the whole page to scroll → Scrolling inside a .div using the touchpad causes the whole page to scroll on google graphs

Updating flags based on duplicate Bug 1699400

Managed to reproduce the issue also on Ubuntu 20 X64. with build 96.0b2-snap.
In comparison with the Windows repro steps, on ubuntu the touchpad scroll must be longer in order for the page to scroll.

Webcompat Priority: - → ---

Also reproducible on Beta v105.0b8 on Windows 7.

Hardware: All → Desktop
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: