[WebUI] Compress javascript files
This commit is contained in:
parent
852b51f224
commit
869dbab459
|
@ -80,7 +80,7 @@ GetText.add('80 KiB/s', '${escape(_("80 KiB/s"))}')
|
|||
// QueuePage.js:69
|
||||
GetText.add('Active Torrents', '${escape(_("Active Torrents"))}')
|
||||
|
||||
// EditTrackersWindow.js:112, ConnectionManager.js:110, AddConnectionWindow.js:56, Toolbar.js:58, AddTrackerWindow.js:57, UrlWindow.js:50, FileWindow.js:53, AddWindow.js:52
|
||||
// EditTrackersWindow.js:112, ConnectionManager.js:110, AddConnectionWindow.js:56, Toolbar.js:58, AddTrackerWindow.js:66, UrlWindow.js:50, FileWindow.js:53, AddWindow.js:52
|
||||
GetText.add('Add', '${escape(_("Add"))}')
|
||||
|
||||
// AddConnectionWindow.js:40
|
||||
|
@ -92,7 +92,7 @@ GetText.add('Add In Paused State', '${escape(_("Add In Paused State"))}')
|
|||
// AddWindow.js:37
|
||||
GetText.add('Add Torrents', '${escape(_("Add Torrents"))}')
|
||||
|
||||
// AddTrackerWindow.js:40
|
||||
// AddTrackerWindow.js:49
|
||||
GetText.add('Add Tracker', '${escape(_("Add Tracker"))}')
|
||||
|
||||
// FileWindow.js:40
|
||||
|
@ -155,7 +155,7 @@ GetText.add('Cache Expiry (seconds)', '${escape(_("Cache Expiry (seconds)"))}')
|
|||
// CachePage.js:63
|
||||
GetText.add('Cache Size (16 KiB Blocks)', '${escape(_("Cache Size (16 KiB Blocks)"))}')
|
||||
|
||||
// EditTrackersWindow.js:56, OtherLimitWindow.js:72, RemoveWindow.js:55, MoveStorage.js:55, EditTrackerWindow.js:56, AddTrackerWindow.js:56, AddWindow.js:51
|
||||
// EditTrackersWindow.js:56, OtherLimitWindow.js:72, RemoveWindow.js:55, MoveStorage.js:55, EditTrackerWindow.js:56, AddTrackerWindow.js:65, AddWindow.js:51
|
||||
GetText.add('Cancel', '${escape(_("Cancel"))}')
|
||||
|
||||
// PreferencesWindow.js:85
|
||||
|
@ -761,7 +761,7 @@ GetText.add('Tracker', '${escape(_("Tracker"))}')
|
|||
// Sidebar.js:35
|
||||
GetText.add('Tracker Host', '${escape(_("Tracker Host"))}')
|
||||
|
||||
// AddTrackerWindow.js:66
|
||||
// AddTrackerWindow.js:75
|
||||
GetText.add('Trackers', '${escape(_("Trackers"))}')
|
||||
|
||||
// ProxyField.js:48
|
||||
|
|
|
@ -5314,6 +5314,15 @@ Deluge.AddConnectionWindow = Ext.extend(Ext.Window, {
|
|||
*/
|
||||
Ext.ns('Deluge');
|
||||
|
||||
// Custom VType validator for tracker urls
|
||||
var trackerUrlTest = /(((^https?)|(^udp)):\/\/([\-\w]+\.)+\w{2,3}(\/[%\-\w]+(\.\w{2,})?)*(([\w\-\.\?\\\/+@&#;`~=%!]*)(\.\w{2,})?)*\/?)/i;
|
||||
Ext.apply(Ext.form.VTypes, {
|
||||
trackerUrl: function(val, field) {
|
||||
return trackerUrlTest.test(val);
|
||||
},
|
||||
trackerUrlText: 'Not a valid tracker url'
|
||||
});
|
||||
|
||||
/**
|
||||
* @class Deluge.AddTrackerWindow
|
||||
* @extends Ext.Window
|
||||
|
@ -5359,7 +5368,7 @@ Deluge.AddTrackerWindow = Ext.extend(Ext.Window, {
|
|||
|
||||
var cleaned = [];
|
||||
Ext.each(trackers, function(tracker) {
|
||||
if (Ext.form.VTypes.url(tracker)) {
|
||||
if (Ext.form.VTypes.trackerUrl(tracker)) {
|
||||
cleaned.push(tracker);
|
||||
}
|
||||
}, this);
|
||||
|
|
|
@ -1085,7 +1085,7 @@ Ext.ns("Deluge");Deluge.AddConnectionWindow=Ext.extend(Ext.Window,{title:_("Add
|
|||
* this exception statement from your version. If you delete this exception
|
||||
* statement from all source files in the program, then also delete it here.
|
||||
*/
|
||||
Ext.ns("Deluge");Deluge.AddTrackerWindow=Ext.extend(Ext.Window,{title:_("Add Tracker"),layout:"fit",width:375,height:150,plain:true,closable:true,resizable:false,bodyStyle:"padding: 5px",buttonAlign:"right",closeAction:"hide",iconCls:"x-deluge-edit-trackers",initComponent:function(){Deluge.AddTrackerWindow.superclass.initComponent.call(this);this.addButton(_("Cancel"),this.onCancelClick,this);this.addButton(_("Add"),this.onAddClick,this);this.addEvents("add");this.form=this.add({xtype:"form",defaultType:"textarea",baseCls:"x-plain",labelWidth:55,items:[{fieldLabel:_("Trackers"),name:"trackers",anchor:"100%"}]})},onAddClick:function(){var b=this.form.getForm().findField("trackers").getValue();b=b.split("\n");var a=[];Ext.each(b,function(c){if(Ext.form.VTypes.url(c)){a.push(c)}},this);this.fireEvent("add",a);this.hide();this.form.getForm().findField("trackers").setValue("")},onCancelClick:function(){this.form.getForm().findField("trackers").setValue("");this.hide()}});
|
||||
Ext.ns("Deluge");var trackerUrlTest=/(((^https?)|(^udp)):\/\/([\-\w]+\.)+\w{2,3}(\/[%\-\w]+(\.\w{2,})?)*(([\w\-\.\?\\\/+@&#;`~=%!]*)(\.\w{2,})?)*\/?)/i;Ext.apply(Ext.form.VTypes,{trackerUrl:function(b,a){return trackerUrlTest.test(b)},trackerUrlText:"Not a valid tracker url"});Deluge.AddTrackerWindow=Ext.extend(Ext.Window,{title:_("Add Tracker"),layout:"fit",width:375,height:150,plain:true,closable:true,resizable:false,bodyStyle:"padding: 5px",buttonAlign:"right",closeAction:"hide",iconCls:"x-deluge-edit-trackers",initComponent:function(){Deluge.AddTrackerWindow.superclass.initComponent.call(this);this.addButton(_("Cancel"),this.onCancelClick,this);this.addButton(_("Add"),this.onAddClick,this);this.addEvents("add");this.form=this.add({xtype:"form",defaultType:"textarea",baseCls:"x-plain",labelWidth:55,items:[{fieldLabel:_("Trackers"),name:"trackers",anchor:"100%"}]})},onAddClick:function(){var b=this.form.getForm().findField("trackers").getValue();b=b.split("\n");var a=[];Ext.each(b,function(c){if(Ext.form.VTypes.trackerUrl(c)){a.push(c)}},this);this.fireEvent("add",a);this.hide();this.form.getForm().findField("trackers").setValue("")},onCancelClick:function(){this.form.getForm().findField("trackers").setValue("");this.hide()}});
|
||||
/*
|
||||
* Deluge.Client.js
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue