546cdf82cb
* Remove spurious search div * Fix nested uls * Use class name selected, not closed (the inverse) * Restor nacl div
25 lines
558 B
JavaScript
25 lines
558 B
JavaScript
var Whisper = Whisper || {};
|
|
|
|
(function () {
|
|
'use strict';
|
|
|
|
Whisper.ConversationListView = Whisper.ListView.extend({
|
|
tagName: 'div',
|
|
id: 'contacts',
|
|
itemView: Whisper.ConversationListItemView,
|
|
collection: Whisper.Threads,
|
|
|
|
events: {
|
|
'click .conversation': 'select',
|
|
},
|
|
|
|
select: function(e) {
|
|
var target = $(e.target).closest('.conversation');
|
|
if (!target.is('.selected')) {
|
|
target.siblings().removeClass('slected');
|
|
target.addClass('selected');
|
|
}
|
|
return false;
|
|
},
|
|
});
|
|
})();
|