How to add/override a ComboBox listener?

Yet another debug sequence.

image

Here’s where we “catch” that it’s a juce::AudioParameterChoice variable, used with the ComboBox.

This would be the logical place to add a listener to the program’s tree, but we don’t have that in scope at this time. However we can wait until we get back. I added some code to check out what is going on.

So now we have the magicState in context. I can check what the GUITree is and the ValueTree.

The GUITree contains this.

The ValueTree contains all the information about the controls and DSP settings.

image

I’m not sure if this is correct or not. I only replaced slash with colon on the ComboBox item but it may need to be done for everything. What’s weird about this is that the sliders work.

I know I can look for a specific one in the context of my actual program, but eventually I need to figure out how to generalize that so that the Faust code generator can build it. So I’m thinking about scanning through the list to figure out which ones are ComboBoxes, if that is possible.

One other note, I haven’t figured out how to trigger on anything after the application launches, e.g. when I move a slider to change a value, or after loading the XML file (though that shouldn’t be hard). I’d like to use this Tree View Debugger if possible to see what is going on. Obviously it’s a common issue not to be able to see what is going on even with a simple model.