OXYGENHUB
◆ main openmsx / src / imgui / ImGuiHelp.hh
838 B · C++ · last changed chore(): initial commit 1 month ago source blame history raw
e8555c89 Andy McCall 1
#ifndef IMGUI_HELP_HH
2
#define IMGUI_HELP_HH
3
4
#include "ImGuiPart.hh"
5
6
#include "GLUtil.hh"
7
8
#include <optional>
9
10
namespace openmsx {
11
12
// This used to be an inner class of ImGuiHelp, but for some reason that didn't compile with (some version of) clang???
13
// Moving it outside is a workaround.
14
struct LogoImage {
15
	LogoImage() = default;
16
17
	gl::Texture texture{gl::Null{}};
18
	gl::vec2 size;
19
};
20
21
class ImGuiHelp final : public ImGuiPart
22
{
23
public:
24
	using ImGuiPart::ImGuiPart;
25
26
	void showMenu(MSXMotherBoard* motherBoard) override;
27
	void paint(MSXMotherBoard* motherBoard) override;
28
29
private:
30
	void paintAbout();
31
32
private:
33
	bool showImGuiUserGuide = false;
34
	bool showAboutOpenMSX = false;
35
	bool showAboutImGui = false;
36
	bool showDemoWindow = false;
37
38
	std::optional<LogoImage> logo; // initialized on first use
39
};
40
41
} // namespace openmsx
42
43
#endif