diff src/common/inputGlobal.h @ 1:f9f4f1b99eed

importing src directory
author Robert McIntyre <rlm@mit.edu>
date Sat, 03 Mar 2012 10:31:27 -0600
parents
children
line wrap: on
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/src/common/inputGlobal.h	Sat Mar 03 10:31:27 2012 -0600
     1.3 @@ -0,0 +1,48 @@
     1.4 +#ifndef VBA_INPUT_GLOBAL_H
     1.5 +#define VBA_INPUT_GLOBAL_H
     1.6 +
     1.7 +#if _MSC_VER > 1000
     1.8 +#pragma once
     1.9 +#endif // _MSC_VER > 1000
    1.10 +
    1.11 +enum
    1.12 +{
    1.13 +	KEY_BUTTON_A, KEY_BUTTON_B,
    1.14 +	KEY_BUTTON_SELECT, KEY_BUTTON_START,
    1.15 +	KEY_RIGHT, KEY_LEFT,
    1.16 +	KEY_UP, KEY_DOWN,
    1.17 +	KEY_BUTTON_R, KEY_BUTTON_L,
    1.18 +	KEY_BUTTON_SPEED, KEY_BUTTON_CAPTURE,
    1.19 +	KEY_BUTTON_GS
    1.20 +};
    1.21 +
    1.22 +#define BUTTON_MASK_A                    (0x0001)
    1.23 +#define BUTTON_MASK_B                    (0x0002)
    1.24 +#define BUTTON_MASK_SELECT               (0x0004)
    1.25 +#define BUTTON_MASK_START                (0x0008)
    1.26 +#define BUTTON_MASK_RIGHT                (0x0010)
    1.27 +#define BUTTON_MASK_LEFT                 (0x0020)
    1.28 +#define BUTTON_MASK_UP                   (0x0040)
    1.29 +#define BUTTON_MASK_DOWN                 (0x0080)
    1.30 +#define BUTTON_MASK_R                    (0x0100)
    1.31 +#define BUTTON_MASK_L                    (0x0200)
    1.32 +#define BUTTON_GB_MASK                   (BUTTON_MASK_A|BUTTON_MASK_B|BUTTON_MASK_SELECT|BUTTON_MASK_START| \
    1.33 +                                          BUTTON_MASK_RIGHT|BUTTON_MASK_LEFT|BUTTON_MASK_UP|BUTTON_MASK_DOWN)
    1.34 +#define BUTTON_GBA_ONLY                  (BUTTON_MASK_R|BUTTON_MASK_L)
    1.35 +#define BUTTON_REGULAR_MASK              (BUTTON_GB_MASK|BUTTON_GBA_ONLY)
    1.36 +#define BUTTON_MASK_OLD_RESET            (0x0400)
    1.37 +#define BUTTON_MASK_NEW_RESET            (0x0800)
    1.38 +#define BUTTON_MASK_LEFT_MOTION          (0x1000)
    1.39 +#define BUTTON_MASK_RIGHT_MOTION         (0x2000)
    1.40 +#define BUTTON_MASK_DOWN_MOTION          (0x4000)
    1.41 +#define BUTTON_MASK_UP_MOTION            (0x8000)
    1.42 +#define BUTTON_MOTION_MASK               (BUTTON_MASK_LEFT_MOTION|BUTTON_MASK_RIGHT_MOTION|BUTTON_MASK_DOWN_MOTION| \
    1.43 +                                          BUTTON_MASK_UP_MOTION)
    1.44 +#define BUTTON_RECORDINGONLY_MASK        (BUTTON_MASK_OLD_RESET|BUTTON_MASK_NEW_RESET|BUTTON_MOTION_MASK)
    1.45 +#define BUTTON_REGULAR_RECORDING_MASK	 (BUTTON_REGULAR_MASK|BUTTON_RECORDINGONLY_MASK)
    1.46 +#define BUTTON_MASK_SPEED                (0x040000)
    1.47 +#define BUTTON_MASK_CAPTURE              (0x080000)
    1.48 +#define BUTTON_MASK_GAMESHARK            (0x100000)
    1.49 +#define BUTTON_NONRECORDINGONLY_MASK     (BUTTON_MASK_SPEED|BUTTON_MASK_CAPTURE|BUTTON_MASK_GAMESHARK)
    1.50 +
    1.51 +#endif // VBA_INPUT_GLOBAL_H