From 3735736bbccd7497fec629b28888e82a8c255942 Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Tue, 24 Jun 2014 16:55:21 -0700 Subject: [PATCH] Replaced vent.on with this.listenTo vent --- src/UI/History/Blacklist/BlacklistLayout.js | 3 ++- src/UI/Series/Details/SeriesDetailsLayout.js | 3 +-- src/UI/Settings/General/GeneralView.js | 2 +- src/UI/System/Logs/Table/LogsTableLayout.js | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/UI/History/Blacklist/BlacklistLayout.js b/src/UI/History/Blacklist/BlacklistLayout.js index 8a6a74487..d8b214ca2 100644 --- a/src/UI/History/Blacklist/BlacklistLayout.js +++ b/src/UI/History/Blacklist/BlacklistLayout.js @@ -67,8 +67,9 @@ define( initialize: function () { this.collection = new BlacklistCollection({ tableName: 'blacklist' }); + this.listenTo(this.collection, 'sync', this._showTable); - vent.on(vent.Events.CommandComplete, this._commandComplete, this); + this.listenTo(vent, vent.Events.CommandComplete, this._commandComplete); }, onShow: function () { diff --git a/src/UI/Series/Details/SeriesDetailsLayout.js b/src/UI/Series/Details/SeriesDetailsLayout.js index 95d20c627..cceef6655 100644 --- a/src/UI/Series/Details/SeriesDetailsLayout.js +++ b/src/UI/Series/Details/SeriesDetailsLayout.js @@ -59,8 +59,7 @@ define( initialize: function () { this.listenTo(this.model, 'change:monitored', this._setMonitoredState); this.listenTo(vent, vent.Events.SeriesDeleted, this._onSeriesDeleted); - - vent.on(vent.Events.CommandComplete, this._commandComplete, this); + this.listenTo(vent, vent.Events.CommandComplete, this._commandComplete); }, onShow: function () { diff --git a/src/UI/Settings/General/GeneralView.js b/src/UI/Settings/General/GeneralView.js index b28ed659c..1b5aaaed7 100644 --- a/src/UI/Settings/General/GeneralView.js +++ b/src/UI/Settings/General/GeneralView.js @@ -31,7 +31,7 @@ define( }, initialize: function () { - vent.on(vent.Events.CommandComplete, this._commandComplete, this); + this.listenTo(vent, vent.Events.CommandComplete, this._commandComplete); }, onRender: function(){ diff --git a/src/UI/System/Logs/Table/LogsTableLayout.js b/src/UI/System/Logs/Table/LogsTableLayout.js index 841a5a92b..2e06e1b7d 100644 --- a/src/UI/System/Logs/Table/LogsTableLayout.js +++ b/src/UI/System/Logs/Table/LogsTableLayout.js @@ -61,7 +61,7 @@ define( this.collection = new LogCollection(); this.listenTo(this.collection, 'sync', this._showTable); - vent.on(vent.Events.CommandComplete, this._commandComplete, this); + this.listenTo(vent, vent.Events.CommandComplete, this._commandComplete); }, onRender: function () {