summaryrefslogtreecommitdiffstats
path: root/apps/screen_access.c
diff options
context:
space:
mode:
authorJens Arnold <amiconn@rockbox.org>2007-04-16 23:55:19 +0000
committerJens Arnold <amiconn@rockbox.org>2007-04-16 23:55:19 +0000
commit539c513fe60f9277105edb1916685594338ac671 (patch)
treeba0026211b5d36658259e8c9bdb33e442263be2e /apps/screen_access.c
parente346a4cb296f291296a8a6dfbed7eb0a8b699af1 (diff)
downloadrockbox-539c513fe60f9277105edb1916685594338ac671.tar.gz
rockbox-539c513fe60f9277105edb1916685594338ac671.tar.bz2
rockbox-539c513fe60f9277105edb1916685594338ac671.zip
Temporary fix for remote bitmap functions in the multi-screen API. Fixed icon.c to use this. Also fixed crash due to missing assignment of lcd_bitmap[_part] for monochrome main LCDs.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13187 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/screen_access.c')
-rw-r--r--apps/screen_access.c26
1 files changed, 17 insertions, 9 deletions
diff --git a/apps/screen_access.c b/apps/screen_access.c
index 03687a3dbb..a642b65d20 100644
--- a/apps/screen_access.c
+++ b/apps/screen_access.c
@@ -52,7 +52,15 @@ void screen_init(struct screen * screen, enum screen_type screen_type)
screen->setfont(FONT_UI);
screen->mono_bitmap=&lcd_remote_mono_bitmap;
screen->mono_bitmap_part=&lcd_remote_mono_bitmap_part;
+ screen->bitmap=(screen_bitmap_func*)&lcd_remote_bitmap;
+ screen->bitmap_part=(screen_bitmap_part_func*)&lcd_remote_bitmap_part;
screen->set_drawmode=&lcd_remote_set_drawmode;
+#if LCD_DEPTH <= 2
+ /* No transparency yet for grayscale and mono lcd */
+ screen->transparent_bitmap=(screen_bitmap_func*)&lcd_remote_bitmap;
+ screen->transparent_bitmap_part=(screen_bitmap_part_func*)&lcd_remote_bitmap_part;
+ /* No colour remotes yet */
+#endif
#if LCD_REMOTE_DEPTH > 1
#if defined(HAVE_LCD_COLOR)
screen->color_to_native=&lcd_remote_color_to_native;
@@ -122,17 +130,17 @@ void screen_init(struct screen * screen, enum screen_type screen_type)
screen->mono_bitmap=&lcd_mono_bitmap;
screen->mono_bitmap_part=&lcd_mono_bitmap_part;
screen->set_drawmode=&lcd_set_drawmode;
-#if LCD_DEPTH > 1
- screen->bitmap=&lcd_bitmap;
- screen->bitmap_part=&lcd_bitmap_part;
-#if LCD_DEPTH == 2
- /* No transparency yet for grayscale lcd */
- screen->transparent_bitmap=&lcd_bitmap;
- screen->transparent_bitmap_part=&lcd_bitmap_part;
+ screen->bitmap=(screen_bitmap_func*)&lcd_bitmap;
+ screen->bitmap_part=(screen_bitmap_part_func*)&lcd_bitmap_part;
+#if LCD_DEPTH <= 2
+ /* No transparency yet for grayscale and mono lcd */
+ screen->transparent_bitmap=(screen_bitmap_func*)&lcd_bitmap;
+ screen->transparent_bitmap_part=(screen_bitmap_part_func*)&lcd_bitmap_part;
#else
- screen->transparent_bitmap=&lcd_bitmap_transparent;
- screen->transparent_bitmap_part=&lcd_bitmap_transparent_part;
+ screen->transparent_bitmap=(screen_bitmap_func*)&lcd_bitmap_transparent;
+ screen->transparent_bitmap_part=(screen_bitmap_part_func*)&lcd_bitmap_transparent_part;
#endif
+#if LCD_DEPTH > 1
#if defined(HAVE_LCD_COLOR) && defined(LCD_REMOTE_DEPTH) && LCD_REMOTE_DEPTH > 1
screen->color_to_native=&lcd_color_to_native;
#endif