JPro-one / JPro

The right place to report about bugs or suggest improvements for JPro.
https://www.jpro.one
9 stars 4 forks source link

Tooltip prevents tab navigation away from input field #188

Open wuedev opened 3 hours ago

wuedev commented 3 hours ago

When a tooltip is shown on an input field, we cannot navigate to the next control with the tab key.

Reproduce:

void start(Stage stage) {

        var testField = new TextField();
        testField.setTooltip(new Tooltip("Hi"));
        var testBtn = new Button("Test");

        var vbox = new VBox(20, testField, testBtn);

        var scene = new Scene(vbox);
        stage.setScene(scene);
        stage.show();                

    }
  1. Click on the text field, wait for the tooltip to show
  2. Press TAB - nothing happens
  3. Wait for the tooltip to disappear
  4. Press TAB - focus moves to the next control as expected

This is a problem for example with the FXForms package, which shows tooltips permanently when an input field has focus, also when there are error messages for the field. So this means in these cases the TAB key doesn't work as expected.

This behaviour doesn't occur when the JavaFX app runs locally.

JPro version: 2024.3.3 Java version: 17 Browser version: firefox 131.0.3 OS: openSuse 15.5

FlorianKirmaier commented 3 hours ago

Hi @wuedev Thank you for the bug report! It is probably the same root cause as the following ticket: https://github.com/JPro-one/JPro/issues/187 We will take a look and make this event handling more robust!