summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorPeter D'Hoye <peter.dhoye@gmail.com>2007-12-07 00:07:30 +0000
committerPeter D'Hoye <peter.dhoye@gmail.com>2007-12-07 00:07:30 +0000
commita007b558b3d088644e2b2b38fa51c52cae14007d (patch)
treed681881ca33ab4db9458419048dcbdb9b96ef01d /apps
parentdfc6093342736a1655269b635f306d8ddecccd81 (diff)
downloadrockbox-a007b558b3d088644e2b2b38fa51c52cae14007d.zip
rockbox-a007b558b3d088644e2b2b38fa51c52cae14007d.tar.gz
rockbox-a007b558b3d088644e2b2b38fa51c52cae14007d.tar.bz2
rockbox-a007b558b3d088644e2b2b38fa51c52cae14007d.tar.xz
Fix gradient selection bar in recording screen
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15888 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r--apps/recorder/recording.c32
1 files changed, 29 insertions, 3 deletions
diff --git a/apps/recorder/recording.c b/apps/recorder/recording.c
index 8adf5af..069c689 100644
--- a/apps/recorder/recording.c
+++ b/apps/recorder/recording.c
@@ -873,13 +873,14 @@ bool recording_screen(bool no_source)
ID2P(LANG_GIGABYTE)
};
- int style = STYLE_INVERT;
+ int base_style = STYLE_INVERT;
+ int style;
#ifdef HAVE_LCD_COLOR
if (global_settings.cursor_style == 2) {
- style |= STYLE_COLORBAR;
+ base_style |= STYLE_COLORBAR;
}
else if (global_settings.cursor_style == 3) {
- style |= STYLE_GRADIENT | 1;
+ base_style |= STYLE_GRADIENT;
}
#endif
@@ -1454,6 +1455,14 @@ bool recording_screen(bool no_source)
for(i = 0; i < screen_update; i++)
screens[i].clear_display();
+ style = base_style;
+
+#ifdef HAVE_LCD_COLOR
+ /* special action for gradient - set default for 1 line gradient */
+ if(global_settings.cursor_style == 3)
+ style = base_style | CURLN_PACK(0) | NUMLN_PACK(1);
+#endif /* HAVE_LCD_COLOR */
+
#if CONFIG_CODEC == SWCODEC
if ((audio_stat & AUDIO_STATUS_WARNING)
&& (warning_counter++ % WARNING_PERIOD) < WARNING_PERIOD/2)
@@ -1622,6 +1631,12 @@ bool recording_screen(bool no_source)
fmt_gain(SOUND_LEFT_GAIN,
global_settings.rec_left_gain,
buf2, sizeof(buf2)));
+#ifdef HAVE_LCD_COLOR
+ /* special action for gradient - double line gradient - line1 */
+ if((global_settings.cursor_style == 3) &&
+ (1==cursor))
+ style = base_style | CURLN_PACK(0) | NUMLN_PACK(2);
+#endif /* HAVE_LCD_COLOR */
if(global_settings.cursor_style && ((1==cursor)||(2==cursor)))
{
for(i = 0; i < screen_update; i++)
@@ -1640,6 +1655,12 @@ bool recording_screen(bool no_source)
fmt_gain(SOUND_RIGHT_GAIN,
global_settings.rec_right_gain,
buf2, sizeof(buf2)));
+#ifdef HAVE_LCD_COLOR
+ /* special action for gradient - double line gradient - line2 */
+ if((global_settings.cursor_style == 3) &&
+ (1==cursor))
+ style = base_style | CURLN_PACK(1) | NUMLN_PACK(2);
+#endif /* HAVE_LCD_COLOR */
if(global_settings.cursor_style && ((1==cursor)||(3==cursor)))
{
for(i = 0; i < screen_update; i++)
@@ -1653,6 +1674,11 @@ bool recording_screen(bool no_source)
PM_HEIGHT + 4, buf);
}
}
+#ifdef HAVE_LCD_COLOR
+ /* special action for gradient - back to single line gradient */
+ if(global_settings.cursor_style == 3)
+ style = base_style | CURLN_PACK(0) | NUMLN_PACK(1);
+#endif /* HAVE_LCD_COLOR */
FOR_NB_SCREENS(i)
{