Browse Source

Apply formatting to Web UI files

adaptive-webui-19844
Chocobo1 7 years ago
parent
commit
cf2c0bd47e
No known key found for this signature in database
GPG Key ID: 210D9C873253A68C
  1. 3
      src/webui/www/private/addtrackers.html
  2. 3
      src/webui/www/private/confirmdeletion.html
  3. 3
      src/webui/www/private/css/Layout.css
  4. 10
      src/webui/www/private/css/Window.css
  5. 3
      src/webui/www/private/css/dynamicTable.css
  6. 59
      src/webui/www/private/css/style.css
  7. 4
      src/webui/www/private/download.html
  8. 3
      src/webui/www/private/downloadlimit.html
  9. 3
      src/webui/www/private/index.html
  10. 6
      src/webui/www/private/newcategory.html
  11. 3
      src/webui/www/private/preferences.html
  12. 92
      src/webui/www/private/preferences_content.html
  13. 96
      src/webui/www/private/properties_content.html
  14. 3
      src/webui/www/private/rename.html
  15. 31
      src/webui/www/private/scripts/client.js
  16. 15
      src/webui/www/private/scripts/contextmenu.js
  17. 32
      src/webui/www/private/scripts/dynamicTable.js
  18. 16
      src/webui/www/private/scripts/misc.js
  19. 4
      src/webui/www/private/scripts/prop-files.js
  20. 4
      src/webui/www/private/scripts/prop-general.js
  21. 4
      src/webui/www/private/scripts/prop-trackers.js
  22. 4
      src/webui/www/private/scripts/prop-webseeds.js
  23. 3
      src/webui/www/private/setlocation.html
  24. 1
      src/webui/www/private/transferlist.html
  25. 4
      src/webui/www/private/upload.html
  26. 3
      src/webui/www/private/uploadlimit.html
  27. 9
      src/webui/www/public/login.html

3
src/webui/www/private/addtrackers.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(Trackers addition dialog)QBT_TR[CONTEXT=TrackersAdditionDlg]</title>
@ -27,6 +28,7 @@ @@ -27,6 +28,7 @@
});
</script>
</head>
<body>
<div style="text-align: center;">
<br/>
@ -36,4 +38,5 @@ @@ -36,4 +38,5 @@
<input type="button" value="QBT_TR(Add)QBT_TR[CONTEXT=HttpServer]" id="addTrackersButton" />
</div>
</body>
</html>

3
src/webui/www/private/confirmdeletion.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(Deletion confirmation - qBittorrent)QBT_TR[CONTEXT=confirmDeletionDlg]</title>
@ -34,6 +35,7 @@ @@ -34,6 +35,7 @@
});
</script>
</head>
<body>
<br/>
@ -43,4 +45,5 @@ @@ -43,4 +45,5 @@
<input type="button" id="cancelBtn" value="QBT_TR(No)QBT_TR[CONTEXT=MainWindow]" />&nbsp;&nbsp;<input type="button" id="confirmBtn" value="QBT_TR(Yes)QBT_TR[CONTEXT=MainWindow]" />&nbsp;&nbsp;
</div>
</body>
</html>

3
src/webui/www/private/css/Layout.css

