[gtk+] menuitem: don't request twice the padding for separator menu items
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] menuitem: don't request twice the padding for separator menu items
- Date: Thu, 15 Dec 2011 17:54:32 +0000 (UTC)
commit 20e94c1275c69886320860aad08e108c32c307bc
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Thu Dec 15 12:33:50 2011 +0100
menuitem: don't request twice the padding for separator menu items
Padding was requested twice for separator menu items.
https://bugzilla.gnome.org/show_bug.cgi?id=666242
gtk/gtkmenuitem.c | 18 ++++++++----------
1 files changed, 8 insertions(+), 10 deletions(-)
---
diff --git a/gtk/gtkmenuitem.c b/gtk/gtkmenuitem.c
index d801d86..4649147 100644
--- a/gtk/gtkmenuitem.c
+++ b/gtk/gtkmenuitem.c
@@ -941,11 +941,10 @@ gtk_menu_item_get_preferred_height (GtkWidget *widget,
NULL);
if (wide_separators)
- min_height += separator_height + padding.top;
- else
- min_height += padding.top + padding.bottom;
-
- nat_height = min_height;
+ {
+ min_height += separator_height;
+ nat_height += separator_height;
+ }
}
accel_width = 0;
@@ -1068,11 +1067,10 @@ gtk_menu_item_get_preferred_height_for_width (GtkWidget *widget,
NULL);
if (wide_separators)
- min_height += separator_height + padding.top;
- else
- min_height += padding.top + padding.bottom;
-
- nat_height = min_height;
+ {
+ min_height += separator_height;
+ nat_height += separator_height;
+ }
}
if (minimum_size)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]