opynsim
Unofficial C++ Documentation
Loading...
Searching...
No Matches
icon_with_menu.h
Go to the documentation of this file.
1#pragma once
2
3#include <liboscar/ui/icon.h>
6
7#include <functional>
8#include <string>
9
10namespace osc
11{
13 public:
14 explicit IconWithMenu(
15 Icon icon,
16 CStringView title,
17 CStringView description,
18 std::function<bool()> content_renderer
19 );
20
21 Vector2 dimensions() const { return icon_without_menu_.dimensions(); }
22 bool on_draw();
23 private:
24 IconWithoutMenu icon_without_menu_;
25 std::string context_menu_id_;
26 std::function<bool()> content_renderer_;
27 };
28}
Definition c_string_view.h:12
Definition icon_with_menu.h:12
IconWithMenu(Icon icon, CStringView title, CStringView description, std::function< bool()> content_renderer)
Vector2 dimensions() const
Definition icon_with_menu.h:21
Definition icon_without_menu.h:11
Vector2 dimensions() const
Definition icon.h:11
Definition custom_decoration_generator.h:5
constexpr U to(T &&value)
Definition conversion.h:56