* grub-core/gfxmenu/gui_circular_progress.c: Take both width and height

into account when calculating radius.
This commit is contained in:
Vladimir Testov 2013-04-03 09:20:29 +02:00 committed by Vladimir 'phcoder' Serbinenko
parent 9efd73ec66
commit c3578acfbb
3 changed files with 10 additions and 1 deletions

View file

@ -138,7 +138,7 @@ circprog_paint (void *vself, const grub_video_rect_t *region)
(height - center_height) / 2, 0, 0,
center_width, center_height);
int radius = width / 2 - tick_width / 2 - 1;
int radius = grub_min (height, width) / 2 - grub_max (tick_height, tick_width) / 2 - 1;
int nticks;
int tick_begin;
int tick_end;