From 84fe501f53f966894b226172faa50b9fd0d651f5 Mon Sep 17 00:00:00 2001 From: William Wilgus Date: Mon, 2 Jan 2023 13:03:48 -0500 Subject: Add locked actions to all soft lock targets fiio m3k native is currently the only player with defined buttons different from the standard mapping. This allows the user to use the keyremap plugin to specify differing keymaps for their device in the locked state Change-Id: Ie0b447bba0d5978e8d23fed423df30c794afc6f9 --- apps/plugins/keyremap.c | 4 ++-- apps/plugins/pictureflow/pictureflow.c | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) (limited to 'apps/plugins') diff --git a/apps/plugins/keyremap.c b/apps/plugins/keyremap.c index cb19fcf92c..f0b36a735e 100644 --- a/apps/plugins/keyremap.c +++ b/apps/plugins/keyremap.c @@ -53,13 +53,13 @@ struct context_flags { /* flags added to context_name[] */ static struct context_flags context_flags[] = { {"UNKNOWN", 0},/* index 0 is an Error */ -#ifdef HAVE_LOCKED_ACTIONS +#ifndef HAS_BUTTON_HOLD {"LOCKED", CONTEXT_LOCKED}, #endif /*{"PLUGIN", CONTEXT_PLUGIN}, need a custom action list and a way to supply */ #if BUTTON_REMOTE != 0 {"REMOTE", CONTEXT_REMOTE}, -#ifdef HAVE_LOCKED_ACTIONS +#ifndef HAS_BUTTON_HOLD {"REMOTE_LOCKED", CONTEXT_REMOTE | CONTEXT_LOCKED}, #endif #endif /* BUTTON_REMOTE != 0 */ diff --git a/apps/plugins/pictureflow/pictureflow.c b/apps/plugins/pictureflow/pictureflow.c index a7a0031391..54497d8306 100644 --- a/apps/plugins/pictureflow/pictureflow.c +++ b/apps/plugins/pictureflow/pictureflow.c @@ -967,9 +967,7 @@ const struct custom_format format_transposed = { static const struct button_mapping* get_context_map(int context) { -#ifdef HAVE_LOCKED_ACTIONS context &= ~CONTEXT_LOCKED; -#endif return pf_contexts[context & ~CONTEXT_PLUGIN]; } -- cgit v1.2.3