JUCE
JUCE copied to clipboard
add disableDefaultMouseEvents flag in juce_Component
This allows to use only mouseListeners as trigger for mouseEnter(), mouseExit().. callbacks. This is especially useful when doing on a component addMouseListener(this,true) to itself. The default behaviour is that this component will get mouse events from children and from himself through listeners, but will also have the event triggered from internalMouseEnter(), internalMouseExit()... this flags allows to disable the this internal call and only relies on mouseListener, effectively getting only one event for this component as well as its children.