AudioProcessorEditor::broughtToFront() never called


#1

Hi,
my AudioProcessorEditor needs to be notified if its Window gains focus. From the documentation I would have expected that AudioProcessorEditor::broughtToFront() would be the correct notification for this. However its never called. focusOfChildComponentChanged() is only called once clicked into one of its child components, but I need a notification when the plugin windows gains focus, without the need of clicking into one of the components inside the window.
What am I missing, or better how can my plugin be notified about its window gaining focus?


#2

The Window is owned by the host… so no notification can be received

Rail


#3

Thanks!

Really: there is no message/runloop notification flying around, that can be caught? Can this be acknowledged by somebody from Roli, please!

Raketa


#4

But why do you need to get that notification, to begin with?


#5

The reason shouldn’t matter, but the plugin is controlling hardware. To support multiple instances the hardware needs to be assigned to one plugin instance: Preferably the one that has the focus.


#6

Doesn’t the AudioProcessorEditor itself work like a normal Juce Component that can get focus? Is there some reason you need to be able to determine the focused status of the host owned window?


#7

Correct, I am not interested in the focus state of the host owned windows; if the Component would gain focus (or could notify by other means) when the surrounding window is brought to front - I would be fine with it.


#8

See: ComboBox ModalCallbackFunction

Which is tangential to this topic.

Rail