diff options
author | Thomas Martitz <kugel@rockbox.org> | 2009-02-05 00:14:52 +0000 |
---|---|---|
committer | Thomas Martitz <kugel@rockbox.org> | 2009-02-05 00:14:52 +0000 |
commit | dd137301121b4e45d3b2e28ba756c22f3212cbfa (patch) | |
tree | 4cf58a2b49c01dc5a8cd84608edcfed4823e6fdb /apps | |
parent | e8da4477297ffb12603680f09fa9b2cd30d0b7b5 (diff) | |
download | rockbox-dd137301121b4e45d3b2e28ba756c22f3212cbfa.tar.gz rockbox-dd137301121b4e45d3b2e28ba756c22f3212cbfa.zip |
Minor quickscreen and pitchscreen fixes
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19924 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r-- | apps/gui/pitchscreen.c | 5 | ||||
-rw-r--r-- | apps/gui/quickscreen.c | 2 |
2 files changed, 3 insertions, 4 deletions
diff --git a/apps/gui/pitchscreen.c b/apps/gui/pitchscreen.c index 746af0d7de..db50a5d866 100644 --- a/apps/gui/pitchscreen.c +++ b/apps/gui/pitchscreen.c | |||
@@ -68,7 +68,6 @@ static void pitchscreen_fix_viewports(struct viewport *parent, | |||
68 | pitch_viewports[i] = *parent; | 68 | pitch_viewports[i] = *parent; |
69 | pitch_viewports[i].height = height; | 69 | pitch_viewports[i].height = height; |
70 | } | 70 | } |
71 | |||
72 | pitch_viewports[PITCH_TOP].y += ICON_BORDER; | 71 | pitch_viewports[PITCH_TOP].y += ICON_BORDER; |
73 | 72 | ||
74 | pitch_viewports[PITCH_MID].x += ICON_BORDER; | 73 | pitch_viewports[PITCH_MID].x += ICON_BORDER; |
@@ -98,6 +97,7 @@ static void pitchscreen_draw_icons (struct screen *display, | |||
98 | display->mono_bitmap(bitmap_icons_7x8[Icon_FastBackward], | 97 | display->mono_bitmap(bitmap_icons_7x8[Icon_FastBackward], |
99 | 2, | 98 | 2, |
100 | parent->height /2 - 4, 7, 8); | 99 | parent->height /2 - 4, 7, 8); |
100 | display->update_viewport(); | ||
101 | } | 101 | } |
102 | 102 | ||
103 | static void pitchscreen_draw (struct screen *display, int max_lines, | 103 | static void pitchscreen_draw (struct screen *display, int max_lines, |
@@ -153,7 +153,7 @@ static void pitchscreen_draw (struct screen *display, int max_lines, | |||
153 | snprintf((char *)buf, sizeof(buf), "%d.%d%%", | 153 | snprintf((char *)buf, sizeof(buf), "%d.%d%%", |
154 | pitch / 10, pitch % 10 ); | 154 | pitch / 10, pitch % 10 ); |
155 | display->getstringsize(buf,&width_val,&h); | 155 | display->getstringsize(buf,&width_val,&h); |
156 | display->putsxy((pitch_viewports[PITCH_MID].width / 2) - (w / 2), | 156 | display->putsxy((pitch_viewports[PITCH_MID].width / 2) - (width_val / 2), |
157 | (show_lang_pitch? h : h/2), buf); | 157 | (show_lang_pitch? h : h/2), buf); |
158 | 158 | ||
159 | /* What's wider? LANG_PITCH or the value? | 159 | /* What's wider? LANG_PITCH or the value? |
@@ -272,7 +272,6 @@ int gui_syncpitchscreen_run(void) | |||
272 | 272 | ||
273 | /* also, draw the icons now, it's only needed once */ | 273 | /* also, draw the icons now, it's only needed once */ |
274 | pitchscreen_draw_icons(&screens[i], &parent[i]); | 274 | pitchscreen_draw_icons(&screens[i], &parent[i]); |
275 | screens[i].update(); | ||
276 | } | 275 | } |
277 | #if CONFIG_CODEC == SWCODEC | 276 | #if CONFIG_CODEC == SWCODEC |
278 | pcmbuf_set_low_latency(true); | 277 | pcmbuf_set_low_latency(true); |
diff --git a/apps/gui/quickscreen.c b/apps/gui/quickscreen.c index c554195d27..b39105dc72 100644 --- a/apps/gui/quickscreen.c +++ b/apps/gui/quickscreen.c | |||
@@ -70,7 +70,7 @@ static void quickscreen_fix_viewports(struct gui_quickscreen *qs, | |||
70 | /* center the icons VP first */ | 70 | /* center the icons VP first */ |
71 | vp_icons[screen] = *parent; | 71 | vp_icons[screen] = *parent; |
72 | vp_icons[screen].width = CENTER_ICONAREA_WIDTH; /* abosulte smallest allowed */ | 72 | vp_icons[screen].width = CENTER_ICONAREA_WIDTH; /* abosulte smallest allowed */ |
73 | vp_icons[screen].x = (parent->width-parent->x-CENTER_ICONAREA_WIDTH)/2; | 73 | vp_icons[screen].x = parent->x + (parent->width / 2 - CENTER_ICONAREA_WIDTH / 2); |
74 | 74 | ||
75 | vps[screen][QUICKSCREEN_BOTTOM] = *parent; | 75 | vps[screen][QUICKSCREEN_BOTTOM] = *parent; |
76 | if (nb_lines <= MIN_LINES) /* make the bottom item use 1 line */ | 76 | if (nb_lines <= MIN_LINES) /* make the bottom item use 1 line */ |