Fix the scrollbar boundary checking to prevent the player from freezing on screens that are too small to show the list with the font selected. Correct the M:Robe remote screen height.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20690 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Karl Kurbjun 2009-04-11 22:22:44 +00:00
parent ac0722da74
commit 76328bbfda
2 changed files with 9 additions and 1 deletions

View File

@ -92,6 +92,14 @@ void gui_scrollbar_draw(struct screen * screen, int x, int y,
inner_y = y + 1;
inner_wd = width - 2;
inner_ht = height - 2;
/* Boundary check to make sure that height is reasonable, otherwise nothing
* to do
*/
if(height<2 || width<2)
{
return;
}
if (flags & HORIZONTAL)
inner_len = inner_wd;

View File

@ -91,7 +91,7 @@
/* remote LCD */
#define HAVE_REMOTE_LCD
#define LCD_REMOTE_WIDTH 79
#define LCD_REMOTE_HEIGHT 64
#define LCD_REMOTE_HEIGHT 16
#define LCD_REMOTE_DEPTH 1
/* Remote display colours, for screenshots and sim (0xRRGGBB) */