All key commands don't work
thomas-schiwietz-ai opened this issue · 4 comments
None of the key commands work anymore.
keymod is always false:
https://github.com/googlecartographer/point_cloud_viewer/blob/master/sdl_viewer/src/lib.rs#L439
related to Rust-SDL2/rust-sdl2#580?
cannot repro on latest master with latest rust stable.
This seems to be related to an active num lock or caps lock. In this statement keymod is only checked for an empty value, which is not the case, if num lock is active. A work around would be to change
if keymod.is_empty()
to
if keymod.is_empty() || keymod.intersects(NUMMOD | CAPSMOD) && !keymod.intersects(LCTRLMOD | RCTRLMOD)
The last check prevents the following else ifs from breaking.
Alternatively one could tell the user to disable num lock etc. on the keyboard, which seems inconvenient.
Please fix this issue. Its very annoying and very non-intuitive.