How to detect when a ComboBox's menu item is really selected by the user?

How to detect when a ComboBox's menu item is really selected by the user?

I'm currently facing the situation that if a user clicks on my ComboBox and moves the selection with his keys, the selection listener will keep being called, although for all purposes a choice was still not really made by the user.

I'm currently facing the situation that if a user clicks on my ComboBox and moves the selection with his keys, the selection listener will keep being called, although for all purposes a choice was still not really made by the user.

How can I distinguish those "intermediate" selections from the proper, final, user selection in my ComboBox?

I tried looking at variables such as isPopupVisible or even playing with PopupMenuListener but they didn't seem to really help.

Thanks

Edit: Example of the offending code:

public class Main extends JFrame {    
    public Main() {
        setLayout(new FlowLayout(FlowLayout.LEFT, 10, 10));

    JComboBox<String> comboBox = new JComboBox<>();
    comboBox.setModel(new DefaultComboBoxModel<>(new String[] { "a", "b", "c" }));
    comboBox.addItemListener(e -> {
        System.out.println(e.getItem());
    });
    add(comboBox);
}    

}


Angular 9 Tutorial: Learn to Build a CRUD Angular App Quickly

What's new in Bootstrap 5 and when Bootstrap 5 release date?

Brave, Chrome, Firefox, Opera or Edge: Which is Better and Faster?

How to Build Progressive Web Apps (PWA) using Angular 9

What is new features in Javascript ES2020 ECMAScript 2020

Java Fundamentals: Learn Java for absolute beginners |Simpliv

Java Fundamentals: Learn Java for absolute beginners

Java Essentials : Learn Core Java From Basic to Advance

Learn Java Programming Using Practical Assignments. Start Building Back-end Web Applications Robust Test Automation Frameworks By End Of The Course. Learn More!

Fundamentos de Java: Aprende Java desde cero, sin misterios | Simpliv

Fundamentos de Java: Aprende Java desde cero, sin misterios