mirror of
https://git.savannah.gnu.org/git/grub.git
synced 2026-10-20 22:48:22 +00:00
* grub-core/gfxmenu/widget-box.c (get_left_pad): Take corners into
account. (get_top_pad): Likewise. (get_right_pad): Likewise. (get_bottom_pad): Likewise.
This commit is contained in:
1 parent
9f59e9fc36
commit
ca1b552c02
2 files changed
+53
-5
No files matched your search
@@ -1,6 +1,14 @@
|
||||
2011-12-14 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* grub-core/gfxmenu/gui_list.c (draw_menu): Don't use set in if.
|
||||
* grub-core/gfxmenu/widget-box.c (get_left_pad): Take corners into
|
||||
account.
|
||||
(get_top_pad): Likewise.
|
||||
(get_right_pad): Likewise.
|
||||
(get_bottom_pad): Likewise.
|
||||
|
||||
2011-12-14 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* grub-core/gfxmenu/gui_list.c (draw_menu): Don't use assignment in if.
|
||||
|
||||
2011-12-14 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
|
||||
@@ -188,25 +188,65 @@ get_border_width (grub_gfxmenu_box_t self)
|
||||
static int
|
||||
get_left_pad (grub_gfxmenu_box_t self)
|
||||
{
|
||||
return get_width (self->raw_pixmaps[BOX_PIXMAP_W]);
|
||||
int v, c;
|
||||
|
||||
v = get_width (self->raw_pixmaps[BOX_PIXMAP_W]);
|
||||
c = get_width (self->raw_pixmaps[BOX_PIXMAP_NW]);
|
||||
if (c > v)
|
||||
v = c;
|
||||
c = get_width (self->raw_pixmaps[BOX_PIXMAP_SW]);
|
||||
if (c > v)
|
||||
v = c;
|
||||
|
||||
return v;
|
||||
}
|
||||
|
||||
static int
|
||||
get_top_pad (grub_gfxmenu_box_t self)
|
||||
{
|
||||
return get_height (self->raw_pixmaps[BOX_PIXMAP_N]);
|
||||
int v, c;
|
||||
|
||||
v = get_height (self->raw_pixmaps[BOX_PIXMAP_N]);
|
||||
c = get_height (self->raw_pixmaps[BOX_PIXMAP_NW]);
|
||||
if (c > v)
|
||||
v = c;
|
||||
c = get_height (self->raw_pixmaps[BOX_PIXMAP_NE]);
|
||||
if (c > v)
|
||||
v = c;
|
||||
|
||||
return v;
|
||||
}
|
||||
|
||||
static int
|
||||
get_right_pad (grub_gfxmenu_box_t self)
|
||||
{
|
||||
return get_width (self->raw_pixmaps[BOX_PIXMAP_E]);
|
||||
int v, c;
|
||||
|
||||
v = get_width (self->raw_pixmaps[BOX_PIXMAP_E]);
|
||||
c = get_width (self->raw_pixmaps[BOX_PIXMAP_NE]);
|
||||
if (c > v)
|
||||
v = c;
|
||||
c = get_width (self->raw_pixmaps[BOX_PIXMAP_SE]);
|
||||
if (c > v)
|
||||
v = c;
|
||||
|
||||
return v;
|
||||
}
|
||||
|
||||
static int
|
||||
get_bottom_pad (grub_gfxmenu_box_t self)
|
||||
{
|
||||
return get_height (self->raw_pixmaps[BOX_PIXMAP_S]);
|
||||
int v, c;
|
||||
|
||||
v = get_height (self->raw_pixmaps[BOX_PIXMAP_S]);
|
||||
c = get_height (self->raw_pixmaps[BOX_PIXMAP_SW]);
|
||||
if (c > v)
|
||||
v = c;
|
||||
c = get_height (self->raw_pixmaps[BOX_PIXMAP_SE]);
|
||||
if (c > v)
|
||||
v = c;
|
||||
|
||||
return v;
|
||||
}
|
||||
|
||||
static void
|
||||
|
||||
Reference in new issue
Block a user