From 148e0ab4162c7a441fbd99b9524c2a2542be8103 Mon Sep 17 00:00:00 2001 From: Sebastian Leonhardt Date: Sat, 24 May 2014 23:37:57 +0200 Subject: YH820: game fix and improvements * sudoku: make colour icons (without screen was squeezed) * jewels: add colour bitmaps * pegbox: make game fit on screen (add small header bitmap), improve keymap I left the original pegbox keymaps for samsung's YH-92x, because they seem to make some sense there (YH92x has a REC switch instead of pushbutton). Someone with a YH9xx target has to check what is better... Change-Id: Id388c9d69e4a5a1d8ad4c3d7a05cdfc1dff0d06c Reviewed-on: http://gerrit.rockbox.org/816 Reviewed-by: Szymon Dziok Tested: Szymon Dziok --- apps/plugins/bitmaps/native/SOURCES | 16 +++++++++++--- apps/plugins/bitmaps/native/jewels.128x96x16.bmp | Bin 0 -> 9990 bytes .../bitmaps/native/pegbox_header.128x16x16.bmp | Bin 0 -> 3126 bytes .../bitmaps/native/sudoku_inverse.128x96x16.bmp | Bin 0 -> 1198 bytes .../bitmaps/native/sudoku_normal.128x96x16.bmp | Bin 0 -> 1198 bytes .../bitmaps/native/sudoku_start.128x96x16.bmp | Bin 0 -> 1198 bytes apps/plugins/pegbox.c | 24 ++++++++++++++++++--- apps/plugins/sudoku/sudoku.c | 2 +- 8 files changed, 35 insertions(+), 7 deletions(-) create mode 100644 apps/plugins/bitmaps/native/jewels.128x96x16.bmp create mode 100644 apps/plugins/bitmaps/native/pegbox_header.128x16x16.bmp create mode 100644 apps/plugins/bitmaps/native/sudoku_inverse.128x96x16.bmp create mode 100644 apps/plugins/bitmaps/native/sudoku_normal.128x96x16.bmp create mode 100644 apps/plugins/bitmaps/native/sudoku_start.128x96x16.bmp diff --git a/apps/plugins/bitmaps/native/SOURCES b/apps/plugins/bitmaps/native/SOURCES index c91d694aea..6197f168e7 100644 --- a/apps/plugins/bitmaps/native/SOURCES +++ b/apps/plugins/bitmaps/native/SOURCES @@ -411,8 +411,10 @@ jewels.128x128x16.bmp #elif ((LCD_WIDTH == 132) && (LCD_HEIGHT == 80)) || \ ((LCD_WIDTH == 96) && (LCD_HEIGHT == 96)) jewels.132x80x16.bmp -#elif (LCD_WIDTH == 128) && (LCD_HEIGHT == 96) +#elif (LCD_WIDTH == 128) && (LCD_HEIGHT == 96) && !defined(HAVE_LCD_COLOR) jewels.128x96x2.bmp +#elif (LCD_WIDTH == 128) && (LCD_HEIGHT == 96) && defined(HAVE_LCD_COLOR) +jewels.128x96x16.bmp #elif (LCD_WIDTH == 138) && (LCD_HEIGHT == 110) jewels.138x110x2.bmp #elif (LCD_WIDTH == 160) && (LCD_HEIGHT == 128) && !defined(HAVE_LCD_COLOR) @@ -451,7 +453,7 @@ minesweeper_tiles.8x8x1.bmp /* PegBox */ #ifdef HAVE_LCD_COLOR -/* currently only LCD_WIDTH is important, e.g. Nano and e200 use the same set */ +/* for most targets only LCD_WIDTH is important, e.g. Nano and e200 use the same set */ #if LCD_WIDTH >= 640 pegbox_pieces.48x48x16.bmp pegbox_header.640x80x16.bmp @@ -475,7 +477,11 @@ pegbox_pieces.9x9x16.bmp pegbox_header.22x80x16.bmp #elif LCD_WIDTH >= 128 pegbox_pieces.10x10x16.bmp +# if LCD_HEIGHT > 96 pegbox_header.128x42x16.bmp +# else +pegbox_header.128x16x16.bmp +# endif #elif LCD_WIDTH >= 96 pegbox_pieces.8x8x16.bmp pegbox_header.96x32x16.bmp @@ -745,10 +751,14 @@ star_tiles.6x7x1.bmp sudoku_start.112x64x1.bmp sudoku_normal.112x64x1.bmp sudoku_inverse.112x64x1.bmp -#elif (LCD_WIDTH == 128) && (LCD_HEIGHT == 96) && (LCD_DEPTH >= 2) +#elif (LCD_WIDTH == 128) && (LCD_HEIGHT == 96) && (LCD_DEPTH == 2) sudoku_start.128x96x2.bmp sudoku_normal.128x96x2.bmp sudoku_inverse.128x96x2.bmp +#elif (LCD_WIDTH == 128) && (LCD_HEIGHT == 96) && (LCD_DEPTH == 16) +sudoku_start.128x96x16.bmp +sudoku_normal.128x96x16.bmp +sudoku_inverse.128x96x16.bmp #elif (LCD_WIDTH == 128) && (LCD_HEIGHT == 128) && (LCD_DEPTH == 2) sudoku_start.128x128x2.bmp sudoku_normal.128x128x2.bmp diff --git a/apps/plugins/bitmaps/native/jewels.128x96x16.bmp b/apps/plugins/bitmaps/native/jewels.128x96x16.bmp new file mode 100644 index 0000000000..6d8447740f Binary files /dev/null and b/apps/plugins/bitmaps/native/jewels.128x96x16.bmp differ diff --git a/apps/plugins/bitmaps/native/pegbox_header.128x16x16.bmp b/apps/plugins/bitmaps/native/pegbox_header.128x16x16.bmp new file mode 100644 index 0000000000..7090b80f2e Binary files /dev/null and b/apps/plugins/bitmaps/native/pegbox_header.128x16x16.bmp differ diff --git a/apps/plugins/bitmaps/native/sudoku_inverse.128x96x16.bmp b/apps/plugins/bitmaps/native/sudoku_inverse.128x96x16.bmp new file mode 100644 index 0000000000..fc0333b7dd Binary files /dev/null and b/apps/plugins/bitmaps/native/sudoku_inverse.128x96x16.bmp differ diff --git a/apps/plugins/bitmaps/native/sudoku_normal.128x96x16.bmp b/apps/plugins/bitmaps/native/sudoku_normal.128x96x16.bmp new file mode 100644 index 0000000000..57915dd410 Binary files /dev/null and b/apps/plugins/bitmaps/native/sudoku_normal.128x96x16.bmp differ diff --git a/apps/plugins/bitmaps/native/sudoku_start.128x96x16.bmp b/apps/plugins/bitmaps/native/sudoku_start.128x96x16.bmp new file mode 100644 index 0000000000..0ff341c828 Binary files /dev/null and b/apps/plugins/bitmaps/native/sudoku_start.128x96x16.bmp differ diff --git a/apps/plugins/pegbox.c b/apps/plugins/pegbox.c index 19f3d529e6..f53c8f9519 100644 --- a/apps/plugins/pegbox.c +++ b/apps/plugins/pegbox.c @@ -414,8 +414,26 @@ CONFIG_KEYPAD == MROBE500_PAD #define QUIT_TEXT "POWER" -#elif (CONFIG_KEYPAD == SAMSUNG_YH820_PAD) || \ - (CONFIG_KEYPAD == SAMSUNG_YH920_PAD) +#elif CONFIG_KEYPAD == SAMSUNG_YH820_PAD +#define PEGBOX_SAVE BUTTON_FFWD +#define PEGBOX_QUIT BUTTON_REC +#define PEGBOX_RESTART BUTTON_REW +#define PEGBOX_LVL_UP (BUTTON_PLAY|BUTTON_FFWD) +#define PEGBOX_LVL_DOWN (BUTTON_PLAY|BUTTON_REW) +#define PEGBOX_UP BUTTON_UP +#define PEGBOX_DOWN BUTTON_DOWN +#define PEGBOX_RIGHT BUTTON_RIGHT +#define PEGBOX_LEFT BUTTON_LEFT +#define PEGBOX_SELECT BUTTON_PLAY + +#define SAVE_TEXT "FFWD" +#define QUIT_TEXT "REC" +#define RESTART_TEXT "REW" +#define LVL_UP_TEXT "PLAY+FFWD" +#define LVL_DOWN_TEXT "PLAY+REW" +#define SELECT_TEXT "PLAY" + +#elif CONFIG_KEYPAD == SAMSUNG_YH920_PAD #define PEGBOX_SAVE (BUTTON_REC|BUTTON_FFWD) #define PEGBOX_QUIT (BUTTON_REC|BUTTON_PLAY) #define PEGBOX_RESTART (BUTTON_REC|BUTTON_REW) @@ -425,7 +443,7 @@ CONFIG_KEYPAD == MROBE500_PAD #define PEGBOX_DOWN BUTTON_DOWN #define PEGBOX_RIGHT BUTTON_RIGHT #define PEGBOX_LEFT BUTTON_LEFT -#define PEGBOX_SELECT BUTTON_PLAY +#define PEGBOX_SELECT BUTTON_PLAY #define SAVE_TEXT "REC + FFWD" #define QUIT_TEXT "REC + PLAY" diff --git a/apps/plugins/sudoku/sudoku.c b/apps/plugins/sudoku/sudoku.c index d19b556352..12880bd97b 100644 --- a/apps/plugins/sudoku/sudoku.c +++ b/apps/plugins/sudoku/sudoku.c @@ -114,7 +114,7 @@ static const char default_game[9][9] = #define MARK_SIZE 1 /* Mark width and height */ #elif ((LCD_HEIGHT==96) && (LCD_WIDTH==128)) -/* iAudio M3, 9 cells @ 9x9 with 14 border lines */ +/* iAudio M3, Samsung YH820, 9 cells @ 9x9 with 14 border lines */ #define MARK_OFFS 1 /* Pixels between border and mark */ #define MARK_SPACE 2 /* Pixels between two marks */ #define MARK_SIZE 1 /* Mark width and height */ -- cgit v1.2.3