closed #615 - added "active chats" dropdown to header

- some minor tweaks also, to make taskbar work a little better with chats
This commit is contained in:
Julian Lam
2013-12-05 17:35:44 -05:00
parent 2a1671ba9b
commit 030ce95dea
7 changed files with 82 additions and 6 deletions

View File

@@ -102,6 +102,7 @@ define(['taskbar'], function(taskbar) {
chatModal.show();
module.bringModalToTop(chatModal);
checkOnlineStatus(chatModal);
taskbar.updateActive(uuid);
}
module.minimize = function(uuid) {

View File

@@ -87,6 +87,11 @@ define(function() {
toggleNew: function(uuid, state) {
var btnEl = $(taskbar.tasklist.querySelector('[data-uuid="' + uuid + '"]'));
btnEl.toggleClass('new', state);
},
updateActive: function(uuid) {
var tasks = $(taskbar.tasklist).find('li');
tasks.removeClass('active');
tasks.filter('[data-uuid="' + uuid + '"]').addClass('active');
}
}
@@ -98,6 +103,7 @@ define(function() {
push: taskbar.push,
discard: taskbar.discard,
minimize: taskbar.minimize,
toggleNew: taskbar.toggleNew
toggleNew: taskbar.toggleNew,
updateActive: taskbar.updateActive
}
});