* grub-core/gfxmenu/gui_progress_bar.c (draw_pixmap_bar): Fixed bug.

Pixmap highlighted section with east and west slices was displayed
        incorrectly due to negative width of the central slice.
This commit is contained in:
Vladimir Testov committed 2013-10-17 15:34:04 +04:00
1 parent ad543f123b
commit 9c13c57623
2 files changed
+12 -4

No files matched your search

+6
View File
@@ -1,3 +1,9 @@
2013-10-17 Vladimir Testov <vladimir.testov@rosalab.ru>
* grub-core/gfxmenu/gui_progress_bar.c (draw_pixmap_bar): Fixed bug.
Pixmap highlighted section with east and west slices was displayed
incorrectly due to negative width of the central slice.
2013-10-17 Vladimir Testov <vladimir.testov@rosalab.ru>
* docs/grub.texi: Graphical options information update.
+6 -4
View File
@@ -154,14 +154,16 @@ draw_pixmap_bar (grub_gui_progress_bar_t self)
int barwidth;
bar->set_content_size (bar, tracklen, trackheight);
bar->draw (bar, 0, 0);
barwidth = (tracklen * (self->value - self->start)
/ (self->end - self->start));
hl->set_content_size (hl, barwidth - hl_h_pad, h - bar_v_pad - hl_v_pad);
bar->draw (bar, 0, 0);
hl->draw (hl, bar_l_pad, bar_t_pad);
if (barwidth >= hl_h_pad)
{
hl->set_content_size (hl, barwidth - hl_h_pad, h - bar_v_pad - hl_v_pad);
hl->draw (hl, bar_l_pad, bar_t_pad);
}
}
static void