Merge pull request #1838 from rachel-fenichel/bugfix/ff_scrolling

Fix a problem with scrolling on firefox
This commit is contained in:
Rachel Fenichel
2018-05-09 12:44:27 -07:00
committed by GitHub

View File

@@ -212,8 +212,9 @@ Blockly.VerticalFlyout.prototype.wheel_ = function(e) {
var delta = e.deltaY;
if (delta) {
if (goog.userAgent.GECKO) {
// Firefox's deltas are a tenth that of Chrome/Safari.
// Firefox's mouse wheel deltas are a tenth that of Chrome/Safari.
// DeltaMode is 1 for a mouse wheel, but not for a trackpad scroll event
if (goog.userAgent.GECKO && (e.deltaMode === 1)) {
delta *= 10;
}
var metrics = this.getMetrics_();