diff options
Diffstat (limited to 'module/web/templates')
-rw-r--r-- | module/web/templates/default/base.html | 48 |
1 files changed, 41 insertions, 7 deletions
diff --git a/module/web/templates/default/base.html b/module/web/templates/default/base.html index 772d46a00..94b574046 100644 --- a/module/web/templates/default/base.html +++ b/module/web/templates/default/base.html @@ -15,6 +15,32 @@ <script type="text/javascript" src="static/js/libs/underscore-min.js"></script>
<script type="text/javascript" src="static/js/libs/backbone-min.js"></script>
+ <script>
+
+ // id has to look like: #check_name
+ // value is true, false or toggle
+ // iconclass has to be pyload-icon-name-activated and pyload-icon-name-deactivated
+ function setCheckedButton(id, value) {
+ var splitted = id.split("_")
+ if (value == "true") {
+ $( id ).setAttribute("class",'pyload-icon-' + splitted[1] + "-activated");
+ $( id ).checked = true;
+ } else if (value == "false") {
+ $( id ).setAttribute("class",'pyload-icon-' + splitted[1] + "-deactivated");
+ $( id ).checked = false;
+ } else { //toggle
+ if ($( id ).checked == true) {
+ $( id ).setAttribute("class",'pyload-icon-' + splitted[1] + "-deactivated");
+ $( id ).checked = false;
+ } else {
+ $( id ).setAttribute("class",'pyload-icon-' + splitted[1] + "-activated");
+ $( id ).checked = true;
+ }
+ }
+ }
+
+ </script>
+
<title>{% block title %}pyLoad {{ _("Webinterface") }}{% endblock %}</title>
{% block head %}
@@ -32,14 +58,22 @@ </div>
<div id="speedgraph"></div>
- <div class="header_block">
- <div class="icon_info">
- <img src="static/img/default/icon_speed_small_white.png" height="20px"/><span>500 kb/s</span>
- </div>
- <div class="icon_info">
- <img src="static/img/default/icon_clock_small_white.png" height="20px"/><span>5 / 125</span>
- </div>
+
+ <div class="header_block">
+ <div id="check_reconnecting" class="pyload-icon-reconnecting-deactivated"></div>
+ <div id="check_downloading" class="pyload-icon-downloading-deactivated"></div>
</div>
+
+ <div class="header_block">
+ <div id="speedmeter">
+ <div id="speedmeter_icon" class="header-icon"></div>
+ <span id="speedmeter_value" class="header_text">250KiB/s</span>
+ </div>
+ <div id="downloads">
+ <div id="downloads_icon" class="header-icon"></div>
+ <span id="downloads_value" class="header_text">3/126/212</span>
+ </div>
+ </div>
</div>
</header>
<div id="push"></div>
|