1
0
Fork 0

vpw_clock - Restore whole theme

master
Martin Boonk 2024-03-29 19:09:44 +01:00
parent eeb3392538
commit 9f6d1737c9
3 changed files with 6 additions and 4 deletions

View File

@ -2,3 +2,4 @@
0.02: Now using a bigger font for day of week and date for better visibility 0.02: Now using a bigger font for day of week and date for better visibility
0.03: Set theme to light, add black as an option for foreground color 0.03: Set theme to light, add black as an option for foreground color
0.04: Handle fast loading 0.04: Handle fast loading
0.05: Fix theme reset for some themes

View File

@ -150,7 +150,7 @@ Graphics.prototype.setFontMadeSunflower = function () {
}; };
// store the theme before drawing // store the theme before drawing
let orignalTheme = g.theme; let originalTheme = g.theme;
// Clear the screen once, at startup // Clear the screen once, at startup
g.setTheme({ bg: COLOUR_VPW_GREEN, fg: foregroundColor, dark: false }).clear(); g.setTheme({ bg: COLOUR_VPW_GREEN, fg: foregroundColor, dark: false }).clear();
@ -167,8 +167,9 @@ Graphics.prototype.setFontMadeSunflower = function () {
if (drawTimeout) clearTimeout(drawTimeout); if (drawTimeout) clearTimeout(drawTimeout);
// remove custom font // remove custom font
delete Graphics.prototype.setFontMadeSunflower; delete Graphics.prototype.setFontMadeSunflower;
delete Graphics.prototype.setFontVGA8;
// revert theme to how it was before // revert theme to how it was before
g.setTheme({ bg: orignalTheme.bg, fg: orignalTheme.fb, dark: orignalTheme.dark }); g.setTheme(originalTheme);
} }
}); });

View File

@ -3,7 +3,7 @@
"name": "Vaporwave Sunset Clock", "name": "Vaporwave Sunset Clock",
"shortName": "Vaporwave Sunset", "shortName": "Vaporwave Sunset",
"type": "clock", "type": "clock",
"version":"0.04", "version":"0.05",
"description": "A clock with a vaporwave sunset theme.", "description": "A clock with a vaporwave sunset theme.",
"tags": "clock", "tags": "clock",
"supports": ["BANGLEJS2"], "supports": ["BANGLEJS2"],