Author Topic: [BUG] Hotkeys get "stuck" when file selector opens  (Read 3587 times)

0 Members and 1 Guest are viewing this topic.

Offline namida

  • Administrator
  • Posts: 12398
    • View Profile
    • NeoLemmix Website
[BUG] Hotkeys get "stuck" when file selector opens
« on: March 10, 2022, 06:19:18 PM »
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

Quote
Okay 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 Lemmings 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)

Offline namida

  • Administrator
  • Posts: 12398
    • View Profile
    • NeoLemmix Website
Re: [BUG] Hotkeys get "stuck" when file selector opens
« Reply #1 on: March 15, 2022, 06:34:27 PM »
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 Lemmings 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)