skin touchregions: fix the 'none' region firing when it shouldnt.

Change the none action return value so the various action layers don't get confused by ACTION_TOUCHSCREEN return codes which shouldn't be happening (i.e when a long press region overlaps a short press region whihc has the none action)

Change-Id: I63db2c0b49597ada2c5ebd0ef98e99aeef4f522a
This commit is contained in:
Jonathan Gordon 2012-01-19 19:35:19 +11:00
parent 7efbd632c2
commit 8a3af26364
2 changed files with 3 additions and 2 deletions

View file

@ -92,7 +92,8 @@ enum {
ACTION_REDRAW, /* returned if keys are locked and we splash()'ed */ ACTION_REDRAW, /* returned if keys are locked and we splash()'ed */
ACTION_TOUCHSCREEN, ACTION_TOUCHSCREEN,
ACTION_TOUCHSCREEN_MODE, /* toggle the touchscreen mode */ ACTION_TOUCHSCREEN_MODE, /* toggle the touchscreen mode */
ACTION_TOUCHSCREEN_IGNORE, /* used for the 'none' action in skins */
/* standard actions, use these first */ /* standard actions, use these first */
ACTION_STD_PREV, ACTION_STD_PREV,
ACTION_STD_PREVREPEAT, ACTION_STD_PREVREPEAT,

View file

@ -1242,7 +1242,7 @@ static int parse_lasttouch(struct skin_element *element,
struct touchaction {const char* s; int action;}; struct touchaction {const char* s; int action;};
static const struct touchaction touchactions[] = { static const struct touchaction touchactions[] = {
/* generic actions, convert to screen actions on use */ /* generic actions, convert to screen actions on use */
{"none", ACTION_TOUCHSCREEN}, {"lock", ACTION_TOUCH_SOFTLOCK }, {"none", ACTION_TOUCHSCREEN_IGNORE},{"lock", ACTION_TOUCH_SOFTLOCK },
{"prev", ACTION_STD_PREV }, {"next", ACTION_STD_NEXT }, {"prev", ACTION_STD_PREV }, {"next", ACTION_STD_NEXT },
{"rwd", ACTION_STD_PREVREPEAT }, {"ffwd", ACTION_STD_NEXTREPEAT }, {"rwd", ACTION_STD_PREVREPEAT }, {"ffwd", ACTION_STD_NEXTREPEAT },
{"hotkey", ACTION_STD_HOTKEY}, {"select", ACTION_STD_OK }, {"hotkey", ACTION_STD_HOTKEY}, {"select", ACTION_STD_OK },