forked from len0rd/rockbox
Adapted most multi-source plugins to the iAudio M3 keypad and screen. Doom and mpegplayer are disabled because of the not yet implemented greyscale library, and zxbox used 2-bit greyscale for now. * Slight optimisation for the (currently unused except on M3) 2-bit greyscale code in zxbox. * Simplified button definitions in chessbox.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16744 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
95d8590659
commit
106ac75ad8
17 changed files with 335 additions and 447 deletions
|
@ -40,211 +40,6 @@ extern const fb_data chessbox_pieces[];
|
|||
|
||||
PLUGIN_HEADER
|
||||
|
||||
/* button definitions */
|
||||
#if (CONFIG_KEYPAD == IPOD_4G_PAD) || (CONFIG_KEYPAD == IPOD_3G_PAD) || \
|
||||
(CONFIG_KEYPAD == IPOD_1G2G_PAD)
|
||||
#define CB_SELECT BUTTON_SELECT
|
||||
#define CB_UP BUTTON_MENU
|
||||
#define CB_DOWN BUTTON_PLAY
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY (BUTTON_SELECT | BUTTON_PLAY)
|
||||
#define CB_LEVEL (BUTTON_SELECT | BUTTON_RIGHT)
|
||||
#define CB_MENU (BUTTON_SELECT | BUTTON_MENU)
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_SCROLL_FWD|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_SCROLL_BACK|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif CONFIG_KEYPAD == IAUDIO_X5M5_PAD
|
||||
#define CB_SELECT BUTTON_SELECT
|
||||
#define CB_UP BUTTON_UP
|
||||
#define CB_DOWN BUTTON_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY BUTTON_PLAY
|
||||
#define CB_LEVEL BUTTON_REC
|
||||
#define CB_MENU BUTTON_POWER
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_UP|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif (CONFIG_KEYPAD == IRIVER_H100_PAD) || (CONFIG_KEYPAD == IRIVER_H300_PAD)
|
||||
#define CB_SELECT BUTTON_SELECT
|
||||
#define CB_UP BUTTON_UP
|
||||
#define CB_DOWN BUTTON_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY BUTTON_ON
|
||||
#define CB_LEVEL BUTTON_MODE
|
||||
#define CB_MENU BUTTON_OFF
|
||||
|
||||
#define CB_RC_QUIT BUTTON_RC_STOP
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_UP|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif CONFIG_KEYPAD == IRIVER_IFP7XX_PAD
|
||||
#define CB_SELECT BUTTON_SELECT
|
||||
#define CB_UP BUTTON_UP
|
||||
#define CB_DOWN BUTTON_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY BUTTON_PLAY
|
||||
#define CB_LEVEL BUTTON_EQ
|
||||
#define CB_MENU BUTTON_MODE
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_UP|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif CONFIG_KEYPAD == RECORDER_PAD
|
||||
#define CB_SELECT BUTTON_PLAY
|
||||
#define CB_UP BUTTON_UP
|
||||
#define CB_DOWN BUTTON_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY BUTTON_ON
|
||||
#define CB_LEVEL BUTTON_F1
|
||||
#define CB_MENU BUTTON_OFF
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_UP|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif CONFIG_KEYPAD == ARCHOS_AV300_PAD
|
||||
#define CB_SELECT BUTTON_SELECT
|
||||
#define CB_UP BUTTON_UP
|
||||
#define CB_DOWN BUTTON_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY BUTTON_ON
|
||||
#define CB_LEVEL BUTTON_F1
|
||||
#define CB_MENU BUTTON_OFF
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_UP|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif CONFIG_KEYPAD == ONDIO_PAD
|
||||
#define CB_SELECT_PRE BUTTON_MENU
|
||||
#define CB_SELECT (BUTTON_MENU|BUTTON_REL)
|
||||
#define CB_UP BUTTON_UP
|
||||
#define CB_DOWN BUTTON_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY_PRE BUTTON_MENU
|
||||
#define CB_PLAY (BUTTON_MENU|BUTTON_REPEAT)
|
||||
#define CB_LEVEL (BUTTON_MENU|BUTTON_OFF)
|
||||
#define CB_MENU BUTTON_OFF
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_UP|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif (CONFIG_KEYPAD == GIGABEAT_PAD)
|
||||
#define CB_SELECT BUTTON_SELECT
|
||||
#define CB_UP BUTTON_UP
|
||||
#define CB_DOWN BUTTON_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY BUTTON_A
|
||||
#define CB_LEVEL BUTTON_MENU
|
||||
#define CB_MENU BUTTON_POWER
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_UP|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif CONFIG_KEYPAD == IRIVER_H10_PAD
|
||||
#define CB_SELECT BUTTON_REW
|
||||
#define CB_UP BUTTON_SCROLL_UP
|
||||
#define CB_DOWN BUTTON_SCROLL_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY BUTTON_PLAY
|
||||
#define CB_LEVEL BUTTON_FF
|
||||
#define CB_MENU BUTTON_POWER
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_SCROLL_UP|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_SCROLL_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif CONFIG_KEYPAD == SANSA_E200_PAD
|
||||
#define CB_SELECT BUTTON_SELECT
|
||||
#define CB_UP BUTTON_UP
|
||||
#define CB_DOWN BUTTON_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY (BUTTON_SELECT | BUTTON_RIGHT)
|
||||
#define CB_LEVEL BUTTON_REC
|
||||
#define CB_MENU BUTTON_POWER
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_SCROLL_BACK|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_SCROLL_FWD|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif CONFIG_KEYPAD == SANSA_C200_PAD
|
||||
#define CB_SELECT BUTTON_SELECT
|
||||
#define CB_UP BUTTON_UP
|
||||
#define CB_DOWN BUTTON_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY BUTTON_VOL_UP
|
||||
#define CB_LEVEL BUTTON_REC
|
||||
#define CB_MENU BUTTON_POWER
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_UP|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#elif CONFIG_KEYPAD == MROBE500_PAD
|
||||
#define CB_SELECT BUTTON_RC_MODE
|
||||
#define CB_UP BUTTON_RC_PLAY
|
||||
#define CB_DOWN BUTTON_RC_DOWN
|
||||
#define CB_LEFT BUTTON_RC_REW
|
||||
#define CB_RIGHT BUTTON_RC_FF
|
||||
#define CB_PLAY BUTTON_RC_HEART
|
||||
#define CB_LEVEL BUTTON_RC_VOL_DOWN
|
||||
#define CB_MENU BUTTON_POWER
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_RC_PLAY|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_RC_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_RC_REW|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RC_FF|BUTTON_REPEAT)
|
||||
|
||||
#elif (CONFIG_KEYPAD == MROBE100_PAD)
|
||||
#define CB_SELECT BUTTON_SELECT
|
||||
#define CB_UP BUTTON_UP
|
||||
#define CB_DOWN BUTTON_DOWN
|
||||
#define CB_LEFT BUTTON_LEFT
|
||||
#define CB_RIGHT BUTTON_RIGHT
|
||||
#define CB_PLAY BUTTON_PLAY
|
||||
#define CB_LEVEL BUTTON_DISPLAY
|
||||
#define CB_MENU BUTTON_POWER
|
||||
|
||||
#define CB_SCROLL_UP (BUTTON_UP|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_DOWN (BUTTON_DOWN|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_LEFT (BUTTON_LEFT|BUTTON_REPEAT)
|
||||
#define CB_SCROLL_RIGHT (BUTTON_RIGHT|BUTTON_REPEAT)
|
||||
|
||||
#else
|
||||
#error No keymap defined!
|
||||
#endif
|
||||
|
||||
/* Tile size defined by the assigned bitmap */
|
||||
#include "chessbox_pieces.h"
|
||||
#define TILE_WIDTH BMPWIDTH_chessbox_pieces
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue