mirror of
https://github.com/Shpoike/Quakespasm.git
synced 2024-11-10 15:31:39 +00:00
* keys.c: added K_COMMAND as a new key. added Cmd+V as a Mac special
case for paste request. * keys.h: added K_COMMAND as a new key (170 for now). * in_sdl.c (IN_SendKeyEvents): translate SDLK_LMETA/SDLK_RMETA as K_COMMAND. ignore unhandled SDLK_WORLD_* international characters. git-svn-id: svn+ssh://svn.code.sf.net/p/quakespasm/code/trunk@746 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
parent
dbe3e98366
commit
7893e29fd4
6 changed files with 28 additions and 8 deletions
|
@ -478,6 +478,10 @@ void IN_SendKeyEvents (void)
|
|||
case SDLK_LALT:
|
||||
sym = K_ALT;
|
||||
break;
|
||||
case SDLK_RMETA:
|
||||
case SDLK_LMETA:
|
||||
sym = K_COMMAND;
|
||||
break;
|
||||
case SDLK_NUMLOCK:
|
||||
if (gamekey)
|
||||
sym = K_KP_NUMLOCK;
|
||||
|
@ -572,9 +576,10 @@ void IN_SendKeyEvents (void)
|
|||
sym = '~';
|
||||
break;
|
||||
}
|
||||
/* If we're not directly handled and still
|
||||
* above 255, just force it to 0 */
|
||||
if (sym > 255)
|
||||
/* If we are not directly handled and still above 255,
|
||||
* just force it to 0. kill unsupported international
|
||||
* characters, too. */
|
||||
if (sym > 255 || (sym >= SDLK_WORLD_0 && sym <= SDLK_WORLD_95))
|
||||
sym = 0;
|
||||
Key_Event (sym, state);
|
||||
break;
|
||||
|
|
|
@ -111,6 +111,8 @@ keyname_t keynames[] =
|
|||
{"HOME", K_HOME},
|
||||
{"END", K_END},
|
||||
|
||||
{"COMMAND", K_COMMAND},
|
||||
|
||||
{"MOUSE1", K_MOUSE1},
|
||||
{"MOUSE2", K_MOUSE2},
|
||||
{"MOUSE3", K_MOUSE3},
|
||||
|
@ -424,7 +426,15 @@ void Key_Console (int key)
|
|||
}
|
||||
}
|
||||
|
||||
if ((key=='V' || key=='v') && keydown[K_CTRL])
|
||||
#if defined(__MACOSX__) || defined(__MACOS__)
|
||||
/* Cmd+V paste request for Mac : */
|
||||
if (keydown[K_COMMAND] && (key == 'V' || key == 'v'))
|
||||
{
|
||||
PasteToConsole();
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
if (keydown[K_CTRL] && (key=='V' || key=='v'))
|
||||
{
|
||||
PasteToConsole();
|
||||
return;
|
||||
|
|
|
@ -78,6 +78,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|||
#define K_KP_INS 168
|
||||
#define K_KP_DEL 169
|
||||
|
||||
#define K_COMMAND 170
|
||||
|
||||
#define K_PAUSE 255
|
||||
|
||||
//
|
||||
|
|
|
@ -177,6 +177,7 @@ these patched libSDL binaries may help.
|
|||
<LI> Fixed control-character handling in unicode mode.</LI>
|
||||
<LI> Made the keypad keys to send separate key events in game mode.</LI>
|
||||
<LI> Text pasting support from OS clipboard to console. (windows and macosx.)</LI>
|
||||
<LI> Support for the Apple (Command) key on macosx.</LI>
|
||||
<LI> Fixed increased (more than 32) dynamic lights.</LI>
|
||||
<LI> Music playback: Made sure that the file's channels count is supported.</LI>
|
||||
<LI> Support for Solaris.</LI>
|
||||
|
@ -331,7 +332,7 @@ these patched libSDL binaries may help.
|
|||
<UL>
|
||||
<LI>Add uHexen2's first person camera (and menu item)</LI>
|
||||
<LI>Native CD audio support (if desired). cd_sdl.c doesn't have proper volume controls</LI>
|
||||
<LI>Test usb keyboards. Do the keypads work? Make the OSX apple key work.</LI>
|
||||
<LI>Test usb keyboards.</LI>
|
||||
<LI>Complete the unix user directories support</LI>
|
||||
</UL>
|
||||
</P>
|
||||
|
|
|
@ -103,6 +103,7 @@ these patched libSDL binaries may help.
|
|||
<item> Fixed control-character handling in unicode mode.
|
||||
<item> Made the keypad keys to send separate key events in game mode.
|
||||
<item> Text pasting support from OS clipboard to console. (windows and macosx.)
|
||||
<item> Support for the Apple (Command) key on macosx.
|
||||
<item> Fixed increased (more than 32) dynamic lights.
|
||||
<item> Music playback: Made sure that the file's channels count is supported.
|
||||
<item> Support for Solaris.
|
||||
|
@ -236,7 +237,7 @@ these patched libSDL binaries may help.
|
|||
<itemize>
|
||||
<item>Add uHexen2's first person camera (and menu item)
|
||||
<item>Native CD audio support (if desired). cd_sdl.c doesn't have proper volume controls
|
||||
<item>Test usb keyboards. Do the keypads work? Make the OSX apple key work.
|
||||
<item>Test usb keyboards.
|
||||
<item>Complete the unix user directories support
|
||||
</itemize>
|
||||
|
||||
|
|
|
@ -168,6 +168,8 @@
|
|||
o Text pasting support from OS clipboard to console. (windows and
|
||||
macosx.)
|
||||
|
||||
o Support for the Apple (Command) key on macosx.
|
||||
|
||||
o Fixed increased (more than 32) dynamic lights.
|
||||
|
||||
o Music playback: Made sure that the file's channels count is
|
||||
|
@ -408,8 +410,7 @@
|
|||
o Native CD audio support (if desired). cd_sdl.c doesn't have proper
|
||||
volume controls
|
||||
|
||||
o Test usb keyboards. Do the keypads work? Make the OSX apple key
|
||||
work.
|
||||
o Test usb keyboards.
|
||||
|
||||
o Complete the unix user directories support
|
||||
|
||||
|
|
Loading…
Reference in a new issue