From d6a8caa7e27dd08180f6a5a45a080c2e4cfc1fe4 Mon Sep 17 00:00:00 2001 From: Uros Majstorovic Date: Wed, 26 Aug 2020 02:07:48 +0200 Subject: kbdwin removed; stack and contructor moved to view --- fw/fe310/eos/eve/screen/window.h | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) (limited to 'fw/fe310/eos/eve/screen/window.h') diff --git a/fw/fe310/eos/eve/screen/window.h b/fw/fe310/eos/eve/screen/window.h index 7f14f18..89c83eb 100644 --- a/fw/fe310/eos/eve/screen/window.h +++ b/fw/fe310/eos/eve/screen/window.h @@ -3,19 +3,11 @@ struct EVEView; struct EVEWindow; -typedef int (*eve_view_touch_t) (struct EVEView *, uint8_t, int); -typedef uint8_t (*eve_view_draw_t) (struct EVEView *, uint8_t); - -typedef struct EVEView { - eve_view_touch_t touch; - eve_view_draw_t draw; - struct EVEWindow *window; -} EVEView; - typedef struct EVEWindow { EVERect g; - EVEView *view; EVEScreen *screen; + char *name; + struct EVEView *view; struct EVEWindow *next; struct EVEWindow *prev; uint32_t color_bg; @@ -23,7 +15,7 @@ typedef struct EVEWindow { uint8_t tag; } EVEWindow; -void eve_window_init(EVEWindow *window, EVERect *g, EVEView *view, EVEScreen *screen); +void eve_window_init(EVEWindow *window, EVERect *g, EVEScreen *screen, char *name); void eve_window_set_color_bg(EVEWindow *window, uint8_t r, uint8_t g, uint8_t b); void eve_window_set_color_fg(EVEWindow *window, uint8_t r, uint8_t g, uint8_t b); @@ -34,3 +26,4 @@ void eve_window_append(EVEWindow *window); void eve_window_insert_above(EVEWindow *window, EVEWindow *win_prev); void eve_window_insert_below(EVEWindow *window, EVEWindow *win_next); void eve_window_remove(EVEWindow *window); +EVEWindow *eve_window_get(EVEScreen *screen, char *name); -- cgit v1.2.3