ComboBox SAME item selected action listener

前端 未结 1 1933

A combo box will fire an event if a DIFFERENT value is selected. I want to be also be able to listen to the SAME item being selected (that is, valueProperty has no change).

相关标签:
1条回答
  • 2020-12-21 15:23
    comboBox.showingProperty().addListener((obs, wasShowing, isShowing) -> {
        if (! isShowing) {
            System.out.println("Combo box popup hidden");
        }
    });
    

    This event handler might be triggered before the value is changed.

    0 讨论(0)
提交回复
热议问题