Patch #985429 by Christi Scarborough, solid progress bar

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@4851 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Linus Nielsen Feltzing 2004-07-08 10:52:09 +00:00
parent 64c53c6dc2
commit 5f6047075f
6 changed files with 24 additions and 2 deletions

View file

@ -2793,3 +2793,9 @@ desc: in sound settings
eng: "Super bass"
voice: "Super bass"
new:
id: LANG_PROGRESSBAR_SOLID
desc: Appearance of the progress bar
eng: "Solid progress bar"
voice: "solid progress bar"
new:

View file

@ -193,6 +193,7 @@ static struct bit_entry rtc_bits[] =
{1, S_O(statusbar), true, "statusbar", off_on },
{1, S_O(scrollbar), true, "scrollbar", off_on },
{1, S_O(buttonbar), true, "buttonbar", off_on },
{1, S_O(progressbar_solid), false, "solid progressbar", off_on },
{1, S_O(volume_type), 0, "volume display", graphic_numeric },
{1, S_O(battery_type), 0, "battery display", graphic_numeric },
{1, S_O(timeformat), 0, "time format", "24hour,12hour" },

View file

@ -168,6 +168,9 @@ struct user_settings
/* show scroll bar */
bool scrollbar; /* 0=hide, 1=show */
/* Scrollbar mode */
bool progressbar_solid; /* 0=slider, 1=solid */
/* goto current song when exiting WPS */
bool browse_current; /* 1=goto current song,
0=goto previous location */

View file

@ -959,6 +959,12 @@ static bool button_bar(void)
{
return set_bool( str(LANG_BUTTON_BAR), &global_settings.buttonbar );
}
static bool progressbar_solid(void)
{
return set_bool( str(LANG_PROGRESSBAR_SOLID),
&global_settings.progressbar_solid );
}
#endif
static bool ff_rewind_settings_menu(void)
@ -1192,6 +1198,7 @@ static bool display_settings_menu(void)
#ifdef HAVE_LCD_BITMAP
{ STR(LANG_BARS_MENU), bars_settings_menu },
{ STR(LANG_PM_MENU), peak_meter_menu },
{ STR(LANG_PROGRESSBAR_SOLID), progressbar_solid },
#endif
};

View file

@ -916,8 +916,12 @@ bool wps_refresh(struct mp3entry* id3,
int percent=
id3->length?
(id3->elapsed + ff_rewind_count) * 100 / id3->length:0;
slidebar(0, i*h + offset + 1, LCD_WIDTH, 6,
percent, Grow_Right);
if(global_settings.progressbar_solid)
scrollbar(0, i*h + offset + 1, LCD_WIDTH, 6, 100, 0,
percent, HORIZONTAL);
else
slidebar(0, i*h + offset + 1, LCD_WIDTH, 6,
percent, Grow_Right);
update_line = true;
}
if (flags & refresh_mode & WPS_REFRESH_PEAK_METER) {

View file

@ -86,3 +86,4 @@ Matthias Wientapper
Brent Coutts
Jens Arnold
Gerald Vanbaren
Christi Scarborough