[Common] chat and comments panels didn't resize after toolbar changed to compact
This commit is contained in:
parent
134c5c907e
commit
7687f38722
|
@ -64,6 +64,16 @@ define([
|
||||||
'message:add': _.bind(this.onSendMessage, this)
|
'message:add': _.bind(this.onSendMessage, this)
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
var me = this;
|
||||||
|
Common.NotificationCenter.on('layout:changed', function(area){
|
||||||
|
Common.Utils.asyncCall(function(e) {
|
||||||
|
if ( e == 'toolbar' && me.panelChat.$el.is(':visible') ) {
|
||||||
|
me.panelChat.updateLayout(true);
|
||||||
|
me.panelChat.setupAutoSizingTextBox();
|
||||||
|
}
|
||||||
|
}, this, area);
|
||||||
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
events: {
|
events: {
|
||||||
|
|
|
@ -108,6 +108,13 @@ define([
|
||||||
|
|
||||||
Common.NotificationCenter.on('comments:updatefilter', _.bind(this.onUpdateFilter, this));
|
Common.NotificationCenter.on('comments:updatefilter', _.bind(this.onUpdateFilter, this));
|
||||||
Common.NotificationCenter.on('app:comment:add', _.bind(this.onAppAddComment, this));
|
Common.NotificationCenter.on('app:comment:add', _.bind(this.onAppAddComment, this));
|
||||||
|
Common.NotificationCenter.on('layout:changed', function(area){
|
||||||
|
Common.Utils.asyncCall(function(e) {
|
||||||
|
if ( e == 'toolbar' && this.view.$el.is(':visible') ) {
|
||||||
|
this.onAfterShow();
|
||||||
|
}
|
||||||
|
}, this, area);
|
||||||
|
}.bind(this));
|
||||||
},
|
},
|
||||||
onLaunch: function () {
|
onLaunch: function () {
|
||||||
this.collection = this.getApplication().getCollection('Common.Collections.Comments');
|
this.collection = this.getApplication().getCollection('Common.Collections.Comments');
|
||||||
|
|
Loading…
Reference in a new issue