Styled refresh and pause/continue buttons. Fixed link behavior.
This commit is contained in:
parent
98b5208adb
commit
60e76118e3
2
Makefile
2
Makefile
@ -1,4 +1,4 @@
|
|||||||
VERSION =1.1
|
VERSION =1.2
|
||||||
BUILD_NUMBER_FILE = build-number.txt
|
BUILD_NUMBER_FILE = build-number.txt
|
||||||
BUILD_NUMBER = $$(cat $(BUILD_NUMBER_FILE))
|
BUILD_NUMBER = $$(cat $(BUILD_NUMBER_FILE))
|
||||||
|
|
||||||
|
@ -250,3 +250,23 @@ body > section {
|
|||||||
margin: 0;
|
margin: 0;
|
||||||
padding: 0 } }
|
padding: 0 } }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#main-buttons {
|
||||||
|
border-top: solid 2px $accent1;
|
||||||
|
|
||||||
|
ul {
|
||||||
|
list-style: none;
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
|
||||||
|
li {
|
||||||
|
display: inline-block;
|
||||||
|
margin: 0;
|
||||||
|
|
||||||
|
a {
|
||||||
|
border: $accent2 solid thin;
|
||||||
|
border-radius: 5px;
|
||||||
|
display: block;
|
||||||
|
cursor: pointer;
|
||||||
|
padding: 0.1rem 0.3rem; } } }
|
||||||
|
}
|
||||||
|
@ -338,7 +338,7 @@
|
|||||||
el: $("body"),
|
el: $("body"),
|
||||||
|
|
||||||
events: {
|
events: {
|
||||||
"click a.refresh" : "refresh"
|
"click a.refresh" : "refresh",
|
||||||
"click a.pause-continue" : "toggleSync" },
|
"click a.pause-continue" : "toggleSync" },
|
||||||
|
|
||||||
initialize: function() {
|
initialize: function() {
|
||||||
@ -373,7 +373,7 @@
|
|||||||
PD.refreshIntervalId = setInterval(this.refresh, PD.refreshPeriod ? PD.refreshPeriod : 15000);
|
PD.refreshIntervalId = setInterval(this.refresh, PD.refreshPeriod ? PD.refreshPeriod : 15000);
|
||||||
},
|
},
|
||||||
|
|
||||||
refresh: function() {
|
refresh: function(evt) {
|
||||||
// If the dialog is still open we skip this sync to give the user
|
// If the dialog is still open we skip this sync to give the user
|
||||||
// a chance to finish configuration.
|
// a chance to finish configuration.
|
||||||
if ($("#config-dialog").is(":visible")) { return; }
|
if ($("#config-dialog").is(":visible")) { return; }
|
||||||
@ -496,9 +496,11 @@
|
|||||||
collection.remove(model); }});
|
collection.remove(model); }});
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if (evt) evt.preventDefault();
|
||||||
},
|
},
|
||||||
|
|
||||||
toggleSync: function() {
|
toggleSync: function(evt) {
|
||||||
if (PD.refreshIntervalId == null) {
|
if (PD.refreshIntervalId == null) {
|
||||||
PD.refreshIntervalId = setInterval(this.refresh,
|
PD.refreshIntervalId = setInterval(this.refresh,
|
||||||
PD.refreshPeriod ? PD.refreshPeriod : 15000);
|
PD.refreshPeriod ? PD.refreshPeriod : 15000);
|
||||||
@ -506,7 +508,11 @@
|
|||||||
else {
|
else {
|
||||||
clearInterval(PD.refreshIntervalId);
|
clearInterval(PD.refreshIntervalId);
|
||||||
PD.refreshIntervalId = null;
|
PD.refreshIntervalId = null;
|
||||||
$('.pause-continue').text('Resume Monitoring'); } }
|
$('.pause-continue').text('Resume Monitoring'); }
|
||||||
|
|
||||||
|
|
||||||
|
if (evt) evt.preventDefault();
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
PD.main = new PD.Main();
|
PD.main = new PD.Main();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user