fix #1537 editing trackers list, trackers have to be reselected
This commit is contained in:
parent
58134925a2
commit
d658c8fe47
|
@ -216,16 +216,24 @@ Deluge.EditTrackersWindow = Ext.extend(Ext.Window, {
|
||||||
|
|
||||||
onDownClick: function() {
|
onDownClick: function() {
|
||||||
var r = this.list.getSelectedRecords()[0];
|
var r = this.list.getSelectedRecords()[0];
|
||||||
|
if (!r) return;
|
||||||
|
|
||||||
r.set('tier', r.get('tier') + 1);
|
r.set('tier', r.get('tier') + 1);
|
||||||
r.commit();
|
|
||||||
r.store.sort('tier', 'ASC');
|
r.store.sort('tier', 'ASC');
|
||||||
|
r.store.commitChanges();
|
||||||
|
|
||||||
|
this.list.select(r.store.indexOf(r));
|
||||||
},
|
},
|
||||||
|
|
||||||
onUpClick: function() {
|
onUpClick: function() {
|
||||||
var r = this.list.getSelectedRecords()[0];
|
var r = this.list.getSelectedRecords()[0];
|
||||||
|
if (!r) return;
|
||||||
|
|
||||||
if (r.get('tier') == 0) return;
|
if (r.get('tier') == 0) return;
|
||||||
r.set('tier', r.get('tier') - 1);
|
r.set('tier', r.get('tier') - 1);
|
||||||
r.commit();
|
|
||||||
r.store.sort('tier', 'ASC');
|
r.store.sort('tier', 'ASC');
|
||||||
|
r.store.commitChanges();
|
||||||
|
|
||||||
|
this.list.select(r.store.indexOf(r));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue