diff options
| author | Karl Kurbjun <kkurbjun@gmail.com> | 2009-11-07 18:48:35 +0000 |
|---|---|---|
| committer | Karl Kurbjun <kkurbjun@gmail.com> | 2009-11-07 18:48:35 +0000 |
| commit | dcc52f581cdd503e37f78fe917532b759077845f (patch) | |
| tree | 8e2ee9d18ae8387dd4b96441fa27b25440a6a999 | |
| parent | 765ff0130ab58c67e82a2ed17c64c577c6434d57 (diff) | |
| download | rockbox-dcc52f581cdd503e37f78fe917532b759077845f.zip rockbox-dcc52f581cdd503e37f78fe917532b759077845f.tar.gz rockbox-dcc52f581cdd503e37f78fe917532b759077845f.tar.bz2 rockbox-dcc52f581cdd503e37f78fe917532b759077845f.tar.xz | |
Fix two width calculations
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23552 a1c6a512-1295-4272-9138-f99709370657
| -rw-r--r-- | firmware/drivers/lcd-1bit-vert.c | 3 | ||||
| -rw-r--r-- | firmware/drivers/lcd-2bit-vi.c | 3 |
2 files changed, 2 insertions, 4 deletions
diff --git a/firmware/drivers/lcd-1bit-vert.c b/firmware/drivers/lcd-1bit-vert.c index ae7cddb..0518616 100644 --- a/firmware/drivers/lcd-1bit-vert.c +++ b/firmware/drivers/lcd-1bit-vert.c @@ -404,11 +404,10 @@ void LCDFN(hline)(int x1, int x2, int y) /* adjust to viewport */ x1 += current_vp->x; + x2 += current_vp->x; y += current_vp->y; #if defined(HAVE_VIEWPORT_CLIP) - x2 += current_vp->x; - /********************* Viewport on screen clipping ********************/ /* nothing to draw? */ if (((unsigned)y >= (unsigned) LCDM(HEIGHT)) || (x1 >= LCDM(WIDTH)) diff --git a/firmware/drivers/lcd-2bit-vi.c b/firmware/drivers/lcd-2bit-vi.c index 5edb588..853cd88 100644 --- a/firmware/drivers/lcd-2bit-vi.c +++ b/firmware/drivers/lcd-2bit-vi.c @@ -594,11 +594,10 @@ void LCDFN(hline)(int x1, int x2, int y) /* adjust x1 and y to viewport */ x1 += current_vp->x; + x2 += current_vp->x; y += current_vp->y; #if defined(HAVE_VIEWPORT_CLIP) - x2 += current_vp->x; - /********************* Viewport on screen clipping ********************/ /* nothing to draw? */ if (((unsigned)y >= (unsigned) LCDM(HEIGHT)) || (x1 >= LCDM(WIDTH)) |