Skip to content

Key presses report "virtual" key presses (including repetition), not physical key down events #558

Closed

Description

@dylanede

Glutin currently supports key press events and key release events. But (on Windows at least), key press events correspond to the virtual key presses that the OS does, including the repeated presses that occur when you hold the key down. I would really like to be able to get actual physical key down events as well, and distinguish between "presses" and key down events. At the moment, you can get more key press events than release events due to press repetition. I need this distinction for integration with the Chromium Embedded Framework, which has three types of key event - up, down and press.

The ElementState enum currently contains Pressed and Released. Ideally it would change to Pressed, Down and Up. This would be a breaking change, but easy to correct in user applications.

Activity

  1. dylanede commented on Aug 3, 2015

    @dylanede
    ContributorAuthor

    I would also like to add that this is not a blocking issue for CEF, since the behaviour can be emulated by tracking key state.

  2. Limeth commented on Sep 3, 2016

    @Limeth

    I am not sure, but I think this also causes LAlt not to function on Windows.

  3. tomaka commented on Nov 3, 2016

    @tomaka
    Contributor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions