Bug 1488953 - Disable smooth scroll on tabbar scrollbox to avoid stopping scrolling the last tab on race conditions. r=bgrins

Differential Revision: https://phabricator.services.mozilla.com/D33615

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Hiroyuki Ikezoe 2019-07-09 23:55:32 +00:00
parent a5be1c5bc5
commit 69c518e632

View File

@ -52,6 +52,12 @@ add_task(async function() {
async function overflowTabs() {
let arrowScrollbox = gBrowser.tabContainer.arrowScrollbox;
const originalSmoothScroll = arrowScrollbox.smoothScroll;
arrowScrollbox.smoothScroll = false;
registerCleanupFunction(() => {
arrowScrollbox.smoothScroll = originalSmoothScroll;
});
let width = ele => ele.getBoundingClientRect().width;
let tabMinWidth = parseInt(
getComputedStyle(gBrowser.selectedTab, null).minWidth