mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-12-09 05:05:20 -05:00
[BugFix] scroll_stop_viewport_rect off by 1
when you do the math yes there are 8 slots between y = 16 and h = 8 and y = 24 16 17 18 19 20 21 22 23 1 2 3 4 5 6 7 8 but 16 + 8 = 24 ah an off by 1 error Change-Id: I7b0625da1351910b27e5526c0a9f969c067758c6
This commit is contained in:
parent
857267e9df
commit
8347203dc6
1 changed files with 2 additions and 2 deletions
|
|
@ -64,8 +64,8 @@ void LCDFN(scroll_stop_viewport_rect)(const struct viewport *vp, int x, int y, i
|
|||
struct scrollinfo *s = &LCDFN(scroll_info).scroll[i];
|
||||
/* check if the specified area crosses the viewport in some way */
|
||||
if (s->vp == vp
|
||||
&& (x < (s->x+s->width) && (x+width) >= s->x)
|
||||
&& (y < (s->y+s->height) && (y+height) >= s->y))
|
||||
&& (x < (s->x+s->width) && (x+width) > s->x)
|
||||
&& (y < (s->y+s->height) && (y+height) > s->y))
|
||||
{
|
||||
/* inform scroller about end of scrolling */
|
||||
s->line = NULL;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue