Better naming
[MAILPOET-1974]
This commit is contained in:
@@ -226,15 +226,15 @@ Module.BlockToolsView = AugmentedView.extend({
|
||||
},
|
||||
changeSettings: function changeSettings(options) {
|
||||
var ViewType = this.getSettingsView();
|
||||
var showedSettingsId = App.getShowedSettingsId();
|
||||
if (showedSettingsId) {
|
||||
if (showedSettingsId === this.model.cid) {
|
||||
var displayedSettingsId = App.getDisplayedSettingsId();
|
||||
if (displayedSettingsId) {
|
||||
if (displayedSettingsId === this.model.cid) {
|
||||
return;
|
||||
}
|
||||
App.getChannel().trigger('hideSettings');
|
||||
return;
|
||||
}
|
||||
App.getChannel().trigger('settingsShowed', this.model.cid);
|
||||
App.getChannel().trigger('settingsDisplayed', this.model.cid);
|
||||
(new ViewType(_.extend({ model: this.model }, options || {}))).render();
|
||||
},
|
||||
showDeletionConfirmation: function showDeletionConfirmation() {
|
||||
@@ -326,7 +326,7 @@ Module.BlockSettingsView = Marionette.View.extend({
|
||||
onBeforeDestroy: function onBeforeDestroy() {
|
||||
MailPoet.Modal.close();
|
||||
this.model.trigger('stopEditing');
|
||||
App.getChannel().trigger('settingsShowed', null);
|
||||
App.getChannel().trigger('settingsDisplayed', null);
|
||||
},
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user