diff options
| author | Dan Everton <dan@iocaine.org> | 2006-03-25 13:35:31 +0000 |
|---|---|---|
| committer | Dan Everton <dan@iocaine.org> | 2006-03-25 13:35:31 +0000 |
| commit | b66477adccfd08987e409182e15bb17e70283fae (patch) | |
| tree | 46861838424afed2c2d7a6e41d429064d08f0e45 /apps/gui/icon.c | |
| parent | 2b71fa855d57c1dcd19411882d545002603a9dc3 (diff) | |
| download | rockbox-b66477adccfd08987e409182e15bb17e70283fae.zip rockbox-b66477adccfd08987e409182e15bb17e70283fae.tar.gz rockbox-b66477adccfd08987e409182e15bb17e70283fae.tar.bz2 rockbox-b66477adccfd08987e409182e15bb17e70283fae.tar.xz | |
Support the recording screen on the LCD remote. Also adds support for the peakmeter in the rremote WPS. Patch from Martin Scarratt (task 4818).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9246 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/gui/icon.c')
| -rw-r--r-- | apps/gui/icon.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/apps/gui/icon.c b/apps/gui/icon.c index 0cdee11..ef6f61f 100644 --- a/apps/gui/icon.c +++ b/apps/gui/icon.c @@ -26,12 +26,14 @@ void screen_put_iconxy(struct screen * display, int x, int y, ICON icon) { #ifdef HAVE_LCD_BITMAP + int width, height; int xpos, ypos; + display->getstringsize((unsigned char *)"M", &width, &height); xpos = x*CURSOR_WIDTH; - ypos = y*display->char_height + display->getymargin(); + ypos = y*height + display->getymargin(); - if ( display->char_height > CURSOR_HEIGHT )/* center the cursor */ - ypos += (display->char_height - CURSOR_HEIGHT) / 2; + if ( height > CURSOR_HEIGHT )/* center the cursor */ + ypos += (height - CURSOR_HEIGHT) / 2; if(icon==0)/* Don't display invalid icons */ screen_clear_area(display, xpos, ypos, CURSOR_WIDTH, CURSOR_HEIGHT); else |