gtkseparatortoolitem: unseal private pointer
This commit is contained in:
parent
675745e1ca
commit
22d4515d9a
@ -47,6 +47,11 @@
|
|||||||
|
|
||||||
#define MENU_ID "gtk-separator-tool-item-menu-id"
|
#define MENU_ID "gtk-separator-tool-item-menu-id"
|
||||||
|
|
||||||
|
struct _GtkSeparatorToolItemPrivate
|
||||||
|
{
|
||||||
|
guint draw : 1;
|
||||||
|
};
|
||||||
|
|
||||||
enum {
|
enum {
|
||||||
PROP_0,
|
PROP_0,
|
||||||
PROP_DRAW
|
PROP_DRAW
|
||||||
@ -70,14 +75,6 @@ static void gtk_separator_tool_item_add (GtkContainer
|
|||||||
static gint get_space_size (GtkToolItem *tool_item);
|
static gint get_space_size (GtkToolItem *tool_item);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define GTK_SEPARATOR_TOOL_ITEM_GET_PRIVATE(obj)(G_TYPE_INSTANCE_GET_PRIVATE ((obj), GTK_TYPE_SEPARATOR_TOOL_ITEM, GtkSeparatorToolItemPrivate))
|
|
||||||
|
|
||||||
struct _GtkSeparatorToolItemPrivate
|
|
||||||
{
|
|
||||||
guint draw : 1;
|
|
||||||
};
|
|
||||||
|
|
||||||
G_DEFINE_TYPE (GtkSeparatorToolItem, gtk_separator_tool_item, GTK_TYPE_TOOL_ITEM)
|
G_DEFINE_TYPE (GtkSeparatorToolItem, gtk_separator_tool_item, GTK_TYPE_TOOL_ITEM)
|
||||||
|
|
||||||
static gint
|
static gint
|
||||||
@ -131,7 +128,9 @@ gtk_separator_tool_item_class_init (GtkSeparatorToolItemClass *class)
|
|||||||
static void
|
static void
|
||||||
gtk_separator_tool_item_init (GtkSeparatorToolItem *separator_item)
|
gtk_separator_tool_item_init (GtkSeparatorToolItem *separator_item)
|
||||||
{
|
{
|
||||||
separator_item->priv = GTK_SEPARATOR_TOOL_ITEM_GET_PRIVATE (separator_item);
|
separator_item->priv = G_TYPE_INSTANCE_GET_PRIVATE (separator_item,
|
||||||
|
GTK_TYPE_SEPARATOR_TOOL_ITEM,
|
||||||
|
GtkSeparatorToolItemPrivate);
|
||||||
separator_item->priv->draw = TRUE;
|
separator_item->priv->draw = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -216,8 +215,8 @@ gtk_separator_tool_item_expose (GtkWidget *widget,
|
|||||||
GdkEventExpose *event)
|
GdkEventExpose *event)
|
||||||
{
|
{
|
||||||
GtkToolbar *toolbar = NULL;
|
GtkToolbar *toolbar = NULL;
|
||||||
GtkSeparatorToolItemPrivate *priv =
|
GtkSeparatorToolItem *separator = GTK_SEPARATOR_TOOL_ITEM (widget);
|
||||||
GTK_SEPARATOR_TOOL_ITEM_GET_PRIVATE (widget);
|
GtkSeparatorToolItemPrivate *priv = separator->priv;
|
||||||
|
|
||||||
if (priv->draw)
|
if (priv->draw)
|
||||||
{
|
{
|
||||||
|
@ -46,7 +46,7 @@ struct _GtkSeparatorToolItem
|
|||||||
GtkToolItem parent;
|
GtkToolItem parent;
|
||||||
|
|
||||||
/*< private >*/
|
/*< private >*/
|
||||||
GtkSeparatorToolItemPrivate *GSEAL (priv);
|
GtkSeparatorToolItemPrivate *priv;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct _GtkSeparatorToolItemClass
|
struct _GtkSeparatorToolItemClass
|
||||||
|
Loading…
Reference in New Issue
Block a user