[BUG] Hotkeys get "stuck" when file selector opens

Started by namida, March 10, 2022, 06:19:18 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

namida

Steps to reproduce (one example):
1. Assign "Load Replay" and a move camera function to the same key
2. Load a replay on the preview screen via this hotkey
3. Go into gameplay
4. Notice how the camera moves as if you were still holding the key

QuoteOkay so, this one seems to be something pretty low-level in how the framework and the file-select dialog interact with each other, so I'm not sure that I can fix it. Putting them on different hotkeys should help, of course; beyond that, I likely need to find a better cross-platform solution to open a file dialog, or failing that, write platform-specific code each for Windows and Linux here to handle it properly without interfering with keyboard input. This is likely to become one of those minor "stuck" bugs that doesn't get fixed for a long time, unfortunately.
My projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)
Non-Lemmings: Commander Keen: Galaxy Reimagined (a Commander Keen fangame)

namida

DireKrow suggested on Discord a workaround of opening the dialogs when the keys are released rather than when they're pressed. This workaround is implemented in commit e875712. However, I'd still like to arrange a proper solution at some point, as this merely mitigates the issue rather than actually fixing it.
My projects
2D Lemmings: NeoLemmix (engine) | Lemmings Plus Series (level packs) | Doomsday Lemmings (level pack)
3D Lemmings: Loap (engine) | L3DEdit (level / graphics editor) | L3DUtils (replay / etc utility) | Lemmings Plus 3D (level pack)
Non-Lemmings: Commander Keen: Galaxy Reimagined (a Commander Keen fangame)