Browse Source

Merge pull request #11054 from Piccirello/tom_organize_assets

Organize WebUI assets
adaptive-webui-19844
Vladimir Golovnev 5 years ago committed by GitHub
parent
commit
2cac830749
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 61
      src/webui/www/private/preferences.html
  2. 10
      src/webui/www/private/scripts/client.js
  3. 10
      src/webui/www/private/scripts/mocha-init.js
  4. 0
      src/webui/www/private/views/about.html
  5. 0
      src/webui/www/private/views/aboutToolbar.html
  6. 0
      src/webui/www/private/views/filters.html
  7. 0
      src/webui/www/private/views/installsearchplugin.html
  8. 0
      src/webui/www/private/views/preferences.html
  9. 44
      src/webui/www/private/views/preferencesToolbar.html
  10. 0
      src/webui/www/private/views/properties.html
  11. 0
      src/webui/www/private/views/propertiesToolbar.html
  12. 2
      src/webui/www/private/views/search.html
  13. 2
      src/webui/www/private/views/searchplugins.html
  14. 0
      src/webui/www/private/views/statistics.html
  15. 0
      src/webui/www/private/views/transferlist.html
  16. 24
      src/webui/www/webui.qrc

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

@ -1,61 +0,0 @@ @@ -1,61 +0,0 @@
<!DOCTYPE html>
<html lang="${LANG}">
<head>
<meta charset="UTF-8" />
<title>QBT_TR(Download from URLs)QBT_TR[CONTEXT=downloadFromURL]</title>
<link rel="stylesheet" href="css/style.css?v=${CACHEID}" type="text/css" />
<link rel="stylesheet" href="css/Tabs.css?v=${CACHEID}" type="text/css" />
<script src="scripts/lib/mootools-1.2-core-yc.js"></script>
<script src="scripts/lib/mootools-1.2-more.js"></script>
<script src="scripts/lib/mocha-0.9.6-yc.js"></script>
</head>
<body style="padding: 5px;">
<!-- preferences -->
<div class="toolbarTabs">
<ul id="preferencesTabs" class="tab-menu">
<li id="PrefDownloadsLink" class="selected"><a>QBT_TR(Downloads)QBT_TR[CONTEXT=OptionsDialog]</a></li>
<li id="PrefConnectionLink"><a>QBT_TR(Connection)QBT_TR[CONTEXT=OptionsDialog]</a></li>
<li id="PrefSpeedLink"><a>QBT_TR(Speed)QBT_TR[CONTEXT=OptionsDialog]</a></li>
<li id="PrefBittorrentLink"><a>QBT_TR(BitTorrent)QBT_TR[CONTEXT=OptionsDialog]</a></li>
<li id="PrefWebUILink"><a>QBT_TR(Web UI)QBT_TR[CONTEXT=OptionsDialog]</a></li>
<li id="PrefAdvancedLink"><a>QBT_TR(Advanced)QBT_TR[CONTEXT=OptionsDialog]</a></li>
</ul>
<div class="clear"></div>
</div>
<script>
'use strict';
// Tabs
MochaUI.initializeTabs('preferencesTabs');
$('PrefDownloadsLink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('DownloadsTab').removeClass('invisible');
});
$('PrefConnectionLink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('ConnectionTab').removeClass('invisible');
});
$('PrefSpeedLink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('SpeedTab').removeClass('invisible');
});
$('PrefBittorrentLink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('BittorrentTab').removeClass('invisible');
});
$('PrefWebUILink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('WebUITab').removeClass('invisible');
});
$('PrefAdvancedLink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('AdvancedTab').removeClass('invisible');
});
</script>
</body>
</html>

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

