mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-10-13 18:17:39 -04:00
FS#13297: M3K Autolock allows one action before disabling touchpad
Intercept buttonpress and action, and nullify both if the button
is part of the touchpad. Only affects autolock functionality.
Adding removal of note about autolock in the manual - the lock
button no longer needs to be pressed at least once to prime
the autolock, if enabled, since commit 14f7a95
Change-Id: Ic3582764df490d96abc2d78116f23cbe0fdd6173
This commit is contained in:
parent
f3f9d1fb95
commit
c067b344e8
2 changed files with 14 additions and 2 deletions
|
@ -683,6 +683,20 @@ static inline int do_auto_softlock(action_last_t *last, action_cur_t *cur)
|
|||
if (is_timeout)
|
||||
{
|
||||
do_key_lock(true);
|
||||
|
||||
#if defined(HAVE_TOUCHPAD)
|
||||
/* if the touchpad is supposed to be off and the current buttonpress
|
||||
* is from the touchpad, nullify both button and action. */
|
||||
if (!has_flag(action_last.softlock_mask, SEL_ACTION_ENABLED) ||
|
||||
has_flag(action_last.softlock_mask, SEL_ACTION_NOTOUCH))
|
||||
{
|
||||
cur->button = touchpad_filter(cur->button);
|
||||
if (cur->button == BUTTON_NONE)
|
||||
{
|
||||
action = ACTION_NONE;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
else if (action == ACTION_STD_KEYLOCK)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue