summaryrefslogtreecommitdiff
path: root/src/gui/base.h
diff options
context:
space:
mode:
authorday <day@national.shitposting.agency>2026-03-16 16:25:49 +0100
committerday <day@national.shitposting.agency>2026-03-16 16:25:49 +0100
commit7f85c9fc75bd62ac09ea4457d3b17f85988fca66 (patch)
tree15248e42bfafc6bd19e50c9010b701057958ff3a /src/gui/base.h
parent872c39b24ecf4063f785ff3e8b2f940acd8c2d59 (diff)
parent991352b0d2767e6bd1a46f554db4ac9d208c13ad (diff)
Merge remote-tracking branch 'origin/master' into obj
Diffstat (limited to 'src/gui/base.h')
-rw-r--r--src/gui/base.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gui/base.h b/src/gui/base.h
index e62c66a..293de74 100644
--- a/src/gui/base.h
+++ b/src/gui/base.h
@@ -1,6 +1,5 @@
#pragma once
#include "../render/gl_2d.h"
-#include <functional>
// ======================================= [ colorscheme ] ========================================
@@ -46,7 +45,7 @@ extern U8 gui_is_fg_window( struct GUI_BASE* node ); // 1 if pa
// ======================================= [ components ] =========================================
-using GUI_CALLBACK = std::function<void( void* )>;
+using GUI_CALLBACK = FN<void( void* )>;
struct GUI_LIST_ENTRY {
I32 val;
char title[256];
@@ -129,6 +128,8 @@ extern void gui_base_input_fn( void* );
extern void gui_view_draw_fn( void* );
struct GUI_BASE {
+ virtual ~GUI_BASE() = default;
+
I32 x{}, y{};
I32 w{}, h{};
U8 enabled{1};