From 5cf97db07c26b7ed51ac45c76d93c53d3e9e2a09 Mon Sep 17 00:00:00 2001 From: Ben Ogle Date: Fri, 5 Dec 2014 13:42:55 -0800 Subject: [PATCH] Add getNotifications() --- src/notification-manager.coffee | 6 ++++++ src/notification.coffee | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/notification-manager.coffee b/src/notification-manager.coffee index 499905667..3e47c11e8 100644 --- a/src/notification-manager.coffee +++ b/src/notification-manager.coffee @@ -42,3 +42,9 @@ class NotificationManager @notifications.push(notification) @emitter.emit('did-add-notification', notification) notification + + ### + Section: Getting Notifications + ### + + getNotifications: -> @notifications diff --git a/src/notification.coffee b/src/notification.coffee index b772cc65b..bc0261ad8 100644 --- a/src/notification.coffee +++ b/src/notification.coffee @@ -28,7 +28,7 @@ class Notification and @getDetail() == other.getDetail() dismiss: -> - return unless @isDismissable() + return unless @isDismissable() and not @isDismissed() @dismissed = true @emitter.emit 'did-dismiss'