ChoicePropertyComponent bug

Right, found some time this evening:


class MainComponent : public juce::Component, public Value::Listener
{
public:
    MainComponent()
    {
        setSize (400, 200);
        addAndMakeVisible (panel);

        // with this line in place and JUCE 6.0.8 the listener is never called when the user changes the combo box
        v = String();

        // but with this next line enabled it will work
        // v = 0;
        v.addListener(this);

        Array<PropertyComponent*> properties;
        properties.add (new ChoicePropertyComponent (v, "Property", { "A", "B" }, { 0, 1 }));
        panel.addProperties (properties);
    }

    void valueChanged(Value &) override
    {
        DBG("working: value is now " + v.getValue().toString());
    }

    ~MainComponent() override = default;

    void paint (juce::Graphics& g) override { g.fillAll (Colours::black); }

    void resized() override { panel.setBounds (getLocalBounds()); }

private:
    Value v;
    PropertyPanel panel;

    JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (MainComponent)
};