* 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:
parent
ad543f123b
commit
9c13c57623
2 changed files with 12 additions and 4 deletions
|
@ -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>
|
2013-10-17 Vladimir Testov <vladimir.testov@rosalab.ru>
|
||||||
|
|
||||||
* docs/grub.texi: Graphical options information update.
|
* docs/grub.texi: Graphical options information update.
|
||||||
|
|
|
@ -154,14 +154,16 @@ draw_pixmap_bar (grub_gui_progress_bar_t self)
|
||||||
int barwidth;
|
int barwidth;
|
||||||
|
|
||||||
bar->set_content_size (bar, tracklen, trackheight);
|
bar->set_content_size (bar, tracklen, trackheight);
|
||||||
|
bar->draw (bar, 0, 0);
|
||||||
|
|
||||||
barwidth = (tracklen * (self->value - self->start)
|
barwidth = (tracklen * (self->value - self->start)
|
||||||
/ (self->end - self->start));
|
/ (self->end - self->start));
|
||||||
|
|
||||||
hl->set_content_size (hl, barwidth - hl_h_pad, h - bar_v_pad - hl_v_pad);
|
if (barwidth >= hl_h_pad)
|
||||||
|
{
|
||||||
bar->draw (bar, 0, 0);
|
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);
|
hl->draw (hl, bar_l_pad, bar_t_pad);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
|
Loading…
Reference in a new issue