layoutswitch robustisiert
This commit is contained in:
parent
54de8cc4be
commit
e398011737
2 changed files with 4 additions and 3 deletions
|
@ -47,9 +47,7 @@
|
||||||
$('#layoutswitcher').on('change', function() {
|
$('#layoutswitcher').on('change', function() {
|
||||||
switchLayout(this.value);
|
switchLayout(this.value);
|
||||||
});
|
});
|
||||||
currentLayout = layout['de_CH'];
|
switchLayout('de_CH');
|
||||||
renderLayout();
|
|
||||||
startClock();
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
|
|
3
uhr.js
3
uhr.js
|
@ -97,6 +97,9 @@ function switchTheme(theme) {
|
||||||
function switchLayout(locale) {
|
function switchLayout(locale) {
|
||||||
stopClock();
|
stopClock();
|
||||||
currentLayout = layout[locale];
|
currentLayout = layout[locale];
|
||||||
|
if (currentLayout == undefined) {
|
||||||
|
currentLayout = layout['default'];
|
||||||
|
}
|
||||||
renderLayout();
|
renderLayout();
|
||||||
if (isOn()) {
|
if (isOn()) {
|
||||||
startClock();
|
startClock();
|
||||||
|
|
Loading…
Reference in a new issue