diff options
| author | Thomas Martitz <kugel@rockbox.org> | 2013-04-03 16:33:23 +0200 |
|---|---|---|
| committer | Thomas Martitz <kugel@rockbox.org> | 2013-12-14 23:11:30 +0100 |
| commit | 1c5d0b41eebdb4f8c627b1a0e5f7b699f0b08fb8 (patch) | |
| tree | 3ec44a4e6cfe4bfaab689e765ef3546d8dac730d /firmware/drivers | |
| parent | 47c8d3c14d8fdaf4749ef5e0380fb0c52140b5fb (diff) | |
| download | rockbox-1c5d0b41eebdb4f8c627b1a0e5f7b699f0b08fb8.zip rockbox-1c5d0b41eebdb4f8c627b1a0e5f7b699f0b08fb8.tar.gz rockbox-1c5d0b41eebdb4f8c627b1a0e5f7b699f0b08fb8.tar.bz2 rockbox-1c5d0b41eebdb4f8c627b1a0e5f7b699f0b08fb8.tar.xz | |
scroll_engine: Rename scroll_stop* functions to be more consistent with the lcd api.
Change-Id: I8ada10b96bfb628cca0331689e8b936ae47c7e1c
Diffstat (limited to 'firmware/drivers')
| -rw-r--r-- | firmware/drivers/lcd-16bit-common.c | 8 | ||||
| -rw-r--r-- | firmware/drivers/lcd-1bit-vert.c | 2 | ||||
| -rw-r--r-- | firmware/drivers/lcd-bitmap-common.c | 10 | ||||
| -rw-r--r-- | firmware/drivers/lcd-charcell.c | 6 |
4 files changed, 14 insertions, 12 deletions
diff --git a/firmware/drivers/lcd-16bit-common.c b/firmware/drivers/lcd-16bit-common.c index f8673ec..dffc1cf 100644 --- a/firmware/drivers/lcd-16bit-common.c +++ b/firmware/drivers/lcd-16bit-common.c @@ -144,13 +144,9 @@ void lcd_clear_viewport(void) } if (current_vp == &default_vp) - { - lcd_scroll_info.lines = 0; - } + lcd_scroll_stop(); else - { - lcd_scroll_stop(current_vp); - } + lcd_scroll_stop_viewport(current_vp); } /*** parameter handling ***/ diff --git a/firmware/drivers/lcd-1bit-vert.c b/firmware/drivers/lcd-1bit-vert.c index 5cacf0a..668c685 100644 --- a/firmware/drivers/lcd-1bit-vert.c +++ b/firmware/drivers/lcd-1bit-vert.c @@ -226,7 +226,7 @@ void LCDFN(clear_viewport)(void) current_vp->drawmode = oldmode; - LCDFN(scroll_stop)(current_vp); + LCDFN(scroll_stop_viewport)(current_vp); } } diff --git a/firmware/drivers/lcd-bitmap-common.c b/firmware/drivers/lcd-bitmap-common.c index a17ac51..10a567e 100644 --- a/firmware/drivers/lcd-bitmap-common.c +++ b/firmware/drivers/lcd-bitmap-common.c @@ -178,6 +178,12 @@ void LCDFN(set_viewport)(struct viewport* vp) #endif } +struct viewport *LCDFN(get_viewport)(bool *is_default) +{ + *is_default = (current_vp == &default_vp); + return current_vp; +} + void LCDFN(update_viewport)(void) { LCDFN(update_rect)(current_vp->x, current_vp->y, @@ -405,7 +411,7 @@ void LCDFN(puts_style_xyoffset)(int x, int y, const unsigned char *str, int style, int x_offset, int y_offset) { int xpos, ypos, h; - LCDFN(scroll_stop_line)(current_vp, y); + LCDFN(scroll_stop_viewport_line)(current_vp, y); if(!str) return; @@ -491,7 +497,7 @@ void LCDFN(puts_scroll_style_xyoffset)(int x, int y, const unsigned char *string if (restart) { /* remove any previously scrolling line at the same location */ - LCDFN(scroll_stop_line)(current_vp, y); + LCDFN(scroll_stop_viewport_line)(current_vp, y); if (LCDFN(scroll_info).lines >= LCDM(SCROLLABLE_LINES)) return; LCDFN(puts_style_xyoffset)(x, y, string, style, x_offset, y_offset); diff --git a/firmware/drivers/lcd-charcell.c b/firmware/drivers/lcd-charcell.c index b59b270..bdd02de 100644 --- a/firmware/drivers/lcd-charcell.c +++ b/firmware/drivers/lcd-charcell.c @@ -377,7 +377,7 @@ void lcd_clear_viewport(void) for (y = 0; y < current_vp->height; y++) lcd_putxchar(x, y, xspace); - lcd_scroll_stop(current_vp); + lcd_scroll_stop_viewport(current_vp); } } @@ -486,7 +486,7 @@ void lcd_puts_offset(int x, int y, const unsigned char *str, int offset) return; /* make sure scrolling is turned off on the line we are updating */ - lcd_scroll_stop_line(current_vp, y); + lcd_scroll_stop_viewport_line(current_vp, y); x = lcd_putsxyofs(x, y, offset, str); while (x < current_vp->width) @@ -509,7 +509,7 @@ void lcd_puts_scroll_offset(int x, int y, const unsigned char *string, return; /* remove any previously scrolling line at the same location */ - lcd_scroll_stop_line(current_vp, y); + lcd_scroll_stop_viewport_line(current_vp, y); if (lcd_scroll_info.lines >= LCD_SCROLLABLE_LINES) return; |