@ -186,7 +186,8 @@ body { @@ -186,7 +186,8 @@ body {
color: #3f3f3f;
font-weight: normal;
/* Fix By Chris */
padding: 1px 10px 1px 20px; /* Reduce left padding */
padding: 1px 10px 1px 20px;
/* Reduce left padding */
}
#desktopNavbar li ul li a:hover {

10
src/webui/www/private/css/Window.css

@ -24,8 +24,7 @@ Required by: @@ -24,8 +24,7 @@ Required by:
background-color: #e5e5e5;
}
.mocha.isFocused {
}
.mocha.isFocused {}
.mochaOverlay {
position: absolute; /* This is also set in theme.js in order to make theme transitions smoother */
@ -255,7 +254,8 @@ div.mochaToolbarWrapper.bottom { @@ -255,7 +254,8 @@ div.mochaToolbarWrapper.bottom {
/* The replaced class is used internally when converting CSS values to Canvas. These classes should not be removed. */
.mocha.replaced, .mochaTitlebar.replaced, .mochaMinimizeButton.replaced, .mochaMaximizeButton.replaced, .mochaCloseButton.replaced {
.mocha.replaced, .mochaTitlebar.replaced, .mochaMinimizeButton.replaced,
.mochaMaximizeButton.replaced, .mochaCloseButton.replaced {
background-color: transparent !important;
}
@ -269,7 +269,8 @@ div.mochaToolbarWrapper.bottom { @@ -269,7 +269,8 @@ div.mochaToolbarWrapper.bottom {
overflow: hidden;
}
.windowClosed .mochaContentBorder, .windowClosed .mochaToolbarWrapper, .windowClosed .mochaTitlebar, .windowClosed .mochaControls,
.windowClosed .mochaContentBorder, .windowClosed .mochaToolbarWrapper,
.windowClosed .mochaTitlebar, .windowClosed .mochaControls,
.windowClosed .mochaCanvasControls {
position: absolute;
top: 0;
@ -371,6 +372,7 @@ div.mochaToolbarWrapper.bottom { @@ -371,6 +372,7 @@ div.mochaToolbarWrapper.bottom {
}
/* Workaround to make invisible buttons clickable */
.mochaMinimizeButton.replaced,
.mochaMaximizeButton.replaced,
.mochaCloseButton.replaced {

3
src/webui/www/private/css/dynamicTable.css

@ -1,11 +1,10 @@ @@ -1,11 +1,10 @@
/**************************************************************
Dynamic Table
v 0.4
**************************************************************/
.dynamicTable tbody tr {
background-color: #fff;
}

59
src/webui/www/private/css/style.css

@ -1,9 +1,16 @@ @@ -1,9 +1,16 @@
/* Reset */
/*ul,ol,dl,li,dt,dd,h1,h2,h3,h4,h5,h6,pre,form,body,html,p,blockquote,fieldset,input,object,iframe { margin: 0; padding: 0; }*/
a img,:link img,:visited img { border: none; }
a img, :link img, :visited img {
border: none;
}
/*table { border-collapse: collapse; border-spacing: 0; }*/
:focus { outline: none; }
:focus {
outline: none;
}
/* Structure */
@ -172,9 +179,23 @@ a.propButton img { @@ -172,9 +179,23 @@ a.propButton img {
/* context menu specific */
.contextMenu { border:1px solid #999; padding:0; background:#eee; list-style-type:none; display:none;}
.contextMenu .separator { border-top:1px solid #999; }
.contextMenu li { margin:0; padding:0;}
.contextMenu {
border: 1px solid #999;
padding: 0;
background: #eee;
list-style-type: none;
display: none;
}
.contextMenu .separator {
border-top: 1px solid #999;
}
.contextMenu li {
margin: 0;
padding: 0;
}
.contextMenu li a {
display: block;
padding: 5px 20px 5px 5px;
@ -184,12 +205,25 @@ a.propButton img { @@ -184,12 +205,25 @@ a.propButton img {
color: #000;
white-space: nowrap;
}
.contextMenu li a:hover { background-color:#ddd; }
.contextMenu li a.disabled { color:#ccc; font-style:italic; }
.contextMenu li a.disabled:hover { background-color:#eee; }
.contextMenu li a:hover {
background-color: #ddd;
}
.contextMenu li a.disabled {
color: #ccc;
font-style: italic;
}
.contextMenu li a.disabled:hover {
background-color: #eee;
}
.contextMenu li ul {
padding: 0;
border:1px solid #999; padding:0; background:#eee;
border: 1px solid #999;
padding: 0;
background: #eee;
list-style-type: none;
position: absolute;
left: -999em;
@ -197,14 +231,17 @@ a.propButton img { @@ -197,14 +231,17 @@ a.propButton img {
margin: -29px 0 0 100%;
width: 164px;
}
.contextMenu li ul li a {
position: relative;
}
.contextMenu li a.arrow-right, .contextMenu li a:hover.arrow-right {
background-image: url(../images/skin/arrow-right.gif);
background-repeat: no-repeat;
background-position: right center;
}
.contextMenu li:hover ul,
.contextMenu li.ieHover ul,
.contextMenu li li.ieHover ul,
@ -280,6 +317,7 @@ a.propButton img { @@ -280,6 +317,7 @@ a.propButton img {
}
/* Mocha Customization */
#mochaToolbar {
margin-top: 5px;
}
@ -392,7 +430,8 @@ td.generalLabel { @@ -392,7 +430,8 @@ td.generalLabel {
line-height: 20px;
}
#trackersTable, #webseedsTable {
#trackersTable,
#webseedsTable {
line-height: 25px;
}

4
src/webui/www/private/download.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(Add Torrent Links)QBT_TR[CONTEXT=downloadFromURL]</title>
@ -8,6 +9,7 @@ @@ -8,6 +9,7 @@
<script src="scripts/lib/mootools-1.2-core-yc.js"></script>
<script src="scripts/download.js"></script>
</head>
<body>
<iframe id="download_frame" name="download_frame" class="invisible" src="javascript:false;"></iframe>
<form action="api/v2/torrents/add" enctype="multipart/form-data" method="post" id="downloadForm" style="text-align: center;" target="download_frame">
@ -69,7 +71,6 @@ @@ -69,7 +71,6 @@
</div>
</form>
<script>
var submitted = false;
$('downloadForm').addEventListener("submit", function() {
@ -88,4 +89,5 @@ $('start_torrent').addEventListener('change', function() { @@ -88,4 +89,5 @@ $('start_torrent').addEventListener('change', function() {
</script>
<div id="download_spinner" class="mochaSpinner"></div>
</body>
</html>

3
src/webui/www/private/downloadlimit.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(Torrent Download Speed Limiting)QBT_TR[CONTEXT=TransferListWidget]</title>
@ -9,6 +10,7 @@ @@ -9,6 +10,7 @@
<script src="scripts/lib/mocha-yc.js"></script>
<script src="scripts/lib/parametrics.js"></script>
</head>
<body>
<div style="width: 100%; text-align: center; margin: 0 auto; overflow: hidden">
<div id="dllimitSlider" class="slider">
@ -59,4 +61,5 @@ @@ -59,4 +61,5 @@
</script>
</body>
</html>

3
src/webui/www/private/index.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=10" />
@ -26,6 +27,7 @@ @@ -26,6 +27,7 @@
<script src="scripts/client.js"></script>
<script src="scripts/contextmenu.js"></script>
</head>
<body>
<div id="desktop">
<div id="desktopHeader">
@ -164,4 +166,5 @@ @@ -164,4 +166,5 @@
</div>
</div>
</body>
</html>

6
src/webui/www/private/newcategory.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(New Category)QBT_TR[CONTEXT=TransferListWidget]</title>
@ -43,8 +44,7 @@ @@ -43,8 +44,7 @@
}
}).send();
}
else
{
else {
new Request({
url: 'api/v2/torrents/setCategory',
method: 'post',
@ -61,6 +61,7 @@ @@ -61,6 +61,7 @@
});
</script>
</head>
<body>
<div style="padding: 10px 10px 0px 10px;">
<p style="font-weight: bold;">QBT_TR(Category)QBT_TR[CONTEXT=TransferListWidget]:</p>
@ -70,4 +71,5 @@ @@ -70,4 +71,5 @@
</div>
</div>
</body>
</html>

3
src/webui/www/private/preferences.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(Download from URLs)QBT_TR[CONTEXT=downloadFromURL]</title>
@ -9,6 +10,7 @@ @@ -9,6 +10,7 @@
<script src="scripts/lib/mootools-1.2-more.js"></script>
<script src="scripts/lib/mocha-yc.js"></script>
</head>
<body style="padding: 5px;">
<!-- preferences -->
<div class="toolbarTabs">
@ -48,4 +50,5 @@ $('PrefWebUILink').addEvent('click', function(e) { @@ -48,4 +50,5 @@ $('PrefWebUILink').addEvent('click', function(e) {
});
</script>
</body>
</html>

92
src/webui/www/private/preferences_content.html

@ -15,12 +15,17 @@ @@ -15,12 +15,17 @@
<span id="appendexttr">
<input type="checkbox" id="appendext_checkbox"/>
<label for="appendext_checkbox">QBT_TR(Append .!qB extension to incomplete files)QBT_TR[CONTEXT=OptionsDialog]</label>
</span><br/><br/>
QBT_TR(Automatically add torrents from:)QBT_TR[CONTEXT=OptionsDialog]<br/>
</span><br/><br/> QBT_TR(Automatically add torrents from:)QBT_TR[CONTEXT=OptionsDialog]<br/>
<table id="watched_folders_tab" style="border: 1px solid black;">
<thead><tr><th>QBT_TR(Monitored Folder)QBT_TR[CONTEXT=ScanFoldersModel]</th><th>QBT_TR(Override Save Location)QBT_TR[CONTEXT=ScanFoldersModel]</th></tr></thead>
<thead>
<tr>
<th>QBT_TR(Monitored Folder)QBT_TR[CONTEXT=ScanFoldersModel]</th>
<th>QBT_TR(Override Save Location)QBT_TR[CONTEXT=ScanFoldersModel]</th>
</tr>
</thead>
<tbody></tbody>
<tfoot><tr>
<tfoot>
<tr>
<td style="padding-top:4px;"><input type="text" id="new_watch_folder_txt" /></td>
<td style="padding-top:4px;">
<div class="select-watched-folder-editable">
@ -33,7 +38,8 @@ @@ -33,7 +38,8 @@
<img src="theme/list-add" alt="Add" style="padding-left:170px;width:16px;cursor:pointer;" onclick="addWatchFolder();" />
</div>
</td>
</tr></tfoot>
</tr>
</tfoot>
</table><br/>
<input type="checkbox" id="exportdir_checkbox" onclick="updateExportDirEnabled();" />
<label for="exportdir_checkbox">QBT_TR(Copy .torrent files to:)QBT_TR[CONTEXT=OptionsDialog]</label>&nbsp;&nbsp;
@ -244,11 +250,9 @@ @@ -244,11 +250,9 @@
<legend><input type="checkbox" id="limit_sheduling_checkbox" onclick="updateSchedulingEnabled();" />
<label for="limit_sheduling_checkbox">QBT_TR(Schedule the use of alternative rate limits)QBT_TR[CONTEXT=OptionsDialog]</label></legend>
QBT_TR(From:)QBT_TR[CONTEXT=OptionsDialog]
<input type="text" id="schedule_from_hour" style="width: 1.5em;"/>:<input type="text" id="schedule_from_min" style="width: 1.5em;"/>
QBT_TR(To:)QBT_TR[CONTEXT=OptionsDialog]
<input type="text" id="schedule_from_hour" style="width: 1.5em;" />:<input type="text" id="schedule_from_min" style="width: 1.5em;" /> QBT_TR(To:)QBT_TR[CONTEXT=OptionsDialog]
<input type="text" id="schedule_to_hour" style="width: 1.5em;" />:<input type="text" id="schedule_to_min" style="width: 1.5em;" />
<br/>
QBT_TR(When:)QBT_TR[CONTEXT=OptionsDialog]
<br/> QBT_TR(When:)QBT_TR[CONTEXT=OptionsDialog]
<select id="schedule_freq_select">
<option value="0">QBT_TR(Every day)QBT_TR[CONTEXT=OptionsDialog]</option>
<option value="1">QBT_TR(Weekdays)QBT_TR[CONTEXT=OptionsDialog]</option>
@ -512,7 +516,8 @@ changeWatchFolderSelect = function(item) { @@ -512,7 +516,8 @@ changeWatchFolderSelect = function(item) {
if (item.value == "other") {
item.nextElementSibling.value = 'QBT_TR(Type folder here)QBT_TR[CONTEXT=HttpServer]';
item.nextElementSibling.select();
} else {
}
else {
var text = item.options[item.selectedIndex].innerHTML;
item.nextElementSibling.value = text;
}
@ -524,14 +529,14 @@ changeWatchFolderText = function(item) { @@ -524,14 +529,14 @@ changeWatchFolderText = function(item) {
pushWatchFolder = function(pos, folder, sel, other) {
var myinput = "<input id='text_watch_" + pos + "' type='text' value='" + folder + "'>";
var mycb = "<div class='select-watched-folder-editable'>" +
"<select id ='cb_watch_" + pos + "' onchange='changeWatchFolderSelect(this)'>" +
"<option value='watch_folder'>QBT_TR(Monitored folder)QBT_TR[CONTEXT=ScanFoldersModel]</option>" +
"<option value='default_folder'>QBT_TR(Default save location)QBT_TR[CONTEXT=ScanFoldersModel]</option>" +
"<option value='other'>QBT_TR(Other...)QBT_TR[CONTEXT=HttpServer]</option>" +
"</select>" +
"<input id='cb_watch_txt_" + pos + "' type='text' " +
"onchange='changeWatchFolderText(this)' /></div>";
var mycb = "<div class='select-watched-folder-editable'>"
+ "<select id ='cb_watch_" + pos + "' onchange='changeWatchFolderSelect(this)'>"
+ "<option value='watch_folder'>QBT_TR(Monitored folder)QBT_TR[CONTEXT=ScanFoldersModel]</option>"
+ "<option value='default_folder'>QBT_TR(Default save location)QBT_TR[CONTEXT=ScanFoldersModel]</option>"
+ "<option value='other'>QBT_TR(Other...)QBT_TR[CONTEXT=HttpServer]</option>"
+ "</select>"
+ "<input id='cb_watch_txt_" + pos + "' type='text' "
+ "onchange='changeWatchFolderText(this)' /></div>";
WatchedFoldersTable.push([myinput, mycb]);
$('cb_watch_' + pos).setProperty('value', sel);
@ -552,7 +557,8 @@ getWatchedFolders = function() { @@ -552,7 +557,8 @@ getWatchedFolders = function() {
var sel = $('cb_watch_' + i).getProperty('value').trim();
if (sel == "other") {
other = $('cb_watch_txt_' + i).getProperty('value').trim();
} else {
}
else {
other = (sel == "watch_folder") ? 0 : 1;
}
folders.set(fpath, other);
@ -632,7 +638,8 @@ updatePeerProxySettings = function() { @@ -632,7 +638,8 @@ updatePeerProxySettings = function() {
$('peer_proxy_auth_checkbox').setProperty('checked', isPeerProxyTypeSocks5);
updatePeerProxyAuthSettings();
}
} else {
}
else {
$('peer_proxy_auth_checkbox').setProperty('disabled', !isPeerProxyTypeSelected);
$('peer_proxy_auth_checkbox').setProperty('checked', isPeerProxyTypeSelected);
updatePeerProxyAuthSettings();
@ -738,7 +745,8 @@ updateDynDnsSettings = function() { @@ -738,7 +745,8 @@ updateDynDnsSettings = function() {
registerDynDns = function() {
if ($('dyndns_select').getProperty('value').toInt() == 1) {
window.open("http://www.no-ip.com/services/managed_dns/free_dynamic_dns.html", "NO-IP Registration");
} else {
}
else {
window.open("https://www.dyndns.com/account/services/hosts/add.html", "DynDNS Registration");
}
};
@ -776,7 +784,8 @@ loadPreferences = function() { @@ -776,7 +784,8 @@ loadPreferences = function() {
if (typeof pref.scan_dirs[folder] == "string") {
other = pref.scan_dirs[folder];
sel = "other";
} else {
}
else {
sel = (pref.scan_dirs[folder] == 0) ? "watch_folder" : "default_folder";
}
pushWatchFolder(i++, folder, sel, other);
@ -827,7 +836,8 @@ loadPreferences = function() { @@ -827,7 +836,8 @@ loadPreferences = function() {
if (max_connec <= 0) {
$('max_connec_checkbox').setProperty('checked', false);
$('max_connec_value').setProperty('value', 500);
} else {
}
else {
$('max_connec_checkbox').setProperty('checked', true);
$('max_connec_value').setProperty('value', max_connec);
}
@ -836,7 +846,8 @@ loadPreferences = function() { @@ -836,7 +846,8 @@ loadPreferences = function() {
if (max_connec_per_torrent <= 0) {
$('max_connec_per_torrent_checkbox').setProperty('checked', false);
$('max_connec_per_torrent_value').setProperty('value', 100);
} else {
}
else {
$('max_connec_per_torrent_checkbox').setProperty('checked', true);
$('max_connec_per_torrent_value').setProperty('value', max_connec_per_torrent);
}
@ -845,7 +856,8 @@ loadPreferences = function() { @@ -845,7 +856,8 @@ loadPreferences = function() {
if (max_uploads <= 0) {
$('max_uploads_checkbox').setProperty('checked', false);
$('max_uploads_value').setProperty('value', 8);
} else {
}
else {
$('max_uploads_checkbox').setProperty('checked', true);
$('max_uploads_value').setProperty('value', max_uploads);
}
@ -854,7 +866,8 @@ loadPreferences = function() { @@ -854,7 +866,8 @@ loadPreferences = function() {
if (max_uploads_per_torrent <= 0) {
$('max_uploads_per_torrent_checkbox').setProperty('checked', false);
$('max_uploads_per_torrent_value').setProperty('value', 4);
} else {
}
else {
$('max_uploads_per_torrent_checkbox').setProperty('checked', true);
$('max_uploads_per_torrent_value').setProperty('value', max_uploads_per_torrent);
}
@ -900,7 +913,8 @@ loadPreferences = function() { @@ -900,7 +913,8 @@ loadPreferences = function() {
var up_limit = pref.up_limit.toInt() / 1024;
if (up_limit <= 0) {
$('up_limit_checkbox').setProperty('checked', false);
} else {
}
else {
$('up_limit_checkbox').setProperty('checked', true);
$('up_limit_value').setProperty('value', up_limit);
}
@ -908,7 +922,8 @@ loadPreferences = function() { @@ -908,7 +922,8 @@ loadPreferences = function() {
var dl_limit = pref.dl_limit.toInt() / 1024;
if (dl_limit <= 0) {
$('dl_limit_checkbox').setProperty('checked', false);
} else {
}
else {
$('dl_limit_checkbox').setProperty('checked', true);
$('dl_limit_value').setProperty('value', dl_limit);
}
@ -921,7 +936,8 @@ loadPreferences = function() { @@ -921,7 +936,8 @@ loadPreferences = function() {
var alt_up_limit = pref.alt_up_limit.toInt() / 1024;
if (alt_up_limit <= 0) {
$('alt_up_limit_checkbox').setProperty('checked', false);
} else {
}
else {
$('alt_up_limit_checkbox').setProperty('checked', true);
$('alt_up_limit_value').setProperty('value', alt_up_limit);
}
@ -929,7 +945,8 @@ loadPreferences = function() { @@ -929,7 +945,8 @@ loadPreferences = function() {
var alt_dl_limit = pref.alt_dl_limit.toInt() / 1024;
if (alt_dl_limit <= 0) {
$('alt_dl_limit_checkbox').setProperty('checked', false);
} else {
}
else {
$('alt_dl_limit_checkbox').setProperty('checked', true);
$('alt_dl_limit_value').setProperty('value', alt_dl_limit);
}
@ -1107,18 +1124,22 @@ applyPreferences = function() { @@ -1107,18 +1124,22 @@ applyPreferences = function() {
if ($('peer_proxy_auth_checkbox').getProperty('checked')) {
proxy_type = 4;
proxy_auth_enabled = true;
} else {
}
else {
proxy_type = 2;
}
} else {
}
else {
if (proxy_type_str == "socks4") {
proxy_type = 5;
} else {
}
else {
if (proxy_type_str == "http") {
if ($('peer_proxy_auth_checkbox').getProperty('checked')) {
proxy_type = 3;
proxy_auth_enabled = true;
} else {
}
else {
proxy_type = 1;
}
}
@ -1302,7 +1323,8 @@ applyPreferences = function() { @@ -1302,7 +1323,8 @@ applyPreferences = function() {
// Send it to qBT
var json_str = JSON.encode(settings);
new Request({url: 'api/v2/app/setPreferences',
new Request({
url: 'api/v2/app/setPreferences',
method: 'post',
data: {
'json': json_str,

96
src/webui/www/private/properties_content.html

@ -3,25 +3,44 @@ @@ -3,25 +3,44 @@
<legend><b>QBT_TR(Transfer)QBT_TR[CONTEXT=PropertiesWidget]</b></legend>
<table style="width: 100%">
<tr>
<td class="generalLabel">QBT_TR(Time Active:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="time_elapsed"></td>
<td class="generalLabel">QBT_TR(ETA:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="eta"></td>
<td class="generalLabel">QBT_TR(Connections:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="nb_connections"></td>
</tr><tr>
<td class="generalLabel">QBT_TR(Downloaded:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="total_downloaded"></td>
<td class="generalLabel">QBT_TR(Uploaded:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="total_uploaded"></td>
<td class="generalLabel">QBT_TR(Seeds:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="seeds"></td>
</tr><tr>
<td class="generalLabel">QBT_TR(Download Speed:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="dl_speed"></td>
<td class="generalLabel">QBT_TR(Upload Speed:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="up_speed"></td>
<td class="generalLabel">QBT_TR(Peers:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="peers"></td>
</tr><tr>
<td class="generalLabel">QBT_TR(Download Limit:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="dl_limit"></td>
<td class="generalLabel">QBT_TR(Upload Limit:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="up_limit"></td>
<td class="generalLabel">QBT_TR(Wasted:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="total_wasted"></td>
</tr><tr>
<td class="generalLabel">QBT_TR(Share Ratio:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="share_ratio"></td>
<td class="generalLabel">QBT_TR(Reannounce In:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="reannounce"></td>
<td class="generalLabel">QBT_TR(Last Seen Complete:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="last_seen"></td>
<td class="generalLabel">QBT_TR(Time Active:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="time_elapsed"></td>
<td class="generalLabel">QBT_TR(ETA:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="eta"></td>
<td class="generalLabel">QBT_TR(Connections:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="nb_connections"></td>
</tr>
<tr>
<td class="generalLabel">QBT_TR(Downloaded:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="total_downloaded"></td>
<td class="generalLabel">QBT_TR(Uploaded:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="total_uploaded"></td>
<td class="generalLabel">QBT_TR(Seeds:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="seeds"></td>
</tr>
<tr>
<td class="generalLabel">QBT_TR(Download Speed:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="dl_speed"></td>
<td class="generalLabel">QBT_TR(Upload Speed:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="up_speed"></td>
<td class="generalLabel">QBT_TR(Peers:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="peers"></td>
</tr>
<tr>
<td class="generalLabel">QBT_TR(Download Limit:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="dl_limit"></td>
<td class="generalLabel">QBT_TR(Upload Limit:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="up_limit"></td>
<td class="generalLabel">QBT_TR(Wasted:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="total_wasted"></td>
</tr>
<tr>
<td class="generalLabel">QBT_TR(Share Ratio:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="share_ratio"></td>
<td class="generalLabel">QBT_TR(Reannounce In:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="reannounce"></td>
<td class="generalLabel">QBT_TR(Last Seen Complete:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="last_seen"></td>
</tr>
</table>
</fieldset>
@ -29,19 +48,32 @@ @@ -29,19 +48,32 @@
<legend><b>QBT_TR(Information)QBT_TR[CONTEXT=PropertiesWidget]</b></legend>
<table style="width: 100%">
<tr>
<td class="generalLabel">QBT_TR(Total Size:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="total_size"></td>
<td class="generalLabel">QBT_TR(Pieces:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="pieces"></td>
<td class="generalLabel">QBT_TR(Created By:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="created_by"></td>
</tr><tr>
<td class="generalLabel">QBT_TR(Added On:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="addition_date"></td>
<td class="generalLabel">QBT_TR(Completed On:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="completion_date"></td>
<td class="generalLabel">QBT_TR(Created On:)QBT_TR[CONTEXT=PropertiesWidget]</td><td id="creation_date"></td>
</tr><tr>
<td class="generalLabel">QBT_TR(Torrent Hash:)QBT_TR[CONTEXT=PropertiesWidget]</td><td colspan="5" id="torrent_hash"></td>
</tr><tr>
<td class="generalLabel">QBT_TR(Save Path:)QBT_TR[CONTEXT=PropertiesWidget]</td><td colspan="5" id="save_path"></td>
</tr><tr>
<td class="generalLabel">QBT_TR(Comment:)QBT_TR[CONTEXT=PropertiesWidget]</td><td colspan="5" style="white-space: pre-wrap;" id="comment"></td>
<td class="generalLabel">QBT_TR(Total Size:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="total_size"></td>
<td class="generalLabel">QBT_TR(Pieces:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="pieces"></td>
<td class="generalLabel">QBT_TR(Created By:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="created_by"></td>
</tr>
<tr>
<td class="generalLabel">QBT_TR(Added On:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="addition_date"></td>
<td class="generalLabel">QBT_TR(Completed On:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="completion_date"></td>
<td class="generalLabel">QBT_TR(Created On:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td id="creation_date"></td>
</tr>
<tr>
<td class="generalLabel">QBT_TR(Torrent Hash:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td colspan="5" id="torrent_hash"></td>
</tr>
<tr>
<td class="generalLabel">QBT_TR(Save Path:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td colspan="5" id="save_path"></td>
</tr>
<tr>
<td class="generalLabel">QBT_TR(Comment:)QBT_TR[CONTEXT=PropertiesWidget]</td>
<td colspan="5" style="white-space: pre-wrap;" id="comment"></td>
</tr>
</table>
</fieldset>

3
src/webui/www/private/rename.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(Rename)QBT_TR[CONTEXT=TransferListWidget]</title>
@ -51,6 +52,7 @@ @@ -51,6 +52,7 @@
});
</script>
</head>
<body>
<div style="padding: 10px 10px 0px 10px;">
<p style="font-weight: bold;">QBT_TR(New name)QBT_TR[CONTEXT=TransferListWidget]:</p>
@ -60,4 +62,5 @@ @@ -60,4 +62,5 @@
</div>
</div>
</body>
</html>

31
src/webui/www/private/scripts/client.js

@ -203,7 +203,10 @@ window.addEvent('load', function () { @@ -203,7 +203,10 @@ window.addEvent('load', function () {
}
var categoryHash = genHash(category);
if (category_list[categoryHash] === null) // This should not happen
category_list[categoryHash] = {name: category, torrents: []};
category_list[categoryHash] = {
name: category,
torrents: []
};
if (!Object.contains(category_list[categoryHash].torrents, torrent['hash'])) {
removeTorrentFromCategoryList(torrent['hash']);
category_list[categoryHash].torrents = category_list[categoryHash].torrents.combine([torrent['hash']]);
@ -235,10 +238,13 @@ window.addEvent('load', function () { @@ -235,10 +238,13 @@ window.addEvent('load', function () {
categoryList.empty();
var create_link = function(hash, text, count) {
var html = '<a href="#" onclick="setCategoryFilter(' + hash + ');return false;">' +
'<img src="theme/inode-directory"/>' +
escapeHtml(text) + ' (' + count + ')' + '</a>';
var el = new Element('li', {id: hash, html: html});
var html = '<a href="#" onclick="setCategoryFilter(' + hash + ');return false;">'
+ '<img src="theme/inode-directory"/>'
+ escapeHtml(text) + ' (' + count + ')' + '</a>';
var el = new Element('li', {
id: hash,
html: html
});
categoriesFilterContextMenu.addTarget(el);
return el;
};
@ -312,7 +318,10 @@ window.addEvent('load', function () { @@ -312,7 +318,10 @@ window.addEvent('load', function () {
if (response['categories']) {
response['categories'].each(function(category) {
var categoryHash = genHash(category);
category_list[categoryHash] = {name: category, torrents: []};
category_list[categoryHash] = {
name: category,
torrents: []
};
});
update_categories = true;
}
@ -390,7 +399,8 @@ window.addEvent('load', function () { @@ -390,7 +399,8 @@ window.addEvent('load', function () {
if (speedInTitle) {
document.title = "QBT_TR([D: %1, U: %2] qBittorrent %3)QBT_TR[CONTEXT=MainWindow]".replace("%1", friendlyUnit(serverState.dl_info_speed, true)).replace("%2", friendlyUnit(serverState.up_info_speed, true)).replace("%3", "${VERSION}");
document.title += " QBT_TR(Web UI)QBT_TR[CONTEXT=OptionsDialog]";
}else
}
else
document.title = "qBittorrent ${VERSION} QBT_TR(Web UI)QBT_TR[CONTEXT=OptionsDialog]";
$('DHTNodes').set('html', 'QBT_TR(DHT: %1 nodes)QBT_TR[CONTEXT=StatusBar]'.replace("%1", serverState.dht_nodes));
@ -460,7 +470,8 @@ window.addEvent('load', function () { @@ -460,7 +470,8 @@ window.addEvent('load', function () {
// Change icon immediately to give some feedback
updateAltSpeedIcon(!alternativeSpeedLimits);
new Request({url: 'api/v2/transfer/toggleSpeedLimitsMode',
new Request({
url: 'api/v2/transfer/toggleSpeedLimitsMode',
method: 'post',
onComplete: function() {
alternativeSpeedLimits = !alternativeSpeedLimits;
@ -680,8 +691,8 @@ var loadTorrentPeersTimer; @@ -680,8 +691,8 @@ var loadTorrentPeersTimer;
var syncTorrentPeersLastResponseId = 0;
var show_flags = true;
var loadTorrentPeersData = function() {
if ($('prop_peers').hasClass('invisible') ||
$('propertiesPanel_collapseToggle').hasClass('panel-expand')) {
if ($('prop_peers').hasClass('invisible')
|| $('propertiesPanel_collapseToggle').hasClass('panel-expand')) {
syncTorrentPeersLastResponseId = 0;
torrentPeersTable.clear();
return;

15
src/webui/www/private/scripts/contextmenu.js

@ -310,7 +310,8 @@ var TorrentsTableContextMenu = new Class({ @@ -310,7 +310,8 @@ var TorrentsTableContextMenu = new Class({
this.hideItem('FirstLastPiecePrio');
this.showItem('SuperSeeding');
this.setItemChecked('SuperSeeding', all_are_super_seeding);
} else {
}
else {
if (!show_seq_dl && show_f_l_piece_prio)
this.menu.getElement('a[href$=FirstLastPiecePrio]').parentNode.addClass('separator');
else
@ -354,8 +355,12 @@ var TorrentsTableContextMenu = new Class({ @@ -354,8 +355,12 @@ var TorrentsTableContextMenu = new Class({
updateCategoriesSubMenu: function(category_list) {
var categoryList = $('contextCategoryList');
categoryList.empty();
categoryList.appendChild(new Element('li', {html: '<a href="javascript:torrentNewCategoryFN();"><img src="theme/list-add" alt="QBT_TR(New...)QBT_TR[CONTEXT=TransferListWidget]"/> QBT_TR(New...)QBT_TR[CONTEXT=TransferListWidget]</a>'}));
categoryList.appendChild(new Element('li', {html: '<a href="javascript:torrentSetCategoryFN(0);"><img src="theme/edit-clear" alt="QBT_TR(Reset)QBT_TR[CONTEXT=TransferListWidget]"/> QBT_TR(Reset)QBT_TR[CONTEXT=TransferListWidget]</a>'}));
categoryList.appendChild(new Element('li', {
html: '<a href="javascript:torrentNewCategoryFN();"><img src="theme/list-add" alt="QBT_TR(New...)QBT_TR[CONTEXT=TransferListWidget]"/> QBT_TR(New...)QBT_TR[CONTEXT=TransferListWidget]</a>'
}));
categoryList.appendChild(new Element('li', {
html: '<a href="javascript:torrentSetCategoryFN(0);"><img src="theme/edit-clear" alt="QBT_TR(Reset)QBT_TR[CONTEXT=TransferListWidget]"/> QBT_TR(Reset)QBT_TR[CONTEXT=TransferListWidget]</a>'
}));
var sortedCategories = [];
Object.each(category_list, function(category) {
@ -366,7 +371,9 @@ var TorrentsTableContextMenu = new Class({ @@ -366,7 +371,9 @@ var TorrentsTableContextMenu = new Class({
var first = true;
Object.each(sortedCategories, function(categoryName) {
var categoryHash = genHash(categoryName);
var el = new Element('li', {html: '<a href="javascript:torrentSetCategoryFN(\'' + categoryHash + '\');"><img src="theme/inode-directory"/> ' + escapeHtml(categoryName) + '</a>'});
var el = new Element('li', {
html: '<a href="javascript:torrentSetCategoryFN(\'' + categoryHash + '\');"><img src="theme/inode-directory"/> ' + escapeHtml(categoryName) + '</a>'
});
if (first) {
el.addClass('separator');
first = false;

32
src/webui/www/private/scripts/dynamicTable.js

@ -60,8 +60,7 @@ var DynamicTable = new Class({ @@ -60,8 +60,7 @@ var DynamicTable = new Class({
setupCommonEvents: function() {
var scrollFn = function() {
$(this.dynamicTableFixedHeaderDivId).getElements('table')[0].style.left =
-$(this.dynamicTableDivId).scrollLeft + 'px';
$(this.dynamicTableFixedHeaderDivId).getElements('table')[0].style.left = -$(this.dynamicTableDivId).scrollLeft + 'px';
}.bind(this);
$(this.dynamicTableDivId).addEvent('scroll', scrollFn);
@ -131,7 +130,8 @@ var DynamicTable = new Class({ @@ -131,7 +130,8 @@ var DynamicTable = new Class({
this.resizeTh = e.target.getPrevious('[class=""]');
this.canResize = true;
e.target.getParent("tr").style.cursor = 'col-resize';
} else {
}
else {
this.canResize = false;
e.target.getParent("tr").style.cursor = '';
}
@ -244,7 +244,10 @@ var DynamicTable = new Class({ @@ -244,7 +244,10 @@ var DynamicTable = new Class({
th.addEvent('mousemove', mouseMoveFn);
th.addEvent('mouseout', mouseOutFn);
th.makeResizable({
modifiers : {x: '', y: ''},
modifiers: {
x: '',
y: ''
},
onBeforeStart: onBeforeStart,
onStart: onStart,
onDrag: onDrag,
@ -283,11 +286,16 @@ var DynamicTable = new Class({ @@ -283,11 +286,16 @@ var DynamicTable = new Class({
var menuId = this.dynamicTableDivId + '_headerMenu';
var ul = new Element('ul', {id: menuId, class: 'contextMenu scrollableMenu'});
var ul = new Element('ul', {
id: menuId,
class: 'contextMenu scrollableMenu'
});
var createLi = function(columnName, text) {
var html = '<a href="#' + columnName + '" ><img src="theme/checked"/>' + escapeHtml(text) + '</a>';
return new Element('li', {html: html});
return new Element('li', {
html: html
});
};
var actions = {};
@ -432,8 +440,7 @@ var DynamicTable = new Class({ @@ -432,8 +440,7 @@ var DynamicTable = new Class({
for (var j = 0; j < trs.length; j++)
trs[j].getElements('td')[pos].addClass('invisible');
}
if (this.columns[pos].onResize !== null)
{
if (this.columns[pos].onResize !== null) {
this.columns[pos].onResize(columnName);
}
},
@ -466,7 +473,8 @@ var DynamicTable = new Class({ @@ -466,7 +473,8 @@ var DynamicTable = new Class({
trs.each(function(el, i) {
if (i % 2) {
el.addClass('alt');
} else {
}
else {
el.removeClass('alt');
}
}.bind(this));
@ -535,8 +543,7 @@ var DynamicTable = new Class({ @@ -535,8 +543,7 @@ var DynamicTable = new Class({
var rows = this.rows.getValues();
for (i = 0; i < rows.length; i++)
{
for (i = 0; i < rows.length; i++) {
filteredRows.push(rows[i]);
filteredRows[rows[i].rowId] = rows[i];
}
@ -642,7 +649,8 @@ var DynamicTable = new Class({ @@ -642,7 +649,8 @@ var DynamicTable = new Class({
tr.removeClass('selected');
}
}
} else {
}
else {
// Simple selection
this._this.selectRow(this.rowId);
}

16
src/webui/www/private/scripts/misc.js

@ -90,14 +90,14 @@ if (!Date.prototype.toISOString) { @@ -90,14 +90,14 @@ if (!Date.prototype.toISOString) {
}
Date.prototype.toISOString = function() {
return this.getUTCFullYear() +
'-' + pad(this.getUTCMonth() + 1) +
'-' + pad(this.getUTCDate()) +
'T' + pad(this.getUTCHours()) +
':' + pad(this.getUTCMinutes()) +
':' + pad(this.getUTCSeconds()) +
'.' + (this.getUTCMilliseconds() / 1000).toFixed(3).slice(2, 5) +
'Z';
return this.getUTCFullYear()
+ '-' + pad(this.getUTCMonth() + 1)
+ '-' + pad(this.getUTCDate())
+ 'T' + pad(this.getUTCHours())
+ ':' + pad(this.getUTCMinutes())
+ ':' + pad(this.getUTCSeconds())
+ '.' + (this.getUTCMilliseconds() / 1000).toFixed(3).slice(2, 5)
+ 'Z';
};
}());

4
src/webui/www/private/scripts/prop-files.js

@ -273,8 +273,8 @@ var filesDynTable = new Class({ @@ -273,8 +273,8 @@ var filesDynTable = new Class({
var loadTorrentFilesDataTimer;
var loadTorrentFilesData = function() {
if ($('prop_files').hasClass('invisible') ||
$('propertiesPanel_collapseToggle').hasClass('panel-expand')) {
if ($('prop_files').hasClass('invisible')
|| $('propertiesPanel_collapseToggle').hasClass('panel-expand')) {
// Tab changed, don't do anything
return;
}

4
src/webui/www/private/scripts/prop-general.js

@ -27,8 +27,8 @@ var clearData = function() { @@ -27,8 +27,8 @@ var clearData = function() {
var loadTorrentDataTimer;
var loadTorrentData = function() {
if ($('prop_general').hasClass('invisible') ||
$('propertiesPanel_collapseToggle').hasClass('panel-expand')) {
if ($('prop_general').hasClass('invisible')
|| $('propertiesPanel_collapseToggle').hasClass('panel-expand')) {
// Tab changed, don't do anything
return;
}

4
src/webui/www/private/scripts/prop-trackers.js

@ -54,8 +54,8 @@ var current_hash = ""; @@ -54,8 +54,8 @@ var current_hash = "";
var loadTrackersDataTimer;
var loadTrackersData = function() {
if ($('prop_trackers').hasClass('invisible') ||
$('propertiesPanel_collapseToggle').hasClass('panel-expand')) {
if ($('prop_trackers').hasClass('invisible')
|| $('propertiesPanel_collapseToggle').hasClass('panel-expand')) {
// Tab changed, don't do anything
return;
}

4
src/webui/www/private/scripts/prop-webseeds.js

@ -54,8 +54,8 @@ var current_hash = ""; @@ -54,8 +54,8 @@ var current_hash = "";
var loadWebSeedsDataTimer;
var loadWebSeedsData = function() {
if ($('prop_webseeds').hasClass('invisible') ||
$('propertiesPanel_collapseToggle').hasClass('panel-expand')) {
if ($('prop_webseeds').hasClass('invisible')
|| $('propertiesPanel_collapseToggle').hasClass('panel-expand')) {
// Tab changed, don't do anything
return;
}

3
src/webui/www/private/setlocation.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(Set location)QBT_TR[CONTEXT=HttpServer]</title>
@ -43,6 +44,7 @@ @@ -43,6 +44,7 @@
});
</script>
</head>
<body>
<div style="padding: 10px 10px 0px 10px;">
<p style="font-weight: bold;">QBT_TR(Location)QBT_TR[CONTEXT=TransferListWidget]:</p>
@ -52,4 +54,5 @@ @@ -52,4 +54,5 @@
</div>
</div>
</body>
</html>

1
src/webui/www/private/transferlist.html

@ -16,7 +16,6 @@ @@ -16,7 +16,6 @@
</div>
<script>
//create a context menu
var torrentsTableContextMenu = new TorrentsTableContextMenu({
targets: '.torrentsTableContextMenuTarget',

4
src/webui/www/private/upload.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(Upload local torrent)QBT_TR[CONTEXT=HttpServer]</title>
@ -8,6 +9,7 @@ @@ -8,6 +9,7 @@
<script src="scripts/lib/mootools-1.2-core-yc.js"></script>
<script src="scripts/download.js"></script>
</head>
<body>
<iframe id="upload_frame" name="upload_frame" class="invisible" src="javascript:false;"></iframe>
<form action="api/v2/torrents/add" enctype="multipart/form-data" method="post" id="uploadForm" style="text-align: center;" target="upload_frame">
@ -62,7 +64,6 @@ @@ -62,7 +64,6 @@
</fieldset>
</form>
<script>
var submitted = false;
$('uploadForm').addEventListener("submit", function() {
@ -81,4 +82,5 @@ $('start_torrent').addEventListener('change', function() { @@ -81,4 +82,5 @@ $('start_torrent').addEventListener('change', function() {
</script>
<div id="upload_spinner" class="mochaSpinner"></div>
</body>
</html>

3
src/webui/www/private/uploadlimit.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(Torrent Upload Speed Limiting)QBT_TR[CONTEXT=TransferListWidget]</title>
@ -9,6 +10,7 @@ @@ -9,6 +10,7 @@
<script src="scripts/lib/mocha-yc.js"></script>
<script src="scripts/lib/parametrics.js"></script>
</head>
<body>
<div style="width: 100%; text-align: center; margin: 0 auto; overflow: hidden">
<div id="uplimitSlider" class="slider">
@ -59,4 +61,5 @@ @@ -59,4 +61,5 @@
</script>
</body>
</html>

9
src/webui/www/public/login.html

@ -1,5 +1,6 @@ @@ -1,5 +1,6 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>qBittorrent QBT_TR(Web UI)QBT_TR[CONTEXT=OptionsDialog]</title>
@ -30,7 +31,8 @@ @@ -30,7 +31,8 @@
onFailure: function(xhr) {
if (xhr.responseText !== "") {
$('error_msg').set('html', xhr.responseText);
} else {
}
else {
$('error_msg').set('html', 'QBT_TR(Unable to log in, qBittorrent is probably unreachable.)QBT_TR[CONTEXT=HttpServer]');
}
},
@ -38,7 +40,8 @@ @@ -38,7 +40,8 @@
if (text == "Ok.") {
// Session started. Simply reload page.
window.location.reload();
} else {
}
else {
$('error_msg').set('html', 'QBT_TR(Invalid Username or Password.)QBT_TR[CONTEXT=HttpServer]');
}
}
@ -46,6 +49,7 @@ @@ -46,6 +49,7 @@
}
</script>
</head>
<body>
<div id="main">
<h1>qBittorrent QBT_TR(Web UI)QBT_TR[CONTEXT=OptionsDialog]</h1>
@ -68,4 +72,5 @@ @@ -68,4 +72,5 @@
<div id="error_msg"></div>
</div>
</body>
</html>

Loading…
Cancel
Save