summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJens Arnold <amiconn@rockbox.org>2005-06-24 23:06:06 +0000
committerJens Arnold <amiconn@rockbox.org>2005-06-24 23:06:06 +0000
commit24a1f94cd7cc50fbda6689d33c5d2dbcf123dab5 (patch)
tree1be06cf64f839ea856f28122e0bcd3d8c6182c8c
parent22c1a8e1d97c3fd078067f4e1d2444b3499bd869 (diff)
Fixed yellow FM builds, and changed the function type names according to the rockbox coding style.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@6858 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/recorder/radio.c8
-rw-r--r--firmware/drivers/lcd-h100.c14
-rw-r--r--firmware/drivers/lcd-recorder.c14
-rw-r--r--firmware/export/lcd.h4
4 files changed, 22 insertions, 18 deletions
diff --git a/apps/recorder/radio.c b/apps/recorder/radio.c
index 93e2022caf..5dbe9478d6 100644
--- a/apps/recorder/radio.c
+++ b/apps/recorder/radio.c
@@ -443,7 +443,9 @@ bool radio_screen(void)
/* Only display the peak meter when not recording */
if(!audio_status())
{
- lcd_clearrect(0, 8 + fh*(top_of_screen + 3), LCD_WIDTH, fh);
+ lcd_set_drawmode(DRMODE_SOLID|DRMODE_INVERSEVID);
+ lcd_fillrect(0, 8 + fh*(top_of_screen + 3), LCD_WIDTH, fh);
+ lcd_set_drawmode(DRMODE_SOLID);
peak_meter_draw(0, 8 + fh*(top_of_screen + 3), LCD_WIDTH, fh);
lcd_update_rect(0, 8 + fh*(top_of_screen + 3), LCD_WIDTH, fh);
}
@@ -477,7 +479,9 @@ bool radio_screen(void)
}
else
{
- lcd_clearrect(0, 8 + top_of_screen*fh, LCD_WIDTH, fh);
+ lcd_set_drawmode(DRMODE_SOLID|DRMODE_INVERSEVID);
+ lcd_fillrect(0, 8 + top_of_screen*fh, LCD_WIDTH, fh);
+ lcd_set_drawmode(DRMODE_SOLID);
}
freq = curr_freq / 100000;
diff --git a/firmware/drivers/lcd-h100.c b/firmware/drivers/lcd-h100.c
index 2b0326eb3b..db2aba8673 100644
--- a/firmware/drivers/lcd-h100.c
+++ b/firmware/drivers/lcd-h100.c
@@ -331,7 +331,7 @@ static void nopixel(int x, int y)
(void)y;
}
-tLCDPixelFunc* pixelfunc[8] = {flippixel, nopixel, setpixel, setpixel,
+lcd_pixelfunc_type* pixelfunc[8] = {flippixel, nopixel, setpixel, setpixel,
nopixel, clearpixel, nopixel, clearpixel};
static void flipblock(unsigned char *address, unsigned mask, unsigned bits)
@@ -354,7 +354,7 @@ static void solidblock(unsigned char *address, unsigned mask, unsigned bits)
*address = (*address & ~mask) | (bits & mask);
}
-tLCDBlockFunc* blockfunc[4] = {flipblock, bgblock, fgblock, solidblock};
+lcd_blockfunc_type* blockfunc[4] = {flipblock, bgblock, fgblock, solidblock};
/*** drawing functions ***/
@@ -384,7 +384,7 @@ void lcd_drawline(int x1, int y1, int x2, int y2)
int d, dinc1, dinc2;
int x, xinc1, xinc2;
int y, yinc1, yinc2;
- tLCDPixelFunc *pfunc = pixelfunc[drawmode];
+ lcd_pixelfunc_type *pfunc = pixelfunc[drawmode];
deltax = abs(x2 - x1);
deltay = abs(y2 - y1);
@@ -452,7 +452,7 @@ void lcd_hline(int x1, int x2, int y)
int x;
unsigned char *dst;
unsigned char mask, bits;
- tLCDBlockFunc *bfunc;
+ lcd_blockfunc_type *bfunc;
/* direction flip */
if (x2 < x1)
@@ -487,7 +487,7 @@ void lcd_vline(int x, int y1, int y2)
int ny;
unsigned char *dst;
unsigned char mask_top, mask_bottom, bits;
- tLCDBlockFunc *bfunc;
+ lcd_blockfunc_type *bfunc;
/* direction flip */
if (y2 < y1)
@@ -547,7 +547,7 @@ void lcd_drawrect(int x, int y, int width, int height)
}
/* helper function for lcd_fillrect() */
-static void fillrow(tLCDBlockFunc *bfunc, unsigned char *address,
+static void fillrow(lcd_blockfunc_type *bfunc, unsigned char *address,
int width, unsigned mask, unsigned bits)
{
int i;
@@ -562,7 +562,7 @@ void lcd_fillrect(int x, int y, int width, int height)
int ny;
unsigned char *dst;
unsigned char mask_top, mask_bottom, bits;
- tLCDBlockFunc *bfunc;
+ lcd_blockfunc_type *bfunc;
bool fillopt = (drawmode & DRMODE_INVERSEVID) ?
(drawmode & DRMODE_BG) : (drawmode & DRMODE_FG);
diff --git a/firmware/drivers/lcd-recorder.c b/firmware/drivers/lcd-recorder.c
index 16a47f28bf..a83f58e35d 100644
--- a/firmware/drivers/lcd-recorder.c
+++ b/firmware/drivers/lcd-recorder.c
@@ -390,7 +390,7 @@ static void nopixel(int x, int y)
(void)y;
}
-tLCDPixelFunc* pixelfunc[8] = {flippixel, nopixel, setpixel, setpixel,
+lcd_pixelfunc_type* pixelfunc[8] = {flippixel, nopixel, setpixel, setpixel,
nopixel, clearpixel, nopixel, clearpixel};
static void flipblock(unsigned char *address, unsigned mask, unsigned bits)
@@ -413,7 +413,7 @@ static void solidblock(unsigned char *address, unsigned mask, unsigned bits)
*address = (*address & ~mask) | (bits & mask);
}
-tLCDBlockFunc* blockfunc[4] = {flipblock, bgblock, fgblock, solidblock};
+lcd_blockfunc_type* blockfunc[4] = {flipblock, bgblock, fgblock, solidblock};
/*** drawing functions ***/
@@ -443,7 +443,7 @@ void lcd_drawline(int x1, int y1, int x2, int y2)
int d, dinc1, dinc2;
int x, xinc1, xinc2;
int y, yinc1, yinc2;
- tLCDPixelFunc *pfunc = pixelfunc[drawmode];
+ lcd_pixelfunc_type *pfunc = pixelfunc[drawmode];
deltax = abs(x2 - x1);
deltay = abs(y2 - y1);
@@ -511,7 +511,7 @@ void lcd_hline(int x1, int x2, int y)
int x;
unsigned char *dst;
unsigned char mask, bits;
- tLCDBlockFunc *bfunc;
+ lcd_blockfunc_type *bfunc;
/* direction flip */
if (x2 < x1)
@@ -546,7 +546,7 @@ void lcd_vline(int x, int y1, int y2)
int ny;
unsigned char *dst;
unsigned char mask_top, mask_bottom, bits;
- tLCDBlockFunc *bfunc;
+ lcd_blockfunc_type *bfunc;
/* direction flip */
if (y2 < y1)
@@ -606,7 +606,7 @@ void lcd_drawrect(int x, int y, int width, int height)
}
/* helper function for lcd_fillrect() */
-static void fillrow(tLCDBlockFunc *bfunc, unsigned char *address,
+static void fillrow(lcd_blockfunc_type *bfunc, unsigned char *address,
int width, unsigned mask, unsigned bits)
{
int i;
@@ -621,7 +621,7 @@ void lcd_fillrect(int x, int y, int width, int height)
int ny;
unsigned char *dst;
unsigned char mask_top, mask_bottom, bits;
- tLCDBlockFunc *bfunc;
+ lcd_blockfunc_type *bfunc;
bool fillopt = (drawmode & DRMODE_INVERSEVID) ?
(drawmode & DRMODE_BG) : (drawmode & DRMODE_FG);
diff --git a/firmware/export/lcd.h b/firmware/export/lcd.h
index 700ebbf67c..c6e0fe0f0e 100644
--- a/firmware/export/lcd.h
+++ b/firmware/export/lcd.h
@@ -126,8 +126,8 @@ extern void lcd_jump_scroll_delay(int ms);
#define CLEAR_PIXEL(x,y) lcd_framebuffer[(y)/8][(x)] &= ~(1<<((y)&7))
#define INVERT_PIXEL(x,y) lcd_framebuffer[(y)/8][(x)] ^= (1<<((y)&7))
-typedef void tLCDPixelFunc(int x, int y); /* for b&w */
-typedef void tLCDBlockFunc(unsigned char *address, unsigned mask, unsigned bits);
+typedef void lcd_pixelfunc_type(int x, int y); /* for b&w */
+typedef void lcd_blockfunc_type(unsigned char *address, unsigned mask, unsigned bits);
/* Memory copy of display bitmap */
extern unsigned char lcd_framebuffer[LCD_HEIGHT/8][LCD_WIDTH];