Merge pull request #103 from voloved/disable_slcd
Added watch_disable_display
This commit is contained in:
@@ -50,17 +50,23 @@ void watch_enable_display(void) {
|
||||
_watch_update_indicator_segments();
|
||||
#endif
|
||||
|
||||
EM_ASM({
|
||||
#if defined(FORCE_CUSTOM_LCD_TYPE)
|
||||
document.getElementById("classic").style.display = "none";
|
||||
EM_ASM({document.getElementById("custom").style.display = "";});
|
||||
EM_ASM({document.getElementById("classic").style.display = "none";});
|
||||
#else
|
||||
document.getElementById("custom").style.display = "none";
|
||||
EM_ASM({document.getElementById("custom").style.display = "none";});
|
||||
EM_ASM({document.getElementById("classic").style.display = "";});
|
||||
#endif
|
||||
});
|
||||
|
||||
watch_clear_display();
|
||||
}
|
||||
|
||||
void watch_disable_display(void) {
|
||||
watch_clear_display();
|
||||
EM_ASM({document.getElementById("classic").style.display = "none";});
|
||||
EM_ASM({document.getElementById("custom").style.display = "none";});
|
||||
}
|
||||
|
||||
void watch_set_pixel(uint8_t com, uint8_t seg) {
|
||||
EM_ASM({
|
||||
document.querySelectorAll("[data-com='" + $0 + "'][data-seg='" + $1 + "']")
|
||||
|
||||
Reference in New Issue
Block a user