Hi all out there!
I hope it is not a silly question but i thing I don’t get the broad/listen concept.
I have looked into the demo to see how it works but.
I am trying to use the boadcaster/listener methods in the following way…
I have got a main components which holds several different components (comms_panel, info_panel, buttons_panel).
For example if I press i button at buttons_panel, its name appears at info_panel and comms_panel.
I have thought of using the broadcaster/listener classes to keep a component informed about events in other components.
The juce demo use ONE main listener to listen to SEVERAL broadcasters(events from child components -> balls in the demo)
In my case I want SEVERAL listeners to listen to ONE broadcaster…so for example I press a button in a component, its name appear at the listeners. I can do it although I am not really sure if this is the concepts.
also changeListenerCallback(ChangeBroadcaster* source) receives the source, so if broadcasters belong to the listener is easy to write: if(source==child_A) or whatever, but when components are defined at different files and they are added in a main component, i don’t know how to find out who the trigger was.
Any advise?I would like to be sure of how to use it before writing a lot useless code
Thanks in advance