diff options
author | Jonathan Gordon <rockbox@jdgordon.info> | 2010-09-06 13:33:49 +0000 |
---|---|---|
committer | Jonathan Gordon <rockbox@jdgordon.info> | 2010-09-06 13:33:49 +0000 |
commit | 4caa8326abd590eb01279dde3f4dc6611a9255c8 (patch) | |
tree | c7f0f858ecda565e688b945ab89cd000d8c4fe2c /apps/gui/statusbar-skinned.c | |
parent | 1a92ff099499a657c55e1282dab00276100f99f7 (diff) | |
download | rockbox-4caa8326abd590eb01279dde3f4dc6611a9255c8.tar.gz rockbox-4caa8326abd590eb01279dde3f4dc6611a9255c8.tar.bz2 rockbox-4caa8326abd590eb01279dde3f4dc6611a9255c8.zip |
2 new touch region options... "settings_inc" and "settings_dec" which will increase or decrease most of the available settings. To use it put the config name of the setting as the next param after settings_inc... i.e %T(0, 0, 32, 32, settings_inc, repeat)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28009 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/gui/statusbar-skinned.c')
-rw-r--r-- | apps/gui/statusbar-skinned.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/apps/gui/statusbar-skinned.c b/apps/gui/statusbar-skinned.c index 8928378781..e22ab28f13 100644 --- a/apps/gui/statusbar-skinned.c +++ b/apps/gui/statusbar-skinned.c @@ -38,6 +38,7 @@ #include "debug.h" #include "font.h" #include "icon.h" +#include "option_select.h" /* currently only one wps_state is needed */ @@ -359,6 +360,7 @@ void sb_bypass_touchregions(bool enable) int sb_touch_to_button(int context) { + struct touchregion *region; static int last_context = -1; int button, offset; if (bypass_sb_touchregions) @@ -367,7 +369,7 @@ int sb_touch_to_button(int context) if (last_context != context) skin_disarm_touchregions(&sb_skin_data[SCREEN_MAIN]); last_context = context; - button = skin_get_touchaction(&sb_skin_data[SCREEN_MAIN], &offset); + button = skin_get_touchaction(&sb_skin_data[SCREEN_MAIN], &offset, ®ion); switch (button) { @@ -377,6 +379,13 @@ int sb_touch_to_button(int context) case ACTION_WPS_VOLDOWN: return ACTION_LIST_VOLDOWN; #endif + case ACTION_SETTINGS_INC: + case ACTION_SETTINGS_DEC: + { + const struct settings_list *setting = region->extradata; + option_select_next_val(setting, button == ACTION_SETTINGS_DEC, true); + } + return ACTION_REDRAW; /* TODO */ } return button; |