Oxygen Engine
Modern C++ 3D Engine using OpenGL
Loading...
Searching...
No Matches
button.h
1
#ifndef OE_GUI_COMPONENT_BUTTON_H
2
#define OE_GUI_COMPONENT_BUTTON_H
3
4
#include "../component.h"
5
#include <functional>
6
#include <glm/vec2.hpp>
7
8
namespace
oe::gui::component
9
{
10
class
Button
:
public
Component
11
{
12
public
:
13
Button
(
const
std::string& label, std::function<
void
()> on_click);
14
15
Button
* setLabel(
const
std::string& label) { _label = label;
return
this
; }
16
17
void
generate();
18
private
:
19
std::string _label;
20
std::function<void()> _on_click;
21
};
22
}
23
#endif
oe::gui::Component
Definition
component.h:22
oe::gui::component::Button
Definition
button.h:11
oe::gui::component
UI components.
Definition
component.h:15
OxygenEngine
gui
component
button.h
Generated by
1.9.8