diff options
Diffstat (limited to 'src/common/key_map.cpp')
| -rw-r--r-- | src/common/key_map.cpp | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/src/common/key_map.cpp b/src/common/key_map.cpp new file mode 100644 index 000000000..5941a105b --- /dev/null +++ b/src/common/key_map.cpp | |||
| @@ -0,0 +1,21 @@ | |||
| 1 | // Copyright 2013 Dolphin Emulator Project | ||
| 2 | // Licensed under GPLv2 | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #include "key_map.h" | ||
| 6 | #include <map> | ||
| 7 | |||
| 8 | |||
| 9 | namespace KeyMap { | ||
| 10 | |||
| 11 | std::map<CitraKey, HID_User::PADState> g_key_map; | ||
| 12 | |||
| 13 | void SetKeyMapping(CitraKey key, HID_User::PADState padState) { | ||
| 14 | g_key_map[key].hex = padState.hex; | ||
| 15 | } | ||
| 16 | |||
| 17 | HID_User::PADState Get3DSKey(CitraKey key) { | ||
| 18 | return g_key_map[key]; | ||
| 19 | } | ||
| 20 | |||
| 21 | } | ||