summaryrefslogtreecommitdiffstats
path: root/apps/plugins/sudoku/sudoku.h
diff options
context:
space:
mode:
Diffstat (limited to 'apps/plugins/sudoku/sudoku.h')
-rw-r--r--apps/plugins/sudoku/sudoku.h37
1 files changed, 11 insertions, 26 deletions
diff --git a/apps/plugins/sudoku/sudoku.h b/apps/plugins/sudoku/sudoku.h
index 749087260d..36f47a377a 100644
--- a/apps/plugins/sudoku/sudoku.h
+++ b/apps/plugins/sudoku/sudoku.h
@@ -404,21 +404,7 @@
#define SUDOKU_BUTTON_MENU (BUTTON_POWER | BUTTON_REL)
#define SUDOKU_BUTTON_POSSIBLE (BUTTON_HOME | BUTTON_PWRALT)
-#elif CONFIG_KEYPAD == XDUOO_X3II_PAD
-#define SUDOKU_BUTTON_QUIT_PRE BUTTON_POWER
-#define SUDOKU_BUTTON_QUIT (BUTTON_POWER | BUTTON_REPEAT)
-#define SUDOKU_BUTTON_UP BUTTON_HOME
-#define SUDOKU_BUTTON_DOWN BUTTON_OPTION
-#define SUDOKU_BUTTON_LEFT BUTTON_PREV
-#define SUDOKU_BUTTON_RIGHT BUTTON_NEXT
-#define SUDOKU_BUTTON_TOGGLEBACK BUTTON_VOL_DOWN
-#define SUDOKU_BUTTON_TOGGLE BUTTON_VOL_UP
-#define SUDOKU_BUTTON_ALTTOGGLE BUTTON_PLAY
-#define SUDOKU_BUTTON_MENU_PRE BUTTON_POWER
-#define SUDOKU_BUTTON_MENU (BUTTON_POWER | BUTTON_REL)
-#define SUDOKU_BUTTON_POSSIBLE (BUTTON_HOME | BUTTON_POWER)
-
-#elif CONFIG_KEYPAD == XDUOO_X20_PAD
+#elif CONFIG_KEYPAD == XDUOO_X3II_PAD || CONFIG_KEYPAD == XDUOO_X20_PAD
#define SUDOKU_BUTTON_QUIT_PRE BUTTON_POWER
#define SUDOKU_BUTTON_QUIT (BUTTON_POWER | BUTTON_REPEAT)
#define SUDOKU_BUTTON_UP BUTTON_HOME
@@ -446,7 +432,7 @@
#define SUDOKU_BUTTON_MENU (BUTTON_POWER | BUTTON_REL)
#define SUDOKU_BUTTON_POSSIBLE (BUTTON_HOME | BUTTON_POWER)
-#elif CONFIG_KEYPAD == IHIFI_770_PAD
+#elif CONFIG_KEYPAD == IHIFI_770_PAD || CONFIG_KEYPAD == IHIFI_800_PAD
#define SUDOKU_BUTTON_QUIT_PRE BUTTON_POWER
#define SUDOKU_BUTTON_QUIT (BUTTON_POWER | BUTTON_REPEAT)
#define SUDOKU_BUTTON_UP BUTTON_PREV
@@ -460,19 +446,18 @@
#define SUDOKU_BUTTON_MENU (BUTTON_POWER | BUTTON_REL)
#define SUDOKU_BUTTON_POSSIBLE (BUTTON_POWER | BUTTON_HOME)
-#elif CONFIG_KEYPAD == IHIFI_800_PAD
+#elif CONFIG_KEYPAD == EROSQ_PAD
#define SUDOKU_BUTTON_QUIT_PRE BUTTON_POWER
#define SUDOKU_BUTTON_QUIT (BUTTON_POWER | BUTTON_REPEAT)
#define SUDOKU_BUTTON_UP BUTTON_PREV
#define SUDOKU_BUTTON_DOWN BUTTON_NEXT
-#define SUDOKU_BUTTON_LEFT BUTTON_HOME
-#define SUDOKU_BUTTON_RIGHT BUTTON_VOL_DOWN
-#define SUDOKU_BUTTON_TOGGLEBACK (BUTTON_POWER | BUTTON_VOL_DOWN)
-#define SUDOKU_BUTTON_TOGGLE (BUTTON_POWER | BUTTON_VOL_UP)
-#define SUDOKU_BUTTON_ALTTOGGLE BUTTON_PLAY
-#define SUDOKU_BUTTON_MENU_PRE BUTTON_POWER
-#define SUDOKU_BUTTON_MENU (BUTTON_POWER | BUTTON_REL)
-#define SUDOKU_BUTTON_POSSIBLE (BUTTON_POWER | BUTTON_HOME)
+#define SUDOKU_BUTTON_LEFT BUTTON_SCROLL_BACK
+#define SUDOKU_BUTTON_RIGHT BUTTON_SCROLL_FWD
+#define SUDOKU_BUTTON_TOGGLEBACK BUTTON_VOL_DOWN
+#define SUDOKU_BUTTON_TOGGLE BUTTON_VOL_UP
+#define SUDOKU_BUTTON_MENU_PRE BUTTON_MENU
+#define SUDOKU_BUTTON_MENU (BUTTON_MENU | BUTTON_REL)
+#define SUDOKU_BUTTON_POSSIBLE BUTTON_BACK
#else
#error No keymap defined!
@@ -512,7 +497,7 @@ struct sudoku_state_t {
char savedboard[9][9]; /* Cached copy of saved state */
int x,y; /* Cursor position */
int editmode; /* We are editing the start board */
-#ifdef SUDOKU_BUTTON_POSSIBLE
+#ifdef SUDOKU_BUTTON_POSSIBLE
short possiblevals[9][9]; /* possible values a cell could be, user sets them */
short savedpossible[9][9]; /* cached copy of possible cell values */
#endif