| Index: notification.js |
| =================================================================== |
| --- a/notification.js |
| +++ b/notification.js |
| @@ -63,7 +63,9 @@ |
| window.addEventListener("load", function() |
| { |
| var notification = getActiveNotification(); |
| - if (!notification) |
| + if (!notification |
| + || notification.type == "question" |
| + || notification.type == "normal") |
| return; |
| var texts = Notification.getLocalizedTexts(notification); |
| @@ -86,28 +88,6 @@ |
| ext.pages.open(link.href); |
| }); |
| - if (notification.type == "question") |
| - { |
| - document.getElementById("notification-question").addEventListener("click", function(event) |
| - { |
| - event.preventDefault(); |
| - event.stopPropagation(); |
| - |
| - var approved = false; |
| - switch (event.target.id) |
| - { |
| - case "notification-yes": |
| - approved = true; |
| - case "notification-no": |
| - Notification.triggerQuestionListeners(notification.id, approved); |
| - Notification.markAsShown(notification.id); |
| - notification.onClicked(); |
| - break; |
| - } |
| - window.close(); |
| - }, true); |
| - } |
| - |
| var notificationElement = document.getElementById("notification"); |
| notificationElement.className = notification.type; |
| notificationElement.hidden = false; |