diff options
| author | Thomas Martitz <kugel@rockbox.org> | 2010-05-20 17:41:28 +0000 |
|---|---|---|
| committer | Thomas Martitz <kugel@rockbox.org> | 2010-05-20 17:41:28 +0000 |
| commit | 20e9d56ba5507021bdde898f4b0a0eb14f2af861 (patch) | |
| tree | 20a1ff36d0cc0f530bc7c7648b1bca2f9127a5c8 /apps/plugins/lib/pluginlib_actions.h | |
| parent | 97365803d390e44155fc41657bd03a7b121956aa (diff) | |
| download | rockbox-20e9d56ba5507021bdde898f4b0a0eb14f2af861.zip rockbox-20e9d56ba5507021bdde898f4b0a0eb14f2af861.tar.gz rockbox-20e9d56ba5507021bdde898f4b0a0eb14f2af861.tar.bz2 rockbox-20e9d56ba5507021bdde898f4b0a0eb14f2af861.tar.xz | |
S#10387 - Rework pluginlib actions
It changes pluginlib actions to contain only a single and simple context (and
other one for remote directional buttons),
consisting of 7(9) buttons: up/down/left/right, select OR short select and long
select, exit and cancel (plus 2 for scrollwheel targets).
This ensures contexts don't clash with other contexts and simplifies them, at
the expense of reduced versatility. However, the versatility made it largely unusable
due to the great number of targets.
This should allow for using pluginlib actions safely for the most simple plugins (e.g. almost all demos).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26202 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/lib/pluginlib_actions.h')
| -rw-r--r-- | apps/plugins/lib/pluginlib_actions.h | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/apps/plugins/lib/pluginlib_actions.h b/apps/plugins/lib/pluginlib_actions.h index cc5f8b4..51a0f4a 100644 --- a/apps/plugins/lib/pluginlib_actions.h +++ b/apps/plugins/lib/pluginlib_actions.h @@ -38,27 +38,26 @@ enum { PLA_LEFT_REPEAT, PLA_RIGHT_REPEAT, - PLA_INC, - PLA_DEC, - PLA_INC_REPEAT, - PLA_DEC_REPEAT, + PLA_CANCEL, + PLA_EXIT, + PLA_SELECT, + PLA_SELECT_REL, + PLA_SELECT_REPEAT, - PLA_QUIT, - PLA_START, - PLA_MENU, - PLA_FIRE, - PLA_FIRE_REPEAT, +#ifdef HAVE_SCROLLWHEEL + PLA_SCROLL_FWD, + PLA_SCROLL_FWD_REPEAT, + PLA_SCROLL_BACK, + PLA_SCROLL_BACK_REPEAT, +#endif LAST_PLUGINLIB_ACTION }; #if defined(HAVE_REMOTE_LCD) -extern const struct button_mapping remote_directions[]; +extern const struct button_mapping pla_remote_ctx[]; #endif -extern const struct button_mapping generic_directions[]; -extern const struct button_mapping generic_left_right_fire[]; -extern const struct button_mapping generic_actions[]; -extern const struct button_mapping generic_increase_decrease[]; +extern const struct button_mapping pla_main_ctx[]; int pluginlib_getaction(int timeout, const struct button_mapping *plugin_contexts[], |