Deluge Firmware 1.3.0
Build date: 2025.04.16
Loading...
Searching...
No Matches
engine_select.h
1
2/*
3 * Copyright © 2015-2023 Synthstrom Audible Limited
4 *
5 * This file is part of The Synthstrom Audible Deluge Firmware.
6 *
7 * The Synthstrom Audible Deluge Firmware is free software: you can redistribute it and/or modify it under the
8 * terms of the GNU General Public License as published by the Free Software Foundation,
9 * either version 3 of the License, or (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
12 * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13 * See the GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License along with this program.
16 * If not, see <https://www.gnu.org/licenses/>.
17 */
18
19#pragma once
20
21#include "dsp/dx/dx7note.h"
22#include "gui/menu_item/menu_item.h"
23
24namespace deluge::gui::menu_item {
25
26class DxEngineSelect final : public MenuItem {
27public:
28 using MenuItem::MenuItem;
29 DxEngineSelect(l10n::String newName) : MenuItem(newName) {}
30
31 void beginSession(MenuItem* navigatedBackwardFrom) override;
32 bool tryLoad(const char* path);
33 void drawPixelsForOled() override;
34 void readValueAgain() final;
35 void selectEncoderAction(int32_t offset) final;
36 MenuItem* selectButtonPress() final;
37 void drawValue();
38
39 int32_t currentValue = 0;
40 DxPatch* patch;
41};
42
43extern DxEngineSelect dxEngineSelect;
44} // namespace deluge::gui::menu_item
Definition dx7note.h:38
Definition engine_select.h:26
void beginSession(MenuItem *navigatedBackwardFrom) override
Begin an editing session with this menu item.
Definition engine_select.cpp:33
MenuItem * selectButtonPress() final
Handle a select button press.
Definition engine_select.cpp:82
void selectEncoderAction(int32_t offset) final
Handle select encoder movement.
Definition engine_select.cpp:60
void readValueAgain() final
Re-read the value from the system and redraw the display to match.
Definition engine_select.cpp:37
void drawPixelsForOled() override
Paints the pixels below the standard title block.
Definition engine_select.cpp:45