Added button to allow the user to open the config dialog on command.

This commit is contained in:
Jonathan Bernard 2013-10-28 11:09:36 -05:00
parent 9bd00cdab7
commit 0a083ba8cc
4 changed files with 9 additions and 5 deletions

View File

@ -1,4 +1,4 @@
VERSION =1.3 VERSION =1.4
BUILD_NUMBER_FILE = build-number.txt BUILD_NUMBER_FILE = build-number.txt
BUILD_NUMBER = $$(cat $(BUILD_NUMBER_FILE)) BUILD_NUMBER = $$(cat $(BUILD_NUMBER_FILE))

View File

@ -1 +1 @@
0 1

View File

@ -21,7 +21,7 @@
<script src="js/personal-display.js" type="text/javascript" defer></script> <script src="js/personal-display.js" type="text/javascript" defer></script>
<meta name="viewport" content="width=device-width, user-scalable=no"> <meta name="viewport" content="width=device-width, user-scalable=no">
<meta name=version content="1.3"> <meta name=version content="1.4">
</head> </head>
<body> <body>
<section id=current-task> <section id=current-task>
@ -36,6 +36,7 @@
<ul> <ul>
<li><a href="#" class=pause-continue>Pause Monitoring</a></li> <li><a href="#" class=pause-continue>Pause Monitoring</a></li>
<li><a href="#" class=refresh>Refresh Now</a></li> <li><a href="#" class=refresh>Refresh Now</a></li>
<li><a href="#" class=show-config>Config</a></li>
</ul> </ul>
</section> </section>
<section id=config-dialog> <section id=config-dialog>

View File

@ -2,7 +2,7 @@
var root = this; var root = this;
var PD = root.PersonalDisplay = {}; var PD = root.PersonalDisplay = {};
PD.version = "1.3" PD.version = "1.4"
PD.hasHTML5LocalStorage = function() { PD.hasHTML5LocalStorage = function() {
try { try {
@ -340,7 +340,8 @@
events: { events: {
"click a.refresh" : "refresh", "click a.refresh" : "refresh",
"click a.pause-continue" : "toggleSync" }, "click a.pause-continue" : "toggleSync",
"click a.show-config" : "showConfig" },
initialize: function() { initialize: function() {
@ -501,6 +502,8 @@
if (evt) evt.preventDefault(); if (evt) evt.preventDefault();
}, },
showConfig: function() { PD.configDialog.show(); },
toggleSync: function(evt) { toggleSync: function(evt) {
if (PD.refreshIntervalId == null) { if (PD.refreshIntervalId == null) {
PD.refreshIntervalId = setInterval(this.refresh, PD.refreshIntervalId = setInterval(this.refresh,