GCPadEmu/WiimoteEmu: Make some arrays static

This commit is contained in:
Lioncash 2014-10-31 09:51:51 -04:00
parent ef1520eab0
commit 5a321d31dd
2 changed files with 9 additions and 9 deletions

View File

@ -8,7 +8,7 @@
// TODO: Move to header file when VS supports constexpr.
const ControlState GCPad::DEFAULT_PAD_STICK_RADIUS = 1.0;
const u16 button_bitmasks[] =
static const u16 button_bitmasks[] =
{
PAD_BUTTON_A,
PAD_BUTTON_B,
@ -19,18 +19,18 @@ const u16 button_bitmasks[] =
0 // MIC HAX
};
const u16 trigger_bitmasks[] =
static const u16 trigger_bitmasks[] =
{
PAD_TRIGGER_L,
PAD_TRIGGER_R,
};
const u16 dpad_bitmasks[] =
static const u16 dpad_bitmasks[] =
{
PAD_BUTTON_UP, PAD_BUTTON_DOWN, PAD_BUTTON_LEFT, PAD_BUTTON_RIGHT
};
const char* const named_buttons[] =
static const char* const named_buttons[] =
{
"A",
"B",
@ -41,7 +41,7 @@ const char* const named_buttons[] =
"Mic"
};
const char* const named_triggers[] =
static const char* const named_triggers[] =
{
// i18n: Left
_trans("L"),

View File

@ -171,7 +171,7 @@ void EmulateSwing(AccelData* const accel
(&accel->x)[axis_map[i]] += swing[i] * g_dir[i] * SWING_INTENSITY;
}
const u16 button_bitmasks[] =
static const u16 button_bitmasks[] =
{
Wiimote::BUTTON_A,
Wiimote::BUTTON_B,
@ -182,16 +182,16 @@ const u16 button_bitmasks[] =
Wiimote::BUTTON_HOME
};
const u16 dpad_bitmasks[] =
static const u16 dpad_bitmasks[] =
{
Wiimote::PAD_UP, Wiimote::PAD_DOWN, Wiimote::PAD_LEFT, Wiimote::PAD_RIGHT
};
const u16 dpad_sideways_bitmasks[] =
static const u16 dpad_sideways_bitmasks[] =
{
Wiimote::PAD_RIGHT, Wiimote::PAD_LEFT, Wiimote::PAD_UP, Wiimote::PAD_DOWN
};
const char* const named_buttons[] =
static const char* const named_buttons[] =
{
"A", "B", "1", "2", "-", "+", "Home",
};