@ -223,7 +223,7 @@ window.addEvent('load', function() { @@ -223,7 +223,7 @@ window.addEvent('load', function() {
left: 0
},
loadMethod: 'xhr',
contentURL: 'filters.html',
contentURL: 'views/filters.html',
onContentLoaded: function() {
setFilter(selected_filter);
},
@ -826,7 +826,7 @@ window.addEvent('load', function() { @@ -826,7 +826,7 @@ window.addEvent('load', function() {
left: 0
},
loadMethod: 'xhr',
contentURL: 'search.html',
contentURL: 'views/search.html',
content: '',
column: 'searchTabColumn',
height: null
@ -844,7 +844,7 @@ window.addEvent('load', function() { @@ -844,7 +844,7 @@ window.addEvent('load', function() {
left: 0
},
loadMethod: 'xhr',
contentURL: 'transferlist.html',
contentURL: 'views/transferlist.html',
onContentLoaded: function() {
handleDownloadParam();
updateMainData();
@ -868,12 +868,12 @@ window.addEvent('load', function() { @@ -868,12 +868,12 @@ window.addEvent('load', function() {
bottom: 0,
left: 0
},
contentURL: 'properties_content.html',
contentURL: 'views/properties.html',
require: {
css: ['css/Tabs.css', 'css/dynamicTable.css'],
js: ['scripts/prop-general.js', 'scripts/prop-trackers.js', 'scripts/prop-peers.js', 'scripts/prop-webseeds.js', 'scripts/prop-files.js'],
},
tabsURL: 'properties.html',
tabsURL: 'views/propertiesToolbar.html',
tabsOnload: function() {
MochaUI.initializeTabs('propertiesTabs');

10
src/webui/www/private/scripts/mocha-init.js

@ -169,11 +169,11 @@ const initializeWindows = function() { @@ -169,11 +169,11 @@ const initializeWindows = function() {
title: "QBT_TR(Options)QBT_TR[CONTEXT=OptionsDialog]",
loadMethod: 'xhr',
toolbar: true,
contentURL: 'preferences_content.html',
contentURL: 'views/preferences.html',
require: {
css: ['css/Tabs.css']
},
toolbarURL: 'preferences.html',
toolbarURL: 'views/preferencesToolbar.html',
maximizable: false,
closable: true,
paddingVertical: 0,
@ -362,7 +362,7 @@ const initializeWindows = function() { @@ -362,7 +362,7 @@ const initializeWindows = function() {
id: id,
title: 'QBT_TR(Statistics)QBT_TR[CONTEXT=StatsDialog]',
loadMethod: 'xhr',
contentURL: 'statistics.html',
contentURL: 'views/statistics.html',
maximizable: false,
padding: 10,
width: loadWindowWidth(id, 275),
@ -920,12 +920,12 @@ const initializeWindows = function() { @@ -920,12 +920,12 @@ const initializeWindows = function() {
id: id,
title: 'QBT_TR(About qBittorrent)QBT_TR[CONTEXT=AboutDialog]',
loadMethod: 'xhr',
contentURL: 'about.html',
contentURL: 'views/about.html',
require: {
css: ['css/Tabs.css']
},
toolbar: true,
toolbarURL: 'aboutToolbar.html',
toolbarURL: 'views/aboutToolbar.html',
padding: 10,
width: loadWindowWidth(id, 550),
height: loadWindowHeight(id, 360),

0
src/webui/www/private/about.html → src/webui/www/private/views/about.html

0
src/webui/www/private/aboutToolbar.html → src/webui/www/private/views/aboutToolbar.html

0
src/webui/www/private/filters.html → src/webui/www/private/views/filters.html

0
src/webui/www/private/installsearchplugin.html → src/webui/www/private/views/installsearchplugin.html

0
src/webui/www/private/preferences_content.html → src/webui/www/private/views/preferences.html

44
src/webui/www/private/views/preferencesToolbar.html

@ -0,0 +1,44 @@ @@ -0,0 +1,44 @@
<!-- preferences -->
<div class="toolbarTabs">
<ul id="preferencesTabs" class="tab-menu">
<li id="PrefDownloadsLink" class="selected"><a>QBT_TR(Downloads)QBT_TR[CONTEXT=OptionsDialog]</a></li>
<li id="PrefConnectionLink"><a>QBT_TR(Connection)QBT_TR[CONTEXT=OptionsDialog]</a></li>
<li id="PrefSpeedLink"><a>QBT_TR(Speed)QBT_TR[CONTEXT=OptionsDialog]</a></li>
<li id="PrefBittorrentLink"><a>QBT_TR(BitTorrent)QBT_TR[CONTEXT=OptionsDialog]</a></li>
<li id="PrefWebUILink"><a>QBT_TR(Web UI)QBT_TR[CONTEXT=OptionsDialog]</a></li>
<li id="PrefAdvancedLink"><a>QBT_TR(Advanced)QBT_TR[CONTEXT=OptionsDialog]</a></li>
</ul>
<div class="clear"></div>
</div>
<script>
'use strict';
// Tabs
MochaUI.initializeTabs('preferencesTabs');
$('PrefDownloadsLink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('DownloadsTab').removeClass('invisible');
});
$('PrefConnectionLink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('ConnectionTab').removeClass('invisible');
});
$('PrefSpeedLink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('SpeedTab').removeClass('invisible');
});
$('PrefBittorrentLink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('BittorrentTab').removeClass('invisible');
});
$('PrefWebUILink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('WebUITab').removeClass('invisible');
});
$('PrefAdvancedLink').addEvent('click', function(e) {
$$('.PrefTab').addClass('invisible');
$('AdvancedTab').removeClass('invisible');
});
</script>

0
src/webui/www/private/properties_content.html → src/webui/www/private/views/properties.html

0
src/webui/www/private/properties.html → src/webui/www/private/views/propertiesToolbar.html

2
src/webui/www/private/search.html → src/webui/www/private/views/search.html

@ -350,7 +350,7 @@ @@ -350,7 +350,7 @@
id: id,
title: "QBT_TR(Search plugins)QBT_TR[CONTEXT=PluginSelectDlg]",
loadMethod: 'xhr',
contentURL: 'searchplugins.html',
contentURL: 'views/searchplugins.html',
scrollbars: false,
maximizable: false,
paddingVertical: 0,

2
src/webui/www/private/searchplugins.html → src/webui/www/private/views/searchplugins.html

@ -106,7 +106,7 @@ @@ -106,7 +106,7 @@
id: 'installSearchPlugin',
title: "QBT_TR(Install plugin)QBT_TR[CONTEXT=PluginSourceDlg]",
loadMethod: 'xhr',
contentURL: 'installsearchplugin.html',
contentURL: 'views/installsearchplugin.html',
scrollbars: false,
resizable: false,
maximizable: false,

0
src/webui/www/private/statistics.html → src/webui/www/private/views/statistics.html

0
src/webui/www/private/transferlist.html → src/webui/www/private/views/transferlist.html

24
src/webui/www/webui.qrc

@ -1,7 +1,5 @@ @@ -1,7 +1,5 @@
<RCC>
<qresource prefix="/www">
<file>private/about.html</file>
<file>private/aboutToolbar.html</file>
<file>private/addpeers.html</file>
<file>private/addtrackers.html</file>
<file>private/confirmdeletion.html</file>
@ -15,18 +13,10 @@ @@ -15,18 +13,10 @@
<file>private/download.html</file>
<file>private/downloadlimit.html</file>
<file>private/edittracker.html</file>
<file>private/filters.html</file>
<file>private/index.html</file>
<file>private/installsearchplugin.html</file>
<file>private/newcategory.html</file>
<file>private/newtag.html</file>
<file>private/preferences.html</file>
<file>private/preferences_content.html</file>
<file>private/properties.html</file>
<file>private/properties_content.html</file>
<file>private/rename.html</file>
<file>private/search.html</file>
<file>private/searchplugins.html</file>
<file>private/scripts/client.js</file>
<file>private/scripts/contextmenu.js</file>
<file>private/scripts/download.js</file>
@ -48,10 +38,20 @@ @@ -48,10 +38,20 @@
<file>private/scripts/speedslider.js</file>
<file>private/setlocation.html</file>
<file>private/shareratio.html</file>
<file>private/statistics.html</file>
<file>private/transferlist.html</file>
<file>private/upload.html</file>
<file>private/uploadlimit.html</file>
<file>private/views/about.html</file>
<file>private/views/aboutToolbar.html</file>
<file>private/views/filters.html</file>
<file>private/views/installsearchplugin.html</file>
<file>private/views/preferences.html</file>
<file>private/views/preferencesToolbar.html</file>
<file>private/views/properties.html</file>
<file>private/views/propertiesToolbar.html</file>
<file>private/views/search.html</file>
<file>private/views/searchplugins.html</file>
<file>private/views/statistics.html</file>
<file>private/views/transferlist.html</file>
<file>public/css/login.css</file>
<file>public/css/noscript.css</file>
<file>public/index.html</file>

Loading…
Cancel
Save