web: few sidebar fixes
This commit is contained in:
parent
e3e20aa14f
commit
1837d833c2
|
@ -174,7 +174,9 @@ Ext.define('Deluge.FilterPanel', {
|
|||
if (filters[record.getId()]) return;
|
||||
var r = sm.getLastSelected();
|
||||
store.remove(record);
|
||||
if (r.id == record.id) {
|
||||
if (r === undefined)
|
||||
return;
|
||||
if (r.getId() == record.getId()) {
|
||||
sm.select(0);
|
||||
}
|
||||
}, this);
|
||||
|
|
|
@ -90,13 +90,9 @@ Ext.define('Deluge.Sidebar', {
|
|||
deluge.ui.update();
|
||||
}
|
||||
|
||||
Ext.defer(function() {
|
||||
panel.doLayout();
|
||||
}, 100);
|
||||
console.log('switching');
|
||||
//if (!sm.hasSelection() && s.count() > 0) {
|
||||
// sm.select([s.first()]);
|
||||
//}
|
||||
if (!sm.hasSelection() && s.count() > 0) {
|
||||
sm.select([s.first()]);
|
||||
}
|
||||
});
|
||||
this.fireEvent('filtercreate', this, panel);
|
||||
|
||||
|
|
Loading…
Reference in New Issue