Link to home
Start Free TrialLog in
Avatar of Guilly
Guilly

asked on

Stop Java Events

When a mouse event occur in one JComboBox or other Swing Component, i want to kill the event before do something.

To be more precise, when the JCombo is clicked, droplist is not to be showed.

Thanks
Avatar of adam923
adam923

//i haven't tried this but it just might work :-)

public class NoMouseJComponent extends JComponent{
   protected void processMouseMotionEvent(MouseEvent e){}
}
Avatar of Jim Cakalic
By 'kill the event' do you mean you want to intervene in the event dispatching and prevent other listeners from being notified? Somehow abort the handling of the event?
Avatar of Guilly

ASKER

Edited text of question.
ASKER CERTIFIED SOLUTION
Avatar of Nevyn
Nevyn

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial