Module: deluge Branch: master Commit: fec735f948da2553bc22191f359baf17e6f1817a
Author: Damien Churchill <[email protected]> Date: Wed Apr 28 08:42:29 2010 +0100 fix the first item being selected upon creation --- deluge/ui/web/js/deluge-all/FilterPanel.js | 10 ++++------ 1 files changed, 4 insertions(+), 6 deletions(-) diff --git a/deluge/ui/web/js/deluge-all/FilterPanel.js b/deluge/ui/web/js/deluge-all/FilterPanel.js index a686170..8029440 100644 --- a/deluge/ui/web/js/deluge-all/FilterPanel.js +++ b/deluge/ui/web/js/deluge-all/FilterPanel.js @@ -77,12 +77,6 @@ Deluge.FilterPanel = Ext.extend(Ext.Panel, { }] }); this.relayEvents(this.list, ['selectionchange']); - this.list.afterMethod('bindStore', this.doBindStore, this); - }, - - // private - doBindStore: function() { - this.list.select(0); }, /** @@ -160,6 +154,10 @@ Deluge.FilterPanel = Ext.extend(Ext.Panel, { }, this); store.commitChanges(); + + if (!this.list.getSelectionCount()) { + this.list.select(0); + } }, }); -- 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.
