Author: damoxc
Revision: 5856
Log:
fix removing torrents that fail to download when added via url
Diff:
Modified: branches/1.2_RC/deluge/ui/web/js/Deluge.Add.js
===================================================================
--- branches/1.2_RC/deluge/ui/web/js/Deluge.Add.js 2009-10-21 20:15:16 UTC
(rev 5855)
+++ branches/1.2_RC/deluge/ui/web/js/Deluge.Add.js 2009-10-21 20:30:07 UTC
(rev 5856)
@@ -203,7 +203,6 @@
}));
this.form.on('render', this.onFormRender, this);
- this.form.disable();
},
onFormRender: function(form) {
@@ -491,10 +490,10 @@
var selection = this.grid.getSelectionModel();
if (!selection.hasSelection()) return;
var torrent = selection.getSelected();
-
- delete this.torrents[torrent.id];
this.grid.getStore().remove(torrent);
this.optionsPanel.clear();
+
+ if (this.torrents && this.torrents[torrent.id]) delete
this.torrents[torrent.id];
},
onSelect: function(selModel, rowIndex, record) {
Modified: trunk/deluge/ui/web/js/Deluge.Add.js
===================================================================
--- trunk/deluge/ui/web/js/Deluge.Add.js 2009-10-21 20:15:16 UTC (rev
5855)
+++ trunk/deluge/ui/web/js/Deluge.Add.js 2009-10-21 20:30:07 UTC (rev
5856)
@@ -203,7 +203,6 @@
}));
this.form.on('render', this.onFormRender, this);
- this.form.disable();
},
onFormRender: function(form) {
@@ -491,10 +490,10 @@
var selection = this.grid.getSelectionModel();
if (!selection.hasSelection()) return;
var torrent = selection.getSelected();
-
- delete this.torrents[torrent.id];
this.grid.getStore().remove(torrent);
this.optionsPanel.clear();
+
+ if (this.torrents && this.torrents[torrent.id]) delete
this.torrents[torrent.id];
},
onSelect: function(selModel, rowIndex, record) {
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---