diff options
author | Jens Arnold <amiconn@rockbox.org> | 2005-11-22 01:15:31 +0000 |
---|---|---|
committer | Jens Arnold <amiconn@rockbox.org> | 2005-11-22 01:15:31 +0000 |
commit | 49a0a945ac5ee6598a2ff15c3b806e5fa0a727be (patch) | |
tree | 2e73c47d0eebbcadd87accf2e80fe3796565a9b2 /uisimulator | |
parent | b51f7dfc9b507ab9db12fe90b2ddad708f435e06 (diff) |
Win32 simulator now supports iPod Color. Fixed screendump() to correctly work for iPod simulators on big endian machines. Removed duplicate button definitions.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8035 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'uisimulator')
-rw-r--r-- | uisimulator/win32/UI-ipodcolor.bmp | bin | 0 -> 131232 bytes | |||
-rw-r--r-- | uisimulator/win32/button.c | 12 | ||||
-rw-r--r-- | uisimulator/win32/lcd-win32.c | 5 | ||||
-rw-r--r-- | uisimulator/win32/uisw32.h | 10 |
4 files changed, 24 insertions, 3 deletions
diff --git a/uisimulator/win32/UI-ipodcolor.bmp b/uisimulator/win32/UI-ipodcolor.bmp Binary files differnew file mode 100644 index 0000000000..de5dad4ffe --- /dev/null +++ b/uisimulator/win32/UI-ipodcolor.bmp diff --git a/uisimulator/win32/button.c b/uisimulator/win32/button.c index 47adbb485f..579a74a78a 100644 --- a/uisimulator/win32/button.c +++ b/uisimulator/win32/button.c @@ -64,6 +64,8 @@ void button_event(int key, bool pressed) case VK_UP: #ifdef BUTTON_UP new_btn = BUTTON_UP; +#elif defined BUTTON_SCROLL_FWD + new_btn = BUTTON_SCROLL_FWD; #elif defined BUTTON_PLAY new_btn = BUTTON_PLAY; #endif @@ -73,16 +75,20 @@ void button_event(int key, bool pressed) case VK_DOWN: #ifdef BUTTON_DOWN new_btn = BUTTON_DOWN; +#elif defined BUTTON_SCROLL_BACK + new_btn = BUTTON_SCROLL_BACK; #elif defined BUTTON_STOP new_btn = BUTTON_STOP; #endif break; -#ifdef BUTTON_ON case VK_ADD: +#ifdef BUTTON_ON new_btn = BUTTON_ON; - break; +#elif defined(BUTTON_SELECT) && defined(BUTTON_PLAY) + new_btn = BUTTON_PLAY; #endif + break; #ifdef BUTTON_OFF case VK_RETURN: @@ -112,7 +118,7 @@ void button_event(int key, bool pressed) case VK_NUMPAD5: case VK_SPACE: -#ifdef BUTTON_PLAY +#if defined(BUTTON_PLAY) && !defined(BUTTON_SELECT) new_btn = BUTTON_PLAY; #elif defined(BUTTON_SELECT) new_btn = BUTTON_SELECT; diff --git a/uisimulator/win32/lcd-win32.c b/uisimulator/win32/lcd-win32.c index f5672a58bf..e9bf1dacf8 100644 --- a/uisimulator/win32/lcd-win32.c +++ b/uisimulator/win32/lcd-win32.c @@ -97,8 +97,13 @@ void lcd_update_rect(int x_start, int y_start, #elif LCD_DEPTH == 2 bitmap[y][x] = ((lcd_framebuffer[y/4][x] >> (2 * (y & 3))) & 3); #elif LCD_DEPTH == 16 +#if LCD_PIXELFORMAT == RGB565SWAPPED + unsigned bits = lcd_framebuffer[y][x]; + bitmap[y][x] = (bits >> 8) | (bits << 8); +#else bitmap[y][x] = lcd_framebuffer[y][x]; #endif +#endif } /* Invalidate only the window part that actually did change */ diff --git a/uisimulator/win32/uisw32.h b/uisimulator/win32/uisw32.h index 7cbaa6ce47..af4a08ef95 100644 --- a/uisimulator/win32/uisw32.h +++ b/uisimulator/win32/uisw32.h @@ -109,6 +109,16 @@ typedef unsigned short wchar_t; #define UI_REMOTE_WIDTH 128 #define UI_REMOTE_HEIGHT 64 +#elif defined(IPOD_COLOR) +#define UI_TITLE "iPod Color" +#define UI_WIDTH 261 // width of GUI window +#define UI_HEIGHT 493 // height of GUI window +/* high-colour */ +#define UI_LCD_POSX 21 // x position of lcd +#define UI_LCD_POSY 16 // y position of lcd +#define UI_LCD_WIDTH 220 +#define UI_LCD_HEIGHT 176 + #elif defined(ARCHOS_GMINI120) #define UI_TITLE "Gmini 120" #define UI_WIDTH 370 // width of GUI window |