From c32b30d65aa0828b40139a22993d38b6ebe35926 Mon Sep 17 00:00:00 2001 From: Darren Date: Mon, 7 Nov 2011 14:38:48 +0000 Subject: [PATCH] Tabview sorting now enabled --- client/js/front.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/client/js/front.js b/client/js/front.js index 4d15bf9..41074a0 100644 --- a/client/js/front.js +++ b/client/js/front.js @@ -466,9 +466,8 @@ kiwi.front = { sortWindowList: function () { var win_list = $('#kiwi .windowlist ul'); var listitems = win_list.children('li').get(); - console.log(Tabview.getServerTab().tab); + listitems.sort(function (a, b) { - console.log(a); if (a == Tabview.getServerTab().tab[0]) { return -1; } @@ -1306,7 +1305,7 @@ var Tabview = function (v_name) { // Create the window $('#kiwi .windows .scroller').append('
'); - // Create the userlist + // Create the window tab tmp_tab = $('
  • '); $('span', tmp_tab).text(v_name); $('#kiwi .windowlist ul').append(tmp_tab); @@ -1316,6 +1315,8 @@ var Tabview = function (v_name) { tab.show(); } }); + + kiwi.front.sortWindowList(); } kiwi.front.tabviews[v_name.toLowerCase()] = this; -- 2.25.1