From: Robert Kaiser Date: Fri, 14 Nov 2014 02:09:55 +0000 (+0100) Subject: make switch actually look good and work correctly X-Git-Tag: production~2 X-Git-Url: https://git-public.kairo.at/?a=commitdiff_plain;h=9adf799b4ff4fae3049fac6e03c54340065ae2de;p=tricorder.git make switch actually look good and work correctly --- diff --git a/index.html b/index.html index f8cb293..5f4979b 100644 --- a/index.html +++ b/index.html @@ -124,9 +124,9 @@ a better device. Distance:...
diff --git a/js/tricorder.js b/js/tricorder.js index f8bc28f..92885da 100644 --- a/js/tricorder.js +++ b/js/tricorder.js @@ -376,8 +376,8 @@ var gModEnv = { switchFlashlight: function(aEnabled) { if (this.flashCamera) { this.flashCamera.flashMode = aEnabled ? 'torch' : 'off'; - document.getElementById("envFlashOn").disabled == aEnabled; - document.getElementById("envFlashOff").disabled == !aEnabled; + document.getElementById("envFlashOn").disabled = aEnabled; + document.getElementById("envFlashOff").disabled = !aEnabled; } } } diff --git a/style/tricorder.css b/style/tricorder.css index cc79ade..d60e7aa 100644 --- a/style/tricorder.css +++ b/style/tricorder.css @@ -248,10 +248,9 @@ button { color: #000000; background-color: #C09070; border-radius: 3000px; - margin: 0 .25em; } -button.disabled { +button:disabled { background-color: #402858; } @@ -276,19 +275,28 @@ button.disabled { } #envFlashAvail { - padding: 1em 3px 0; + margin-top: .5em; + padding: .5em 3px 0; + border-top: 2px solid #A09090; +} + +.envButton { + font-size: 200%; + margin-top: .25em; } #envFlashOn { - margin-right: 0; + margin-right: 3px; border-top-right-radius: 0; border-bottom-right-radius: 0; + padding-left: .5em; } #envFlashOff { margin-left: 0; border-top-left-radius: 0; border-bottom-left-radius: 0; + padding-right: .5em; } @media screen and (min-width: 500px) {