From 4f4c5048bf386c7d8e93592644bcda99e0fc38ea Mon Sep 17 00:00:00 2001 From: Frankie Date: Tue, 28 Jun 2016 11:57:33 -0700 Subject: fix #341 close notifications when oppening pop up --- ui/app/app.js | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'ui/app/app.js') diff --git a/ui/app/app.js b/ui/app/app.js index a07118ddb..f505c89c0 100644 --- a/ui/app/app.js +++ b/ui/app/app.js @@ -324,6 +324,7 @@ App.prototype.renderPrimary = function () { return h(SendTransactionScreen, {key: 'send-transaction'}) case 'confTx': + this.clearNotifications() return h(ConfirmTxScreen, {key: 'confirm-tx'}) case 'config': @@ -355,3 +356,10 @@ App.prototype.toggleMetamaskActive = function () { } } +App.prototype.clearNotifications = function () { + chrome.notifications.getAll( function (object) { + for (let notification in object){ + chrome.notifications.clear(notification) + } + }) +}; -- cgit