forked from AuroraMiddleware/gtk
GtkTool*: Removed the HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090 ifdefs. This gives us nicer text alignment among other things.
This commit is contained in:
parent
dad6e7343c
commit
2976f4d98c
@ -154,8 +154,6 @@ gtk_tool_item_group_get_icon_size (GtkToolShell *shell)
|
||||
return GTK_ICON_SIZE_SMALL_TOOLBAR;
|
||||
}
|
||||
|
||||
#ifdef HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090
|
||||
|
||||
static PangoEllipsizeMode
|
||||
gtk_tool_item_group_get_ellipsize_mode (GtkToolShell *shell)
|
||||
{
|
||||
@ -200,8 +198,6 @@ gtk_tool_item_group_get_text_size_group (GtkToolShell *shell)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
static void
|
||||
animation_change_notify (GtkToolItemGroup *group)
|
||||
{
|
||||
@ -272,12 +268,10 @@ gtk_tool_item_group_tool_shell_init (GtkToolShellIface *iface)
|
||||
iface->get_icon_size = gtk_tool_item_group_get_icon_size;
|
||||
iface->get_orientation = gtk_tool_item_group_get_orientation;
|
||||
iface->get_style = gtk_tool_item_group_get_style;
|
||||
#ifdef HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090
|
||||
iface->get_text_alignment = gtk_tool_item_group_get_text_alignment;
|
||||
iface->get_text_orientation = gtk_tool_item_group_get_text_orientation;
|
||||
iface->get_text_size_group = gtk_tool_item_group_get_text_size_group;
|
||||
iface->get_ellipsize_mode = gtk_tool_item_group_get_ellipsize_mode;
|
||||
#endif
|
||||
}
|
||||
|
||||
static gboolean
|
||||
@ -1844,9 +1838,7 @@ gtk_tool_item_group_set_ellipsize (GtkToolItemGroup *group,
|
||||
group->priv->ellipsize = ellipsize;
|
||||
gtk_tool_item_group_header_adjust_style (group);
|
||||
g_object_notify (G_OBJECT (group), "ellipsize");
|
||||
#ifdef HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090
|
||||
_gtk_tool_item_group_palette_reconfigured (group);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -144,9 +144,7 @@ struct _GtkToolPalettePrivate
|
||||
|
||||
GtkWidget *expanding_child;
|
||||
|
||||
#ifdef HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090
|
||||
GtkSizeGroup *text_size_group;
|
||||
#endif
|
||||
|
||||
guint sparse_groups : 1;
|
||||
guint drag_source : 2;
|
||||
@ -186,9 +184,7 @@ gtk_tool_palette_init (GtkToolPalette *palette)
|
||||
palette->priv->orientation = DEFAULT_ORIENTATION;
|
||||
palette->priv->style = DEFAULT_TOOLBAR_STYLE;
|
||||
|
||||
#ifdef HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090
|
||||
palette->priv->text_size_group = gtk_size_group_new (GTK_SIZE_GROUP_BOTH);
|
||||
#endif
|
||||
}
|
||||
|
||||
static void
|
||||
@ -302,13 +298,11 @@ gtk_tool_palette_dispose (GObject *object)
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090
|
||||
if (palette->priv->text_size_group)
|
||||
{
|
||||
g_object_unref (palette->priv->text_size_group);
|
||||
palette->priv->text_size_group = NULL;
|
||||
}
|
||||
#endif
|
||||
|
||||
G_OBJECT_CLASS (gtk_tool_palette_parent_class)->dispose (object);
|
||||
}
|
||||
@ -1672,8 +1666,6 @@ gtk_tool_palette_get_vadjustment (GtkToolPalette *palette)
|
||||
return palette->priv->vadjustment;
|
||||
}
|
||||
|
||||
#ifdef HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090
|
||||
|
||||
GtkSizeGroup *
|
||||
_gtk_tool_palette_get_size_group (GtkToolPalette *palette)
|
||||
{
|
||||
@ -1681,5 +1673,3 @@ _gtk_tool_palette_get_size_group (GtkToolPalette *palette)
|
||||
|
||||
return palette->priv->text_size_group;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
@ -49,11 +49,7 @@ gint _gtk_tool_item_group_get_size_for_limit (GtkToolItemGroup *group,
|
||||
gboolean vertical,
|
||||
gboolean animation);
|
||||
|
||||
#undef HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090
|
||||
/* #define HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090 */
|
||||
|
||||
#ifdef HAVE_EXTENDED_TOOL_SHELL_SUPPORT_BUG_535090
|
||||
GtkSizeGroup *_gtk_tool_palette_get_size_group (GtkToolPalette *palette);
|
||||
#endif
|
||||
|
||||
#endif /* __GTK_TOOL_PALETTE_PRIVATE_H__ */
|
||||
|
Loading…
Reference in New Issue
Block a user