Update to work around flashing icon issue (#1384)

Repeatedly clearAttention to prevent flashing icon
This commit is contained in:
beernutz 2017-08-24 18:22:01 -05:00 committed by Scott Nonnenberg
parent f14ac69f2a
commit 07ec2707ac

View file

@ -19,11 +19,21 @@
window.drawAttention = function() {
if (inboxOpened && !inboxFocused) {
if (window.keepClear) {
clearInterval(window.keepClear);
delete window.keepClear;
}
extension.windows.drawAttention(inboxWindowId);
}
};
window.clearAttention = function() {
extension.windows.clearAttention(inboxWindowId);
if (window.keepClear) {
clearInterval(window.keepClear);
delete window.keepClear;
}
window.keepClear = setInterval(function() {
extension.windows.clearAttention(inboxWindowId)
}, 2000);
};
/* Inbox window controller */