From daa87d92b3df433578e53284a8c88083e24f8623 Mon Sep 17 00:00:00 2001 From: Uros Majstorovic Date: Sat, 27 Mar 2021 22:08:31 +0100 Subject: form/app cleanup; scroll infrastructure --- fw/fe310/eos/eve/widget/pagew.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) (limited to 'fw/fe310/eos/eve/widget/pagew.c') diff --git a/fw/fe310/eos/eve/widget/pagew.c b/fw/fe310/eos/eve/widget/pagew.c index 4f59d2e..bd7819f 100644 --- a/fw/fe310/eos/eve/widget/pagew.c +++ b/fw/fe310/eos/eve/widget/pagew.c @@ -25,15 +25,9 @@ void eve_pagew_init(EVEPageWidget *widget, EVERect *g, EVEPage *page, EVEFont *f memset(widget, 0, sizeof(EVEPageWidget)); eve_widget_init(_widget, EVE_WIDGET_TYPE_PAGE, g, page, eve_pagew_draw, eve_pagew_touch, NULL); - eve_pagew_update(widget, font, title, constructor); -} - -void eve_pagew_update(EVEPageWidget *widget, EVEFont *font, char *title, eve_view_constructor_t constructor) { - EVEWidget *_widget = &widget->w; - - if (font) widget->font = font; - if (title) widget->title = title; - if (constructor) widget->constructor = constructor; + widget->font = font; + widget->title = title; + widget->constructor = constructor; if (_widget->g.h == 0) _widget->g.h = eve_font_h(widget->font); } @@ -41,7 +35,7 @@ uint8_t eve_pagew_draw(EVEWidget *_widget, uint8_t tag0) { EVEPageWidget *widget = (EVEPageWidget *)_widget; _widget->tag0 = tag0; - if (tag0 != EVE_TAG_NOTAG) { + if (tag0 != EVE_NOTAG) { eve_cmd_dl(TAG(tag0)); tag0++; } -- cgit v1.2.3