summaryrefslogtreecommitdiffstats
path: root/uisimulator
diff options
context:
space:
mode:
authorSzymon Dziok <b0hoon@o2.pl>2010-02-01 16:41:03 +0000
committerSzymon Dziok <b0hoon@o2.pl>2010-02-01 16:41:03 +0000
commita09606123f4e8501dd527c48d493853435df2a0d (patch)
tree7ec42424f79a5ad1f6c0841e78bc60b8d7454802 /uisimulator
parent9938ea4b793e99026333496eccd7e1eeb4e0cb7e (diff)
downloadrockbox-a09606123f4e8501dd527c48d493853435df2a0d.tar.gz
rockbox-a09606123f4e8501dd527c48d493853435df2a0d.zip
Packard Bell Vibe 500: add the simulator
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24439 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'uisimulator')
-rw-r--r--uisimulator/sdl/UI-vibe500.bmpbin0 -> 421688 bytes
-rw-r--r--uisimulator/sdl/button.c37
-rw-r--r--uisimulator/sdl/uisdl.h7
3 files changed, 43 insertions, 1 deletions
diff --git a/uisimulator/sdl/UI-vibe500.bmp b/uisimulator/sdl/UI-vibe500.bmp
new file mode 100644
index 0000000000..8c12aa5fff
--- /dev/null
+++ b/uisimulator/sdl/UI-vibe500.bmp
Binary files differ
diff --git a/uisimulator/sdl/button.c b/uisimulator/sdl/button.c
index 0f9770dcac..a102925ed2 100644
--- a/uisimulator/sdl/button.c
+++ b/uisimulator/sdl/button.c
@@ -1248,7 +1248,42 @@ void button_event(int key, bool pressed)
break;
case SDLK_KP_MINUS:
new_btn = BUTTON_VOL_DOWN;
- break;
+ break;
+#elif CONFIG_KEYPAD == PBELL_VIBE500_PAD
+ case SDLK_KP4:
+ case SDLK_LEFT:
+ new_btn = BUTTON_PREV;
+ break;
+ case SDLK_KP6:
+ case SDLK_RIGHT:
+ new_btn = BUTTON_NEXT;
+ break;
+ case SDLK_KP8:
+ case SDLK_UP:
+ new_btn = BUTTON_UP;
+ break;
+ case SDLK_KP2:
+ case SDLK_DOWN:
+ new_btn = BUTTON_DOWN;
+ break;
+ case SDLK_KP7:
+ new_btn = BUTTON_MENU;
+ break;
+ case SDLK_KP9:
+ new_btn = BUTTON_PLAY;
+ break;
+ case SDLK_KP5:
+ new_btn = BUTTON_OK;
+ break;
+ case SDLK_KP_DIVIDE:
+ new_btn = BUTTON_CANCEL;
+ break;
+ case SDLK_KP_PLUS:
+ new_btn = BUTTON_POWER;
+ break;
+ case SDLK_KP_MULTIPLY:
+ new_btn = BUTTON_REC;
+ break;
#else
#error No keymap defined!
#endif /* CONFIG_KEYPAD */
diff --git a/uisimulator/sdl/uisdl.h b/uisimulator/sdl/uisdl.h
index 5dfb9c5c2b..58a2f9959d 100644
--- a/uisimulator/sdl/uisdl.h
+++ b/uisimulator/sdl/uisdl.h
@@ -364,6 +364,13 @@
#define UI_HEIGHT 436 /* height of GUI window */
#define UI_LCD_POSX 148 /* x position of lcd */
#define UI_LCD_POSY 50 /* y position of lcd */
+
+#elif defined(PBELL_VIBE500)
+#define UI_TITLE "Packard Bell Vibe 500"
+#define UI_WIDTH 287 /* width of GUI window */
+#define UI_HEIGHT 488 /* height of GUI window */
+#define UI_LCD_POSX 64 /* x position of lcd */
+#define UI_LCD_POSY 61 /* y position of lcd */
#else
#error no UI defines
#endif