Update javascript release files
This commit is contained in:
parent
8fe299dc21
commit
a35b2497f3
|
@ -419,7 +419,7 @@ Deluge.details.DetailsTab = Ext.extend(Ext.Panel, {
|
|||
path: torrent.save_path,
|
||||
size: fsize(torrent.total_size),
|
||||
files: torrent.num_files,
|
||||
status: torrent.tracker_status,
|
||||
status: torrent.message,
|
||||
tracker: torrent.tracker,
|
||||
comment: torrent.comment
|
||||
};
|
||||
|
@ -727,7 +727,8 @@ Deluge.details.OptionsTab = Ext.extend(Ext.form.FormPanel, {
|
|||
'stop_at_ratio': false,
|
||||
'stop_ratio': 2.0,
|
||||
'remove_at_ratio': false,
|
||||
'move_completed': null,
|
||||
'move_completed': false,
|
||||
'move_completed_path': '',
|
||||
'private': false,
|
||||
'prioritize_first_last': false
|
||||
}
|
||||
|
@ -921,7 +922,19 @@ Deluge.details.OptionsTab = Ext.extend(Ext.form.FormPanel, {
|
|||
labelSeparator: '',
|
||||
id: 'move_completed',
|
||||
boxLabel: _('Move Completed'),
|
||||
colspan: 2
|
||||
colspan: 2,
|
||||
handler: this.onMoveCompletedChecked,
|
||||
scope: this
|
||||
});
|
||||
|
||||
this.fields.move_completed_path = this.fieldsets.queue.add({
|
||||
xtype: 'textfield',
|
||||
fieldLabel: '',
|
||||
id: 'move_completed_path',
|
||||
colspan: 3,
|
||||
bodyStyle: 'margin-left: 20px',
|
||||
width: 180,
|
||||
disabled: true
|
||||
});
|
||||
|
||||
|
||||
|
@ -1059,6 +1072,13 @@ Deluge.details.OptionsTab = Ext.extend(Ext.form.FormPanel, {
|
|||
deluge.editTrackers.show();
|
||||
},
|
||||
|
||||
onMoveCompletedChecked: function(checkbox, checked) {
|
||||
this.fields.move_completed_path.setDisabled(!checked);
|
||||
|
||||
if (!checked) return;
|
||||
this.fields.move_completed_path.focus();
|
||||
},
|
||||
|
||||
onStopRatioChecked: function(checkbox, checked) {
|
||||
this.fields.remove_at_ratio.setDisabled(!checked);
|
||||
this.fields.stop_ratio.setDisabled(!checked);
|
||||
|
@ -1073,6 +1093,7 @@ Deluge.details.OptionsTab = Ext.extend(Ext.form.FormPanel, {
|
|||
var stop_at_ratio = this.optionsManager.get('stop_at_ratio');
|
||||
this.fields.remove_at_ratio.setDisabled(!stop_at_ratio);
|
||||
this.fields.stop_ratio.setDisabled(!stop_at_ratio);
|
||||
this.fields.move_completed_path.setDisabled(!this.optionsManager.get('move_completed'));
|
||||
}
|
||||
});
|
||||
/*!
|
||||
|
@ -1109,7 +1130,9 @@ Deluge.details.OptionsTab = Ext.extend(Ext.form.FormPanel, {
|
|||
|
||||
(function() {
|
||||
function flagRenderer(value) {
|
||||
if (!value) return '';
|
||||
if (!value.replace(' ', '').replace(' ', '')){
|
||||
return '';
|
||||
}
|
||||
return String.format('<img src="flag/{0}" />', value);
|
||||
}
|
||||
function peerAddressRenderer(value, p, record) {
|
||||
|
@ -1202,6 +1225,14 @@ Deluge.details.OptionsTab = Ext.extend(Ext.form.FormPanel, {
|
|||
// Go through the peers updating and creating peer records
|
||||
Ext.each(torrent.peers, function(peer) {
|
||||
if (this.peers[peer.ip]) {
|
||||
var record = store.getById(peer.ip);
|
||||
record.beginEdit();
|
||||
for (var k in peer) {
|
||||
if (record.get(k) != peer[k]) {
|
||||
record.set(k, peer[k]);
|
||||
}
|
||||
}
|
||||
record.endEdit();
|
||||
} else {
|
||||
this.peers[peer.ip] = 1;
|
||||
newPeers.push(new Deluge.data.Peer(peer, peer.ip));
|
||||
|
@ -1711,7 +1742,7 @@ Deluge.add.FileWindow = Ext.extend(Deluge.add.Window, {
|
|||
if (this.form.getForm().isValid()) {
|
||||
this.torrentId = this.createTorrentId();
|
||||
this.form.getForm().submit({
|
||||
url: '/upload',
|
||||
url: deluge.config.base + 'upload',
|
||||
waitMsg: _('Uploading your torrent...'),
|
||||
failure: this.onUploadFailure,
|
||||
success: this.onUploadSuccess,
|
||||
|
@ -2299,7 +2330,7 @@ Deluge.add.UrlWindow = Ext.extend(Deluge.add.Window, {
|
|||
fieldLabel: _('Url'),
|
||||
id: 'url',
|
||||
name: 'url',
|
||||
anchor: '100%'
|
||||
width: '97%'
|
||||
});
|
||||
this.urlField.on('specialkey', this.onAdd, this);
|
||||
|
||||
|
@ -2307,7 +2338,7 @@ Deluge.add.UrlWindow = Ext.extend(Deluge.add.Window, {
|
|||
fieldLabel: _('Cookies'),
|
||||
id: 'cookies',
|
||||
name: 'cookies',
|
||||
anchor: '100%'
|
||||
width: '97%'
|
||||
});
|
||||
this.cookieField.on('specialkey', this.onAdd, this);
|
||||
},
|
||||
|
@ -3903,6 +3934,7 @@ Deluge.preferences.Plugins = Ext.extend(Ext.Panel, {
|
|||
},
|
||||
|
||||
onPluginSelect: function(dv, selections) {
|
||||
if (selections.length == 0) return;
|
||||
var r = dv.getRecords(selections)[0];
|
||||
deluge.client.web.get_plugin_info(r.get('plugin'), {
|
||||
success: this.onGotPluginInfo,
|
||||
|
@ -5758,6 +5790,7 @@ Deluge.ConnectionManager = Ext.extend(Ext.Window, {
|
|||
}
|
||||
},
|
||||
|
||||
// FIXME: Find out why this is being fired twice
|
||||
// private
|
||||
onShow: function() {
|
||||
if (!this.addHostButton) {
|
||||
|
@ -5767,6 +5800,7 @@ Deluge.ConnectionManager = Ext.extend(Ext.Window, {
|
|||
this.stopHostButton = bbar.items.get('cm-stop');
|
||||
}
|
||||
this.loadHosts();
|
||||
if (this.running) return;
|
||||
this.running = window.setInterval(this.update, 2000, this);
|
||||
},
|
||||
|
||||
|
@ -5845,7 +5879,7 @@ Ext.apply(Ext, {
|
|||
return true;
|
||||
},
|
||||
|
||||
isObjectsEqual: function(obj1, obj2) {
|
||||
areObjectsEqual: function(obj1, obj2) {
|
||||
var equal = true;
|
||||
if (!obj1 || !obj2) return false;
|
||||
for (var i in obj1) {
|
||||
|
@ -6115,7 +6149,7 @@ Deluge.EditTrackersWindow = Ext.extend(Ext.Window, {
|
|||
height: 220,
|
||||
plain: true,
|
||||
closable: true,
|
||||
resizable: false,
|
||||
resizable: true,
|
||||
|
||||
bodyStyle: 'padding: 5px',
|
||||
buttonAlign: 'right',
|
||||
|
@ -6158,7 +6192,6 @@ Deluge.EditTrackersWindow = Ext.extend(Ext.Window, {
|
|||
},
|
||||
stripeRows: true,
|
||||
singleSelect: true,
|
||||
autoScroll: true,
|
||||
listeners: {
|
||||
'dblclick': {fn: this.onListNodeDblClicked, scope: this},
|
||||
'selectionchange': {fn: this.onSelect, scope: this}
|
||||
|
@ -6168,6 +6201,7 @@ Deluge.EditTrackersWindow = Ext.extend(Ext.Window, {
|
|||
this.panel = this.add({
|
||||
margins: '0 0 0 0',
|
||||
items: [this.list],
|
||||
autoScroll: true,
|
||||
bbar: new Ext.Toolbar({
|
||||
items: [
|
||||
{
|
||||
|
@ -6288,17 +6322,25 @@ Deluge.EditTrackersWindow = Ext.extend(Ext.Window, {
|
|||
|
||||
onDownClick: function() {
|
||||
var r = this.list.getSelectedRecords()[0];
|
||||
if (!r) return;
|
||||
|
||||
r.set('tier', r.get('tier') + 1);
|
||||
r.commit();
|
||||
r.store.sort('tier', 'ASC');
|
||||
r.store.commitChanges();
|
||||
|
||||
this.list.select(r.store.indexOf(r));
|
||||
},
|
||||
|
||||
onUpClick: function() {
|
||||
var r = this.list.getSelectedRecords()[0];
|
||||
if (!r) return;
|
||||
|
||||
if (r.get('tier') == 0) return;
|
||||
r.set('tier', r.get('tier') - 1);
|
||||
r.commit();
|
||||
r.store.sort('tier', 'ASC');
|
||||
r.store.commitChanges();
|
||||
|
||||
this.list.select(r.store.indexOf(r));
|
||||
}
|
||||
});
|
||||
/*!
|
||||
|
@ -6529,6 +6571,8 @@ Ext.ns('Deluge');
|
|||
*/
|
||||
Deluge.FilterPanel = Ext.extend(Ext.Panel, {
|
||||
|
||||
autoScroll: true,
|
||||
|
||||
border: false,
|
||||
|
||||
show_zero: null,
|
||||
|
@ -6902,7 +6946,7 @@ Deluge.Keys = {
|
|||
* Keys used in the details tab of the statistics panel.
|
||||
*/
|
||||
Details: [
|
||||
'name', 'save_path', 'total_size', 'num_files', 'tracker_status',
|
||||
'name', 'save_path', 'total_size', 'num_files', 'message',
|
||||
'tracker', 'comment'
|
||||
],
|
||||
|
||||
|
@ -6915,7 +6959,8 @@ Deluge.Keys = {
|
|||
Options: [
|
||||
'max_download_speed', 'max_upload_speed', 'max_connections',
|
||||
'max_upload_slots','is_auto_managed', 'stop_at_ratio', 'stop_ratio',
|
||||
'remove_at_ratio', 'private', 'prioritize_first_last'
|
||||
'remove_at_ratio', 'private', 'prioritize_first_last',
|
||||
'move_completed', 'move_completed_path'
|
||||
]
|
||||
};
|
||||
|
||||
|
@ -8659,6 +8704,8 @@ Deluge.Toolbar = Ext.extend(Ext.Toolbar, {
|
|||
deluge.add.show();
|
||||
}
|
||||
});
|
||||
|
||||
deluge.toolbar = new Deluge.Toolbar();
|
||||
/*!
|
||||
* Deluge.TorrentGrid.js
|
||||
*
|
||||
|
@ -8945,8 +8992,15 @@ Deluge.Toolbar = Ext.extend(Ext.Toolbar, {
|
|||
return ids;
|
||||
},
|
||||
|
||||
update: function(torrents) {
|
||||
update: function(torrents, wipe) {
|
||||
var store = this.getStore();
|
||||
|
||||
// Need to perform a complete reload of the torrent grid.
|
||||
if (wipe) {
|
||||
store.removeAll();
|
||||
this.torrents = {};
|
||||
}
|
||||
|
||||
var newTorrents = [];
|
||||
|
||||
// Update and add any new torrents.
|
||||
|
@ -9063,7 +9117,6 @@ deluge.ui = {
|
|||
deluge.preferences = new Deluge.preferences.PreferencesWindow();
|
||||
deluge.sidebar = new Deluge.Sidebar();
|
||||
deluge.statusbar = new Deluge.Statusbar();
|
||||
deluge.toolbar = new Deluge.Toolbar();
|
||||
|
||||
this.MainPanel = new Ext.Panel({
|
||||
id: 'mainPanel',
|
||||
|
@ -9122,6 +9175,9 @@ deluge.ui = {
|
|||
|
||||
update: function() {
|
||||
var filters = deluge.sidebar.getFilterStates();
|
||||
this.oldFilters = this.filters;
|
||||
this.filters = filters;
|
||||
|
||||
deluge.client.web.update_ui(Deluge.Keys.Grid, filters, {
|
||||
success: this.onUpdate,
|
||||
failure: this.onUpdateError,
|
||||
|
@ -9178,7 +9234,11 @@ deluge.ui = {
|
|||
' (Down: ' + fspeed(data['stats'].download_rate, true) +
|
||||
' Up: ' + fspeed(data['stats'].upload_rate, true) + ')';
|
||||
}
|
||||
if (Ext.areObjectsEqual(this.filters, this.oldFilters)) {
|
||||
deluge.torrents.update(data['torrents']);
|
||||
} else {
|
||||
deluge.torrents.update(data['torrents'], true);
|
||||
}
|
||||
deluge.statusbar.update(data['stats']);
|
||||
deluge.sidebar.update(data['filters']);
|
||||
this.errorCount = 0;
|
||||
|
@ -9233,7 +9293,7 @@ deluge.ui = {
|
|||
var scripts = (Deluge.debug) ? resources.debug_scripts : resources.scripts;
|
||||
Ext.each(scripts, function(script) {
|
||||
Ext.ux.JSLoader({
|
||||
url: script,
|
||||
url: deluge.config.base + script,
|
||||
onLoad: this.onPluginLoaded,
|
||||
pluginName: resources.name
|
||||
});
|
||||
|
|
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,57 @@
|
|||
bae9690238c817dffae1d0ac63b7a779 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/data/SortTypes.js
|
||||
aa4a1929533921652be154c83f140ae6 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/data/PeerRecord.js
|
||||
8a39c44af9acfb6db3d02bbb863e2837 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/data/TorrentRecord.js
|
||||
be96540b9df7bc257ae88dd7258a9afa /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/details/DetailsPanel.js
|
||||
9dc4900934219ab0590d2600bd2967b6 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/details/DetailsTab.js
|
||||
2ca39dc088cb25b1001fd335b8c8a62a /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/details/FilesTab.js
|
||||
0b63d9432d3fc1f9da819de75a799e99 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/details/OptionsTab.js
|
||||
44245ac1f3e5d0faf8fe0795586ddf24 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/details/PeersTab.js
|
||||
580317dae3ae69fa5c5858beaa306395 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/details/StatusTab.js
|
||||
5e59e90a5a5b33fcfda5e81da7fafc4f /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/add/Window.js
|
||||
f9e4a40069eadf746cdfaeee8ddd1c72 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/add/AddWindow.js
|
||||
012de80d46526b73b5f47274b2d1089d /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/add/FileWindow.js
|
||||
d1ddbcf39be25cbc3675c0f33b8b962e /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/add/FilesTab.js
|
||||
54afee7496ab80d1bd948888434149f0 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/add/Infohash.js
|
||||
78e2be1d0a9d890ec4fb9883d4386474 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/add/OptionsPanel.js
|
||||
cf204664086012a3d007df66dfb2c5dd /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/add/OptionsTab.js
|
||||
f34a08cbe5a82b7c1af7ccc662087b4d /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/add/UrlWindow.js
|
||||
7be87c3c2f0665ed8ec30e7474864944 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/BandwidthPage.js
|
||||
4fbf44b5966f206e8e41c8aa20d18048 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/CachePage.js
|
||||
94d911b7ffb6a40c3f102e3960cffa20 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/DaemonPage.js
|
||||
da518de6a2dc5cc53cbf213e781703a3 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/DownloadsPage.js
|
||||
546c4d90e08c079d641e333b5bd6e791 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/EncryptionPage.js
|
||||
f47a3bcd78c48da1812679f5387d182c /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/InstallPluginWindow.js
|
||||
3fdc169f6779ce03df322e37c3e09899 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/InterfacePage.js
|
||||
f90d9bdb0800afa2bdc4112139198b5a /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/NetworkPage.js
|
||||
213fc032bd53c706cc43c926d8c552ed /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/OtherPage.js
|
||||
3982c521a276f0e205bec3c59e513183 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/PluginsPage.js
|
||||
62b0d65bd8d3fe04b3b20ff3565e5a8c /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/PreferencesWindow.js
|
||||
a2c6d52b1e766600b564ba9f5d383277 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/ProxyField.js
|
||||
61e2cd1abe4dfd708149ad53d980765f /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/ProxyPage.js
|
||||
863f2604eeae7836926d8227c9c64a07 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/preferences/QueuePage.js
|
||||
d0c93bdf8be9cad6f712f122000bbe2c /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/StatusbarMenu.js
|
||||
c467b9445430184182cbf5a4d5bf1366 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/OptionsManager.js
|
||||
33c484389e4e935c09d986bb36fce404 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/AddConnectionWindow.js
|
||||
221cdef8fcd4b7da97df292f634ee32b /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/AddTrackerWindow.js
|
||||
12c575dec8db5cb3c58371e7d5e9f82d /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/Client.js
|
||||
4f8ccbb2128d69debf29337d9bc675fd /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/ConnectionManager.js
|
||||
5bad3696ea7dd63a77cb9e0fd06e0f26 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/Deluge.js
|
||||
b0f454dff088da3785f262c625155746 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/EditTrackerWindow.js
|
||||
33496d084937e3b8fe5b97f5cccaba66 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/EditTrackersWindow.js
|
||||
0e8db1dd6eb7dda634378b52c8510f46 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/EventsManager.js
|
||||
35fd0cc71767b30051ea1815e870d157 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/FileBrowser.js
|
||||
968d15f17edbbe421e9779ca02dd31c8 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/FilterPanel.js
|
||||
fd685ddbe6f023bb313249a91b8698ae /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/Formatters.js
|
||||
aa89426f85c2adaccfe18cb08ed25da8 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/Keys.js
|
||||
884b856210bc4815974796b6ed0f1df0 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/LoginWindow.js
|
||||
c5732310b319e83a1da98d7ddbf2fbe3 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/Menus.js
|
||||
31f9f19ad2d74f9ccc4c175b21ccbd90 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/MoveStorage.js
|
||||
a2774b78fa9953cd08ec92cfa7c086cd /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/MultiOptionsManager.js
|
||||
ba262d687129f452398ef7df08aec0ad /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/OtherLimitWindow.js
|
||||
3f25dfcde1605eb3d05811b992963ae2 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/Plugin.js
|
||||
9c496a8c9ea9857c693098bce386de03 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/RemoveWindow.js
|
||||
ed9282d8f770c0b8719a41f8add88d3a /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/Sidebar.js
|
||||
b0ce6e89ddc4adb8fba9a767dc870241 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/Statusbar.js
|
||||
29eb7ec4b70cb175e99255b54e270edd /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/Toolbar.js
|
||||
5380b0cc5d76e21b1da3bf1031d0b07c /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/TorrentGrid.js
|
||||
58beeafc35a13e41f48cfe4ee59b8612 /home/andrew/Projects/deluge/deluge/ui/web/js/deluge-all/UI.js
|
Loading…
Reference in New Issue