Render conversation titles

This commit is contained in:
lilia 2015-05-22 15:41:30 -07:00
parent bc4d31cf72
commit 7bf1d41184
8 changed files with 21 additions and 10 deletions

View file

@ -24,7 +24,10 @@
},
template: $('#conversation').html(),
render_attributes: function() {
return { group: this.model.get('type') === 'group' };
return {
group: this.model.get('type') === 'group',
title: this.model.getTitle()
};
},
initialize: function(options) {
this.listenTo(this.model, 'destroy', this.stopListening);
@ -34,7 +37,7 @@
this.appWindow = options.appWindow;
new Whisper.WindowControlsView({
appWindow: this.appWindow
}).$el.appendTo(this.$('#header'));
}).$el.insertAfter(this.$('.menu'));
this.fileInput = new Whisper.FileInputView({
el: this.$('.attachments'),

View file

@ -18,6 +18,7 @@
window.Whisper = window.Whisper || {};
Whisper.WindowControlsView = Whisper.View.extend({
tagName: 'span',
className: 'window-controls',
template: $('#window-controls').html(),
initialize: function(options) {