MCPcopy Create free account
hub / github.com/andrewreeman/SpectralSuite / ScaleSlider

Method ScaleSlider

FrequencyShift/Source/ScaleSlider.cpp:3–15  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1#include "ScaleSlider.h"
2
3ScaleSlider::ScaleSlider(std::shared_ptr<FrequencyShiftPluginParameters> valueTreeState, Colour textColour, int textBoxHeight)
4{
5 scaleSlider.setSliderStyle(Slider::LinearHorizontal);
6 scaleSlider.setTextBoxStyle(Slider::TextEntryBoxPosition::TextBoxAbove, false, 100, textBoxHeight);
7 scaleSlider.setColour(Slider::ColourIds::textBoxTextColourId, textColour);
8 scaleSlider.setTooltip("How much to scale the frequencies by");
9 scaleAttachment.reset(valueTreeState->createSliderAttachment("scale", scaleSlider));
10 addAndMakeVisible(scaleSlider);
11
12 scaleLabel.setText("Scale", NotificationType::dontSendNotification);
13 scaleLabel.attachToComponent(&scaleSlider, false);
14 scaleLabel.setColour(Label::ColourIds::textColourId, textColour);
15}
16
17ScaleSlider::~ScaleSlider()= default;
18

Callers

nothing calls this directly

Calls 2

resetMethod · 0.80

Tested by

no test coverage detected