i tried to search on the forum if this issue has already been posted but i can’t find something similar.
I have a fairly complex setup of nested components that are all interactable in their own way.
I need now to be able to add a a mouselistener to a child component from a parent component (the parent component being the listener) and be able to retrieve a pointer to the object on which i put the “addMouseListener” callback in the “mouseDown” or “mouseDrag” callbacks.
Currently, the accessible members are “originalComponent” and “eventComponent”, but none of them seem to represent the object that i wanted to listen, because my listened child component contains components as well and the eventComponent and originalComponent properties point to those component that originally cast the event.
It would be great to get a “listenedComponent” property that represent the object on which we put the mouselistener.
I imagine that the mouseEvent is currently being passed from child to parent, this property “listenedComponent” would be altered at each level to reflect the current component invoking the callback on its listeners.
It actually may be a general behavior of event dispatchers to be able to pass their pointer during the callbacks.
Am i making sense ?