openMSX
ImGuiSoundChip.hh
Go to the documentation of this file.
1#ifndef IMGUI_SOUND_CHIP_HH
2#define IMGUI_SOUND_CHIP_HH
3
4#include "ImGuiPart.hh"
5
6#include <map>
7#include <string>
8
9namespace openmsx {
10
11class ImGuiSoundChip final : public ImGuiPart
12{
13public:
15
16 [[nodiscard]] zstring_view iniName() const override { return "sound chip settings"; }
17 void save(ImGuiTextBuffer& buf) override;
18 void loadLine(std::string_view name, zstring_view value) override;
19 void paint(MSXMotherBoard* motherBoard) override;
20
21private:
22 void showChipSettings(MSXMotherBoard& motherBoard);
23 void showChannelSettings(MSXMotherBoard& motherBoard, const std::string& name, bool* enabled);
24
25private:
26 std::map<std::string, bool, std::less<>> channels;
27public:
29
30 static constexpr auto persistentElements = std::tuple{
32 // manually handle "showChannels.xxx"
33 };
34};
35
36} // namespace openmsx
37
38#endif
ImGuiPart(ImGuiManager &manager_)
Definition ImGuiPart.hh:12
void paint(MSXMotherBoard *motherBoard) override
static constexpr auto persistentElements
void save(ImGuiTextBuffer &buf) override
zstring_view iniName() const override
void loadLine(std::string_view name, zstring_view value) override
Like std::string_view, but with the extra guarantee that it refers to a zero-terminated string.
This file implemented 3 utility functions:
Definition Autofire.cc:11