[DE][SSE] Use commenting display option when show/hide panels in the left menu.

This commit is contained in:
Julia Radzhabova 2017-06-20 12:39:16 +03:00
parent bc69ffe68f
commit fa12b8912b
2 changed files with 12 additions and 0 deletions

View file

@ -145,6 +145,7 @@ define([
this.btnChat.hide();
this.btnComments.on('click', _.bind(this.onBtnMenuClick, this));
this.btnComments.on('toggle', _.bind(this.onBtnCommentsToggle, this));
this.btnChat.on('click', _.bind(this.onBtnMenuClick, this));
/** coauthoring end **/
@ -185,6 +186,11 @@ define([
Common.NotificationCenter.trigger('layout:changed', 'leftmenu');
},
onBtnCommentsToggle: function(btn, state) {
if (!state)
this.fireEvent('comments:hide', this);
},
onBtnMenuClick: function(btn, e) {
this.supressEvents = true;
this.btnFile.toggle(false);

View file

@ -135,6 +135,7 @@ define([
this.btnChat.hide();
this.btnComments.on('click', _.bind(this.onBtnMenuClick, this));
this.btnComments.on('toggle', _.bind(this.onBtnCommentsToggle, this));
this.btnChat.on('click', _.bind(this.onBtnMenuClick, this));
/** coauthoring end **/
@ -177,6 +178,11 @@ define([
Common.NotificationCenter.trigger('layout:changed', 'leftmenu');
},
onBtnCommentsToggle: function(btn, state) {
if (!state)
this.fireEvent('comments:hide', this);
},
onBtnMenuClick: function(btn, e) {
this.btnFile.toggle(false);
this.btnAbout.toggle(false);