seebk
February 26, 2019, 12:03pm
1
The FileSearchPathListComponent has a fixed colour for the included listbox. This makes it difficult to use the component with a custom LookAndFeel.
Any chance that you remove the setting of the listbox colors and let it pickup the default ones from the global LookAndFeel?
FileSearchPathListComponent::FileSearchPathListComponent()
: addButton ("+"),
removeButton ("-"),
changeButton (TRANS ("change...")),
upButton ({}, DrawableButton::ImageOnButtonBackground),
downButton ({}, DrawableButton::ImageOnButtonBackground)
{
listBox.setModel (this);
addAndMakeVisible (listBox);
listBox.setColour (ListBox::backgroundColourId, Colours::black.withAlpha (0.02f));
listBox.setColour (ListBox::outlineColourId, Colours::black.withAlpha (0.1f));
listBox.setOutlineThickness (1);
addAndMakeVisible (addButton);
addButton.onClick = [this] { addPath(); };
addButton.setConnectedEdges (Button::ConnectedOnLeft | Button::ConnectedOnRight | Button::ConnectedOnBottom | Button::ConnectedOnTop);
addAndMakeVisible (removeButton);
removeButton.onClick = [this] { deleteSelected(); };
removeButton.setConnectedEdges (Button::ConnectedOnLeft | Button::ConnectedOnRight | Button::ConnectedOnBottom | Button::ConnectedOnTop);