Added option to hide mouse cursor (without disabling the mouse completely)
This commit is contained in:
parent
a55dd5e69b
commit
a43f7df8d0
|
@ -6,6 +6,7 @@ main/gamerend.c, main/multi.c, net_udp.c: Fixed some minor HUD-text related issu
|
|||
main/kmatrix.c: Defer free of kmatrix data until window is fully gone - patch by Kp
|
||||
main/kconfig.c: Added default keys for weapon cycling similar to Descent 2 and reverted default reverse key to Z as default as more convinient for the QUERTY keyboard layout
|
||||
main/inferno.c: Disable fullscreen toggling via ALT+ENTER if Game_wind is on top so toggling cannot be done accidentially ingame
|
||||
arch/sdl/mouse.c, d1x.ini, include/args.h, main/inferno.c, misc/args.c: Added option to hide mouse cursor (without disabling the mouse completely)
|
||||
|
||||
20130103
|
||||
--------
|
||||
|
|
|
@ -237,7 +237,7 @@ int mouse_get_btns()
|
|||
|
||||
void mouse_toggle_cursor(int activate)
|
||||
{
|
||||
Mouse.cursor_enabled = (activate && !GameArg.CtlNoMouse);
|
||||
Mouse.cursor_enabled = (activate && !GameArg.CtlNoMouse && !GameArg.CtlNoCursor);
|
||||
if (!Mouse.cursor_enabled)
|
||||
SDL_ShowCursor(SDL_DISABLE);
|
||||
}
|
||||
|
|
1
d1x.ini
1
d1x.ini
|
@ -14,6 +14,7 @@
|
|||
|
||||
Controls:
|
||||
|
||||
;-nocursor Hide mouse cursor
|
||||
;-nomouse Deactivate mouse
|
||||
;-nojoystick Deactivate joystick
|
||||
;-nostickykeys Make CapsLock and NumLock non-sticky
|
||||
|
|
|
@ -52,6 +52,7 @@ typedef struct Arg
|
|||
int SysNoBorders;
|
||||
int SysAutoDemo;
|
||||
int SysNoTitles;
|
||||
int CtlNoCursor;
|
||||
int CtlNoMouse;
|
||||
int CtlNoJoystick;
|
||||
int CtlNoStickyKeys;
|
||||
|
|
|
@ -114,6 +114,7 @@ void print_commandline_help()
|
|||
printf( " -noborders Do not show borders in window mode\n");
|
||||
|
||||
printf( "\n Controls:\n\n");
|
||||
printf( " -nocursor Hide mouse cursor\n");
|
||||
printf( " -nomouse Deactivate mouse\n");
|
||||
printf( " -nojoystick Deactivate joystick\n");
|
||||
printf( " -nostickykeys Make CapsLock and NumLock non-sticky\n");
|
||||
|
|
|
@ -146,6 +146,7 @@ void ReadCmdArgs(void)
|
|||
|
||||
// Control Options
|
||||
|
||||
GameArg.CtlNoCursor = FindArg("-nocursor");
|
||||
GameArg.CtlNoMouse = FindArg("-nomouse");
|
||||
GameArg.CtlNoJoystick = FindArg("-nojoystick");
|
||||
GameArg.CtlNoStickyKeys = FindArg("-nostickykeys");
|
||||
|
|
Loading…
Reference in a new issue