[OSRM-talk] Front-end issue on Firefox due to non-standard mousewheel event

Emilio Cobos Álvarez emilio at crisal.io
Wed Jan 22 15:32:29 UTC 2025


Hi!

In https://bugzilla.mozilla.org/show_bug.cgi?id=1942589 we got a report 
of the osrm map not scrolling the controls in Firefox.

I debugged it a bit and it is because of this mousewheel event listener:

                            o.DomEvent.addListener(
                             this._container,
                             'mousewheel',
                             function (e) {
                               o.DomEvent.stopPropagation(e)
                             }
                           ),

Which works in Chromium but not Firefox, because mousewheel is not standard.

I didn't find that code in osrm-frontend nor leaflet (though I guess it 
can be an old leaflet version?), otherwise I would've sent a PR.

It'd be great if it used leaflet's disableScrollPropagation, or just 
s/mousewheel/wheel. It should work virtually everywhere nowadays.

Thanks,

  -- Emilio



More information about the OSRM-talk mailing list