From fb2925bf6af5dcca06c8a4262d36b800100e5f4b Mon Sep 17 00:00:00 2001 From: bluebrother Date: Sat, 4 Jun 2011 18:55:51 +0000 Subject: [PATCH] Center Rockbox logo when smaller than the screen size. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29954 a1c6a512-1295-4272-9138-f99709370657 --- apps/misc.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/apps/misc.c b/apps/misc.c index 5a99db2d8..12aaf08c7 100644 --- a/apps/misc.c +++ b/apps/misc.c @@ -695,9 +695,11 @@ int show_logo( void ) lcd_getstringsize((unsigned char *)"A", &font_w, &font_h); lcd_putsxy((LCD_WIDTH/2) - ((strlen(version)*font_w)/2), 0, (unsigned char *)version); - lcd_bitmap(rockboxlogo, 0, 16, BMPWIDTH_rockboxlogo, BMPHEIGHT_rockboxlogo); + lcd_bitmap(rockboxlogo, (LCD_WIDTH - BMPWIDTH_rockboxlogo) / 2, 16, + BMPWIDTH_rockboxlogo, BMPHEIGHT_rockboxlogo); #else - lcd_bitmap(rockboxlogo, 0, 10, BMPWIDTH_rockboxlogo, BMPHEIGHT_rockboxlogo); + lcd_bitmap(rockboxlogo, (LCD_WIDTH - BMPWIDTH_rockboxlogo) / 2, 10, + BMPWIDTH_rockboxlogo, BMPHEIGHT_rockboxlogo); lcd_setfont(FONT_SYSFIXED); lcd_getstringsize((unsigned char *)"A", &font_w, &font_h); lcd_putsxy((LCD_WIDTH/2) - ((strlen(version)*font_w)/2), -- 2.11.4.GIT