mirror of
https://github.com/Rockbox/rockbox.git
synced 2026-05-12 11:43:16 -04:00
gui: fix "lock screens" making UI viewport disappear
Themes like Adwaitapod, Themify, or FreshOS have custom "lock screens" that are drawn on top of the UI viewport. Request a full skin update when unlocked, so you don't have to press a button to make the hidden UI viewport appear again. Change-Id: Idf5023b4e12f7aea1cd7a2e9d9ab2f754387dc48
This commit is contained in:
parent
83e55164f4
commit
88d4903d10
4 changed files with 8 additions and 4 deletions
|
|
@ -939,7 +939,7 @@ static inline void do_softlock(action_last_t *last, action_cur_t *cur)
|
||||||
if (notify_user)
|
if (notify_user)
|
||||||
{
|
{
|
||||||
#ifndef BOOTLOADER
|
#ifndef BOOTLOADER
|
||||||
skin_request_update_locked();
|
skin_request_update_locked(last->keys_locked);
|
||||||
#endif
|
#endif
|
||||||
action_handle_backlight(true, false);
|
action_handle_backlight(true, false);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -344,12 +344,16 @@ void skin_request_full_update(enum skinnable_screens skin)
|
||||||
|
|
||||||
|
|
||||||
/* Request skin update for lock state change */
|
/* Request skin update for lock state change */
|
||||||
void skin_request_update_locked(void)
|
void skin_request_update_locked(bool locked)
|
||||||
{
|
{
|
||||||
if (get_current_activity() == ACTIVITY_WPS)
|
if (get_current_activity() == ACTIVITY_WPS)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
sb_skin_force_next_update();
|
sb_skin_force_next_update();
|
||||||
|
|
||||||
|
/* fix themes that draw on top of the UI viewport when locked */
|
||||||
|
if (!locked)
|
||||||
|
skin_request_full_update(CUSTOM_STATUSBAR);
|
||||||
#ifdef HAS_BUTTON_HOLD
|
#ifdef HAS_BUTTON_HOLD
|
||||||
button_queue_post(BUTTON_NONE, 0);
|
button_queue_post(BUTTON_NONE, 0);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -82,7 +82,7 @@ void skin_unload_all(void);
|
||||||
|
|
||||||
bool skin_do_full_update(enum skinnable_screens skin, enum screen_type screen);
|
bool skin_do_full_update(enum skinnable_screens skin, enum screen_type screen);
|
||||||
void skin_request_full_update(enum skinnable_screens skin);
|
void skin_request_full_update(enum skinnable_screens skin);
|
||||||
void skin_request_update_locked(void);
|
void skin_request_update_locked(bool locked);
|
||||||
|
|
||||||
bool dbg_skin_engine(void);
|
bool dbg_skin_engine(void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -889,7 +889,7 @@ void backlight_set_timeout_plugged(int value)
|
||||||
void backlight_hold_changed(bool hold_button)
|
void backlight_hold_changed(bool hold_button)
|
||||||
{
|
{
|
||||||
#ifndef BOOTLOADER
|
#ifndef BOOTLOADER
|
||||||
skin_request_update_locked();
|
skin_request_update_locked(hold_button);
|
||||||
#endif
|
#endif
|
||||||
if (!hold_button || (backlight_on_button_hold > 0))
|
if (!hold_button || (backlight_on_button_hold > 0))
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue