Module: deluge Branch: master Commit: 1825ce09fb4e82b159c56b7fbd6968b76bfe2887
Author: Damien Churchill <[email protected]> Date: Sat Apr 24 02:31:33 2010 +0100 fix removing filters that no longer exist add a filtercreate event --- deluge/ui/web/js/deluge-all/Sidebar.js | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/deluge/ui/web/js/deluge-all/Sidebar.js b/deluge/ui/web/js/deluge-all/Sidebar.js index 9a4b459..46ccc14 100644 --- a/deluge/ui/web/js/deluge-all/Sidebar.js +++ b/deluge/ui/web/js/deluge-all/Sidebar.js @@ -109,6 +109,7 @@ this.doLayout(); this.panels[filter] = panel; + this.fireEvent('filtercreate', this, panel); }, getFilters: function() { @@ -164,7 +165,9 @@ Ext.each(Ext.keys(this.panels), function(filter) { if (Ext.keys(filters).indexOf(filter) == -1) { // We need to remove the panel - this.panels[filter] + this.remove(this.panels[filter]); + this.doLayout(); + delete this.panels[filter]; } }, this); }, -- You received this message because you are subscribed to the Google Groups "deluge-commit" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/deluge-commit?hl=en.
