diff options
| author | Glenn Rice <glennricster@gmail.com> | 2010-04-12 01:33:10 +0000 |
|---|---|---|
| committer | Glenn Rice <glennricster@gmail.com> | 2010-04-12 01:33:10 +0000 |
| commit | 33a64d5db02df586483ad67974dedd2c2f6031d3 (patch) | |
| tree | d329f828aa7c620b75f598746e87b47ab0bdffb2 /Source/Core/InputCommon | |
| parent | ba853e682c93b8e0562674af00bfadefbdef7f9c (diff) | |
Big restructuring of how the video plugin works. In linux and windows you shouldn't see a change in the functionality; however, there are changes in how render to main or not, and fullscreen modes, and such are handled. Input is largely restructured for the video plugin. It is now handled by the host. Keys for pausing and changing fullscreen are configurable. More will probably be later. This is probably classified as highly experimental.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5336 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core/InputCommon')
| -rw-r--r-- | Source/Core/InputCommon/InputCommon.vcproj | 8 | ||||
| -rw-r--r-- | Source/Core/InputCommon/Src/SConscript | 5 | ||||
| -rw-r--r-- | Source/Core/InputCommon/Src/X11InputBase.cpp | 12 | ||||
| -rw-r--r-- | Source/Core/InputCommon/Src/X11InputBase.h | 3 |
4 files changed, 25 insertions, 3 deletions
diff --git a/Source/Core/InputCommon/InputCommon.vcproj b/Source/Core/InputCommon/InputCommon.vcproj index b86cd2561d..ec422e111c 100644 --- a/Source/Core/InputCommon/InputCommon.vcproj +++ b/Source/Core/InputCommon/InputCommon.vcproj @@ -449,6 +449,14 @@ >
</File>
<File
+ RelativePath=".\Src\WXInputBase.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\Src\WXInputBase.h"
+ >
+ </File>
+ <File
RelativePath=".\Src\XInput_Util.cpp"
>
</File>
diff --git a/Source/Core/InputCommon/Src/SConscript b/Source/Core/InputCommon/Src/SConscript index 1df5cf64a3..6d1177c257 100644 --- a/Source/Core/InputCommon/Src/SConscript +++ b/Source/Core/InputCommon/Src/SConscript @@ -14,6 +14,11 @@ if env['HAVE_X11']: "X11InputBase.cpp", ] +if env['HAVE_WX']: + files += [ + "WXInputBase.cpp", + ] + env_inputcommon = env.Clone() env_inputcommon.Append(CXXFLAGS = [ '-fPIC' ]) env_inputcommon.StaticLibrary(env['local_libs'] + "inputcommon", files) diff --git a/Source/Core/InputCommon/Src/X11InputBase.cpp b/Source/Core/InputCommon/Src/X11InputBase.cpp index 480b37d408..7f33a7ee7b 100644 --- a/Source/Core/InputCommon/Src/X11InputBase.cpp +++ b/Source/Core/InputCommon/Src/X11InputBase.cpp @@ -112,10 +112,16 @@ KeySym wxCharCodeWXToX(int id) return keySym; } -#else -KeySym wxCharCodeWXToX(int id) +int wxKeyModWXToX(int modstate) { - return NULL; + int xstate = 0; + if (modstate & wxMOD_ALT) + xstate |= 8; + if (modstate & wxMOD_SHIFT) + xstate |= 1; + if (modstate & wxMOD_CONTROL) + xstate |= 4; + return xstate; } #endif void XKeyToString(unsigned int keycode, char *keyStr) { diff --git a/Source/Core/InputCommon/Src/X11InputBase.h b/Source/Core/InputCommon/Src/X11InputBase.h index ea8226801e..13c6717f86 100644 --- a/Source/Core/InputCommon/Src/X11InputBase.h +++ b/Source/Core/InputCommon/Src/X11InputBase.h @@ -26,7 +26,10 @@ #endif namespace InputCommon { +#if defined(HAVE_WX) && HAVE_WX KeySym wxCharCodeWXToX(int id); +int wxKeyModWXToX(int modstate); +#endif void XKeyToString(unsigned int keycode, char *keyStr); } #endif |
