summaryrefslogtreecommitdiff
path: root/fw/fe310/eos/eve/widget/widgets.h
diff options
context:
space:
mode:
Diffstat (limited to 'fw/fe310/eos/eve/widget/widgets.h')
-rw-r--r--fw/fe310/eos/eve/widget/widgets.h23
1 files changed, 19 insertions, 4 deletions
diff --git a/fw/fe310/eos/eve/widget/widgets.h b/fw/fe310/eos/eve/widget/widgets.h
index 542b350..c33fc03 100644
--- a/fw/fe310/eos/eve/widget/widgets.h
+++ b/fw/fe310/eos/eve/widget/widgets.h
@@ -1,4 +1,3 @@
-#include "font.h"
#include "label.h"
#include "widget.h"
@@ -9,17 +8,33 @@
#include "textw.h"
#include "selectw.h"
-typedef union EVEWidgetSpec {
+typedef union EVEWidgetSpecT {
EVEFreeSpec free;
EVESpacerSpec spacer;
EVEPageSpec page;
EVEStrSpec str;
EVETextSpec text;
EVESelectSpec select;
+} EVEWidgetSpecT;
+
+typedef struct EVELabelSpec {
+ EVERect g;
+ EVEFont *font;
+ char *title;
+} APPLabelSpec;
+
+typedef struct EVEWidgetSpec {
+ APPLabelSpec label;
+ struct {
+ EVERect g;
+ EVEFont *font;
+ EVEWidgetSpecT spec;
+ uint8_t type;
+ } widget;
} EVEWidgetSpec;
-typedef int (*eve_widget_create_t) (EVEWidget *, EVERect *g, EVEWidgetSpec *);
+typedef int (*eve_widget_create_t) (EVEWidget *, EVERect *g, EVEFont *, EVEWidgetSpecT *);
typedef void (*eve_widget_destroy_t) (EVEWidget *);
-int eve_widget_create(EVEWidget *widget, uint8_t type, EVERect *g, EVEWidgetSpec *spec);
+int eve_widget_create(EVEWidget *widget, uint8_t type, EVERect *g, EVEFont *font, EVEWidgetSpecT *spec);
void eve_widget_destroy(EVEWidget *widget);