]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commit
Manage resetting the key event state on video reinitialization centrally.
authorRudolf Polzer <divVerent@xonotic.org>
Thu, 2 Nov 2017 15:58:55 +0000 (16:58 +0100)
committerRudolf Polzer <divVerent@xonotic.org>
Thu, 2 Nov 2017 16:02:18 +0000 (17:02 +0100)
commitb16813e33729c9418223c53b8f0a1d37e19386c2
tree9a0a9cbafa04b0262507ea22bbccf41eb02fff2e
parentb525495b9939e6aec1fb8a44ebf0976589d26038
Manage resetting the key event state on video reinitialization centrally.

Fixes:
- No key state clear when SDL gets restarted.
- Key state clear was the wrong action - it allows all keys to get pressed
  again, but does not actually release anything in cl_input.c, so e.g. +jump
  binds stay pressed on vid_restart.

Only vid_wgl.c retains some vid-specific handling (reset of key state when
alt-tabbing out and back in) - there's a chance that we may need similar logic
in the other vid drivers; if so, it may be possible to do this in a shared
place too by watching for changes to vid_activewindow.
keys.c
keys.h
vid_agl.c
vid_glx.c
vid_shared.c
vid_wgl.c