Tab key not working with ctrl down

Started by MGVizor, June 05, 2025, 12:44:19

Previous topic - Next topic

MGVizor

The implementation of listener looks something like this:

private static final class GlfwKeyListener implements GLFWKeyCallbackI {
    private int key;

    @Override
    public void invoke(long window, int key, int scancode, int action, int mods) {
        KeyClass.key = key;
        //schedule to set key to 0 on next frame
    }
}

Then I log the inputs with something like this:

private void logUsedKeys() {
    int key = KeyClass.key;
    if (key != 0) {
        LOGGER.info("Key {}", key);
    }
}

However, when the ctrl is down it prints any pressed key, but tab.

Using macOS if it is important. In other apps everything works fine(e.g. switching tabs in browser/intellij idea)
lwjgl version: 3.3.1