diff options
author | Linus Nielsen Feltzing <linus@haxx.se> | 2004-07-21 13:58:18 +0000 |
---|---|---|
committer | Linus Nielsen Feltzing <linus@haxx.se> | 2004-07-21 13:58:18 +0000 |
commit | d0877aff895d7984a7eeab010e8fdf4968a26215 (patch) | |
tree | 42d3b1fa3bd148c7f882b40cc854041c8396c328 /apps | |
parent | 8057d79202e9eb7a122f67128fbce98f37e912d8 (diff) | |
download | rockbox-d0877aff895d7984a7eeab010e8fdf4968a26215.tar.gz rockbox-d0877aff895d7984a7eeab010e8fdf4968a26215.zip |
splash(): Avoid negative x coordinates if the text doesn't fit
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@4914 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r-- | apps/screens.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/screens.c b/apps/screens.c index be2744f05c..28d9a48869 100644 --- a/apps/screens.c +++ b/apps/screens.c | |||
@@ -773,8 +773,11 @@ void splash(int ticks, /* how long the splash is displayed */ | |||
773 | if(y > (LCD_HEIGHT-h)) | 773 | if(y > (LCD_HEIGHT-h)) |
774 | /* STOP */ | 774 | /* STOP */ |
775 | break; | 775 | break; |
776 | if(center) | 776 | if(center) { |
777 | x = (LCD_WIDTH-widths[line])/2; | 777 | x = (LCD_WIDTH-widths[line])/2; |
778 | if(x < 0) | ||
779 | x = 0; | ||
780 | } | ||
778 | else | 781 | else |
779 | x=0; | 782 | x=0; |
780 | } | 783 | } |