weatherclock v0.06
parent
b7222c485b
commit
7809129ddf
|
|
@ -3,4 +3,4 @@
|
|||
0.03: Minor layout extra spaces.
|
||||
0.04: Layout now compatible with Bangle.js 2.
|
||||
0.05: Use weather condition code for icon selection.
|
||||
0.06: Dev9-New settings to hide the weather icon, day of week, date and/or wind speed.
|
||||
0.06: Dev9-New settings to optionally hide elements. Images placed into functions for performance.
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
# Weather Clock
|
||||
|
||||
A clock which displays the current weather conditions. Temperature, wind speed, and an icon indicating the weather conditions are displayed.
|
||||
A clock which displays the current weather conditions. Time, day of week, date, temperature, wind speed, and an icon indicating the weather conditions are displayed.
|
||||
|
||||
As of Weather Clock v0.06 the day of week, date, temperature and/or wind speed can be hidden using settings.
|
||||
|
||||
Standard widgets are displayed.
|
||||
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ function draw() {
|
|||
}
|
||||
|
||||
function loadSettings() {
|
||||
settings = require("Storage").readJSON(SETTINGS_FILE,1)||{};
|
||||
settings = storage.readJSON(SETTINGS_FILE,1)||{};
|
||||
settings.icon = (settings.icon === undefined ? true : settings.icon);
|
||||
settings.day = (settings.day === undefined ? true : settings.day);
|
||||
settings.date = (settings.date === undefined ? true : settings.date);
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
(function(back) {
|
||||
const SETTINGS_FILE = "weatherClock.json";
|
||||
|
||||
// Load setings file
|
||||
const storage = require('Storage')
|
||||
let settings = storage.readJSON(SETTINGS_FILE, 1) || {}
|
||||
let s;
|
||||
// Load settings file
|
||||
const storage = require('Storage');
|
||||
let settings = storage.readJSON(SETTINGS_FILE, 1) || {};
|
||||
let s = {};
|
||||
s.icon = (settings.icon === undefined ? true : settings.icon);
|
||||
s.day = (settings.day === undefined ? true : settings.day);
|
||||
s.date = (settings.date === undefined ? true : settings.date);
|
||||
|
|
@ -46,5 +46,5 @@
|
|||
save();
|
||||
},
|
||||
}
|
||||
})
|
||||
})
|
||||
});
|
||||
});
|
||||
|
|
|
|||
Loading…
Reference in New Issue