1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 06:57:46 +00:00

Piano: Create controller widgets for processor parameters

These widgets attach to a processor parameter and keep the two sides in
sync. They will become very useful for smart processor interfaces.
This commit is contained in:
kleines Filmröllchen 2021-09-28 18:00:41 +02:00 committed by Linus Groh
parent 481f7d6afa
commit 8f8ae5eb53
6 changed files with 90 additions and 8 deletions

View file

@ -1,24 +0,0 @@
/*
* Copyright (c) 2021, kleines Filmröllchen <malu.bertsch@gmail.com>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include <LibDSP/ProcessorParameter.h>
#include <LibGUI/Label.h>
#include <LibGUI/Slider.h>
#include <LibGfx/Orientation.h>
class ProcessorParameterSlider : public GUI::Slider {
C_OBJECT(ProcessorParameterSlider);
public:
ProcessorParameterSlider(Orientation, LibDSP::ProcessorRangeParameter&, RefPtr<GUI::Label>);
RefPtr<GUI::Label> value_label() { return m_value_label; }
private:
LibDSP::ProcessorRangeParameter& m_parameter;
RefPtr<GUI::Label> m_value_label;
};