Index: messageResponder.js |
=================================================================== |
--- a/messageResponder.js |
+++ b/messageResponder.js |
@@ -182,6 +182,16 @@ |
if (message.what == "options") |
ext.showOptions(); |
break; |
+ case "app.userSubscriptionsToggle": |
Thomas Greiner
2016/03/01 12:11:22
Please reuse "subscriptions.toggle" for that becau
|
+ var subscriptions = FilterStorage.subscriptions; |
+ for (var i = 0; i < subscriptions.length; i++) |
+ { |
+ if (subscriptions[i] instanceof SpecialSubscription) |
+ subscriptions[i].disabled = message.state; |
Thomas Greiner
2016/03/01 12:11:22
It's a "toggle" function so it should toggle the s
|
+ } |
+ FilterNotifier.triggerListeners("app.userSubscriptionsToggle", |
Thomas Greiner
2016/03/01 12:11:22
We already have a filter event for that: "subscrip
|
+ message.state); |
+ break; |
case "filters.add": |
var filter = Filter.fromText(message.text); |
var result = require("filterValidation").parseFilter(message.text); |