diff options
author | Teruaki Kawashima <teru@rockbox.org> | 2010-10-12 12:17:39 +0000 |
---|---|---|
committer | Teruaki Kawashima <teru@rockbox.org> | 2010-10-12 12:17:39 +0000 |
commit | 3eb5826c8a289d2ff2af246388e17d4aa6483da4 (patch) | |
tree | 343690ac844a3d96cec667e1c84793076affa067 /apps/gui/skin_engine/skin_parser.c | |
parent | 69e379a47b6c7830fc17e912eecde6eb5100037f (diff) | |
download | rockbox-3eb5826c8a289d2ff2af246388e17d4aa6483da4.tar.gz rockbox-3eb5826c8a289d2ff2af246388e17d4aa6483da4.zip |
improvement for bar tag with slider.
-fix bug the slider is drawn outside of the bounds (FS#11658).
-offset the slider position so that the center of the slider indicates current position.
-add nobar option. if this option is set, the bar isn't drawn at all.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28248 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/gui/skin_engine/skin_parser.c')
-rw-r--r-- | apps/gui/skin_engine/skin_parser.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/apps/gui/skin_engine/skin_parser.c b/apps/gui/skin_engine/skin_parser.c index 5c169c81de..f5923747ab 100644 --- a/apps/gui/skin_engine/skin_parser.c +++ b/apps/gui/skin_engine/skin_parser.c | |||
@@ -600,6 +600,7 @@ static int parse_progressbar_tag(struct skin_element* element, | |||
600 | pb->bm.data = NULL; /* no bitmap specified */ | 600 | pb->bm.data = NULL; /* no bitmap specified */ |
601 | pb->follow_lang_direction = follow_lang_direction > 0; | 601 | pb->follow_lang_direction = follow_lang_direction > 0; |
602 | pb->nofill = false; | 602 | pb->nofill = false; |
603 | pb->nobar = false; | ||
603 | pb->slider = NULL; | 604 | pb->slider = NULL; |
604 | pb->invert_fill_direction = false; | 605 | pb->invert_fill_direction = false; |
605 | pb->horizontal = true; | 606 | pb->horizontal = true; |
@@ -676,6 +677,8 @@ static int parse_progressbar_tag(struct skin_element* element, | |||
676 | pb->invert_fill_direction = true; | 677 | pb->invert_fill_direction = true; |
677 | else if (!strcmp(param->data.text, "nofill")) | 678 | else if (!strcmp(param->data.text, "nofill")) |
678 | pb->nofill = true; | 679 | pb->nofill = true; |
680 | else if (!strcmp(param->data.text, "nobar")) | ||
681 | pb->nobar = true; | ||
679 | else if (!strcmp(param->data.text, "slider")) | 682 | else if (!strcmp(param->data.text, "slider")) |
680 | { | 683 | { |
681 | if (curr_param+1 < element->params_count) | 684 | if (curr_param+1 < element->params_count) |