Fix: update all icons when some prefs changed

This commit is contained in:
eight 2018-10-04 19:20:36 +08:00
parent 5c0288e9ba
commit 0d0e1b4dc0

View File

@ -144,6 +144,18 @@ prefs.subscribe(['iconset'], () =>
styles: {}, styles: {},
})); }));
prefs.subscribe([
'show-badge',
'disableAll',
'badgeDisabled',
'badgeNormal',
'iconset',
], () =>
queryTabs().then(tabs =>
tabs.map(t => updateIcon({tab: t}))
)
)
// ************************************************************************* // *************************************************************************
chrome.runtime.onInstalled.addListener(({reason}) => { chrome.runtime.onInstalled.addListener(({reason}) => {
if (reason !== 'update') return; if (reason !== 'update') return;