From 5a83759ee21d4b63e56ece984909d16ddf505371 Mon Sep 17 00:00:00 2001 From: ansuz Date: Fri, 14 Apr 2017 17:18:17 +0200 Subject: [PATCH] add usage button to settings page --- www/settings/main.js | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/www/settings/main.js b/www/settings/main.js index 64bf15f7b..cee0772b0 100644 --- a/www/settings/main.js +++ b/www/settings/main.js @@ -227,6 +227,40 @@ define([ return $div; }; + var bytesToMegabytes = function (bytes) { + return Math.floor((bytes / (1024 * 1024) * 100)) / 100; + }; + + var createUsageButton = function (obj) { + var proxy = obj.proxy; + + var $div = $('
', { 'class': 'pinned-usage' }) + .text(Messages.settings_usageTitle) + .append('
'); + + $('