0
0
mirror of https://github.com/Doodle3D/doodle3d-client.git synced 2024-11-22 09:17:56 +01:00

Whitespace fixes.

This commit is contained in:
Wouter R 2014-02-24 15:58:50 +01:00
parent ce489112e8
commit afb279fbc7
2 changed files with 131 additions and 102 deletions

View File

@ -12,32 +12,32 @@ function UpdatePanel() {
this.wifiboxURL; this.wifiboxURL;
this.element; this.element;
this.statusCheckInterval = 1000; this.statusCheckInterval = 1000;
this.statusCheckDelayer; // setTimout instance this.statusCheckDelayer; // setTimout instance
this.installedDelay = 90*1000; // Since we can't retrieve status during installation we show the installed text after a fixed delay this.installedDelay = 90*1000; // Since we can't retrieve status during installation we show the installed text after a fixed delay
this.installedDelayer; // setTimout instance this.installedDelayer; // setTimout instance
this.retryDelay = 1000; this.retryDelay = 1000;
this.retryDelayer; // setTimout instance this.retryDelayer; // setTimout instance
//this.timeoutTime = 3000; //this.timeoutTime = 3000;
this.canUpdate = false; this.canUpdate = false;
this.currentVersion = ""; this.currentVersion = "";
this.newestVersion; this.newestVersion;
this.progress; this.progress;
this.imageSize; this.imageSize;
var _inAccessPointMode; var _inAccessPointMode;
// states from api, see Doodle3D firmware src/script/d3d-updater.lua // states from api, see Doodle3D firmware src/script/d3d-updater.lua
UpdatePanel.NONE = 1; // default state UpdatePanel.NONE = 1; // default state
UpdatePanel.DOWNLOADING = 2; UpdatePanel.DOWNLOADING = 2;
UpdatePanel.DOWNLOAD_FAILED = 3; UpdatePanel.DOWNLOAD_FAILED = 3;
UpdatePanel.IMAGE_READY = 4; // download successfull and checked UpdatePanel.IMAGE_READY = 4; // download successfull and checked
UpdatePanel.INSTALLING = 5; UpdatePanel.INSTALLING = 5;
UpdatePanel.INSTALLED = 6; UpdatePanel.INSTALLED = 6;
UpdatePanel.INSTALL_FAILED = 7; UpdatePanel.INSTALL_FAILED = 7;
this.state; // update state from api this.state; // update state from api
this.stateText = ""; // update state text from api this.stateText = ""; // update state text from api
var self = this; var self = this;
@ -125,7 +125,7 @@ function UpdatePanel() {
clearTimeout(self.retryDelayer); clearTimeout(self.retryDelayer);
} }
this.checkStatus = function(keepChecking) { this.checkStatus = function(keepChecking) {
if (!communicateWithWifibox) return; if (!communicateWithWifibox) return;
$.ajax({ $.ajax({
url: self.wifiboxURL + "/update/status", url: self.wifiboxURL + "/update/status",
type: "GET", type: "GET",
@ -212,7 +212,7 @@ function UpdatePanel() {
break; break;
default: default:
self.btnUpdate.attr("disabled", true); self.btnUpdate.attr("disabled", true);
break; break;
} }
} else { } else {
self.btnUpdate.attr("disabled", true); self.btnUpdate.attr("disabled", true);
@ -261,10 +261,10 @@ function UpdatePanel() {
} }
this.updateInfoDisplay = function() { this.updateInfoDisplay = function() {
var html = 'Current version: ' + self.currentVersion + var html = 'Current version: ' + self.currentVersion +
' (<a target="d3d-curr-relnotes" href="ReleaseNotes.html">release notes</a>). '; ' (<a target="d3d-curr-relnotes" href="ReleaseNotes.html">release notes</a>). ';
if(self.canUpdate) { if(self.canUpdate) {
html += 'Latest version: ' + self.newestVersion + html += 'Latest version: ' + self.newestVersion +
' (<a target="d3d-new-relnotes" href="http://doodle3d.com/updates/images/ReleaseNotes.md">release notes</a>).'; ' (<a target="d3d-new-relnotes" href="http://doodle3d.com/updates/images/ReleaseNotes.md">release notes</a>).';
} }
self.infoDisplay.html(html); self.infoDisplay.html(html);
} }

View File

@ -1,142 +1,171 @@
form { form {
margin: 10px; margin: 10px;
max-width: 600px; max-width: 600px;
} }
form input { form input {
margin: 1px; margin: 1px;
} }
body,th,td { body,th,td {
font-family: Helvetica, Arial, "Nimbus Sans L", sans-serif; font-family: Helvetica, Arial, "Nimbus Sans L", sans-serif;
font-size: 13px; font-size: 13px;
} }
.settingsContainer { .settingsContainer {
position:relative; position: relative;
/*min-width: 370px;*/ /*min-width: 370px;*/
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
/*form#settingsForm {*/ /*form#settingsForm {*/
/*width: 100% auto;*/ /*width: 100% auto;*/
/*}*/ /*}*/
form fieldset { form fieldset {
max-width: 600px; max-width: 600px;
border: 1px solid rgb(187, 187, 187); border: 1px solid rgb(187, 187, 187);
border-radius: 5px; border-radius: 5px;
-webkit-border-radius: 5px; -webkit-border-radius: 5px;
-moz-border-radius: 5px; -moz-border-radius: 5px;
margin-bottom: 20px; margin-bottom: 20px;
padding: 8px; padding: 8px;
/*padding-right: 8px;*/ /*padding-right: 8px;*/
} }
form fieldset fieldset{
form fieldset fieldset {
max-width: 580px; max-width: 580px;
margin: 15px 0 5px 0; margin: 15px 0 5px 0;
clear: left; clear: left;
float: left; float: left;
} }
form fieldset.collapsed { form fieldset.collapsed {
border-radius: 0; border-radius: 0;
-webkit-border-radius: 0; -webkit-border-radius: 0;
-moz-border-radius: 0; -moz-border-radius: 0;
border-width: 1px 0 0 0; border-width: 1px 0 0 0;
float:none; float: none;
} }
form fieldset.collapsible { form fieldset.collapsible {
padding: 0; padding: 0;
} }
form fieldset.collapsible div{
form fieldset.collapsible div {
margin: 8px; margin: 8px;
} }
form fieldset legend { form fieldset legend {
margin-left: 10px; margin-left: 10px;
font-weight: bold; font-weight: bold;
} }
form fieldset.collapsible legend { form fieldset.collapsible legend {
padding-left: 10px; padding-left: 10px;
cursor: pointer; cursor: pointer;
} }
form fieldset.expanded legend { form fieldset.expanded legend {
background: transparent url(../img/buttons/expanded.gif) no-repeat center left; background: transparent url(../img/buttons/expanded.gif) no-repeat
center left;
} }
form fieldset.collapsed legend { form fieldset.collapsed legend {
background: transparent url(../img/buttons/collapsed.gif) no-repeat center left; background: transparent url(../img/buttons/collapsed.gif) no-repeat
center left;
} }
form label { form label {
min-width: 150px; min-width: 150px;
display: block; display: block;
float: left; float: left;
margin: 1px 0 0 0; margin: 1px 0 0 0;
clear: left; clear: left;
} }
form div { form div {
float: left; float: left;
} }
form input[type="text"], form input[type="number"], form input[type="password"] {
border: 1px solid rgb(144, 192, 255); form input[type="text"],form input[type="number"], form input[type="password"]
margin-right: 5px; {
-webkit-border-radius: 4px; border: 1px solid rgb(144, 192, 255);
margin-right: 5px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px; -moz-border-radius: 4px;
border-radius: 4px; border-radius: 4px;
} }
form input[type="text"].small, form input[type="number"].small, form input[type="password"].small {
width: 50px; form input[type="text"].small,form input[type="number"].small, form input[type="password"].small
{
width: 50px;
} }
form input[type="text"].large, form input[type="number"].large, form input[type="password"].large {
width: 250px; form input[type="text"].large,form input[type="number"].large, form input[type="password"].large
{
width: 250px;
} }
form input[type="radio"] { form input[type="radio"] {
margin: 4px 4px 0 0; margin: 4px 4px 0 0;
} }
form textarea { form textarea {
border: 1px solid rgb(144, 192, 255); border: 1px solid rgb(144, 192, 255);
-webkit-border-radius: 5px; -webkit-border-radius: 5px;
-moz-border-radius: 5px; -moz-border-radius: 5px;
border-radius: 5px; border-radius: 5px;
} }
form .startgcode_left { form .startgcode_left {
float:left; float: left;
margin-right: 20px; margin-right: 20px;
} }
form textarea.gcode { form textarea.gcode {
width: 252px; width: 252px;
/*max-width: 262px;*/ /*max-width: 262px;*/
/*min-width: 200px;*/ /*min-width: 200px;*/
height: 150px; height: 150px;
} }
form small { form small {
margin: 3px 0 0 0; margin: 3px 0 0 0;
display: block; display: block;
clear: left; clear: left;
} }
form .button { form .button {
display: inline-block; display: inline-block;
} }
form #passwordLabel, form #password { form #passwordLabel,form #password {
display: none; display: none;
} }
form input.error, form textarea.error, form select.error { form input.error, form textarea.error, form select.error {
border: #f00 solid 2px; border: #f00 solid 2px;
} }
form .errorMsg { form .errorMsg {
color: #f00; color: #f00;
margin: 0 0 0 1em; margin: 0 0 0 1em;
} }
form .intro { form .intro {
margin: 0 0 0.5em 0; margin: 0 0 0.5em 0;
} }
form dl { form dl {
margin: 0.5em 0 0 0; margin: 0.5em 0 0 0;
} }
form dl dt { form dl dt {
float: left; float: left;
font-style: italic; font-style: italic;
width: 10em; width: 10em;
} }
#updatePanel #retainConfigurationLabel, #updatePanel #includeBetasLabel { #updatePanel #retainConfigurationLabel, #updatePanel #includeBetasLabel {
display: inline; display: inline;
float: none; float: none;