From 93f9e7cbfb3905791feccb4da68f6cc969d1e148 Mon Sep 17 00:00:00 2001 From: Teruaki Kawashima Date: Thu, 11 Feb 2010 10:41:06 +0000 Subject: fix text scrolling handling in do_menu, set_time_screen and time_screen. Don't scroll text in time_screen(). the lines will be redrawn before scrolling statrs, so they don't scroll anyway. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24591 a1c6a512-1295-4272-9138-f99709370657 --- apps/gui/bitmap/list.c | 11 +++++++++++ apps/gui/charcell/list.c | 10 ++++++++++ apps/gui/color_picker.c | 2 +- apps/gui/list.h | 1 + 4 files changed, 23 insertions(+), 1 deletion(-) (limited to 'apps/gui') diff --git a/apps/gui/bitmap/list.c b/apps/gui/bitmap/list.c index 7680c876aa..9e222c1973 100644 --- a/apps/gui/bitmap/list.c +++ b/apps/gui/bitmap/list.c @@ -51,6 +51,17 @@ int gui_list_get_item_offset(struct gui_synclist * gui_list, int item_width, struct viewport *vp); bool list_display_title(struct gui_synclist *list, enum screen_type screen); +void gui_synclist_scroll_stop(struct gui_synclist *lists) +{ + int i; + FOR_NB_SCREENS(i) + { + screens[i].scroll_stop(&list_text[i]); + screens[i].scroll_stop(&title_text[i]); + screens[i].scroll_stop(lists->parent[i]); + } +} + /* Draw the list... internal screen layout: ----------------- diff --git a/apps/gui/charcell/list.c b/apps/gui/charcell/list.c index 2374156f0b..220144c356 100644 --- a/apps/gui/charcell/list.c +++ b/apps/gui/charcell/list.c @@ -39,6 +39,16 @@ #include "sound.h" #include "misc.h" +void gui_synclist_scroll_stop(struct gui_synclist *lists) +{ + int i; + (void)lists; + FOR_NB_SCREENS(i) + { + screens[i].stop_scroll(); + } +} + void list_draw(struct screen *display, struct gui_synclist *gui_list) { int text_pos; diff --git a/apps/gui/color_picker.c b/apps/gui/color_picker.c index 09d861245a..f8caf4d38f 100644 --- a/apps/gui/color_picker.c +++ b/apps/gui/color_picker.c @@ -165,7 +165,7 @@ static void draw_screen(struct screen *display, char *title, viewport_set_defaults(&vp, display->screen_type); display->set_viewport(&vp); - display->clear_display(); + display->clear_viewport(); if (display->depth > 1) { diff --git a/apps/gui/list.h b/apps/gui/list.h index ef16c719c1..1d4a6bd5b4 100644 --- a/apps/gui/list.h +++ b/apps/gui/list.h @@ -160,6 +160,7 @@ extern int gui_synclist_get_nb_items(struct gui_synclist * lists); extern int gui_synclist_get_sel_pos(struct gui_synclist * lists); extern void gui_synclist_draw(struct gui_synclist * lists); +extern void gui_synclist_scroll_stop(struct gui_synclist *lists); extern void gui_synclist_select_item(struct gui_synclist * lists, int item_number); extern void gui_synclist_add_item(struct gui_synclist * lists); -- cgit v1.2.3