Commit 096fdfb7 authored by Owen Taylor's avatar Owen Taylor Committed by Owen Taylor

Reference param spec when caching property values, since we unref it later

Mon Apr  2 15:06:13 2001  Owen Taylor  <otaylor@redhat.com>

	* gtk/gtkstyle.c (_gtk_style_peek_property_value): Reference
	param spec when caching property values, since we unref it
	later when we free the style.

	* gtk/gtkoptionmenu.c (gtk_option_menu_get_props): Dont' free
	values since they are retrieved with G_VALUE_NO_COPY_CONTENTS.
parent c944151a
Mon Apr 2 15:06:13 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkstyle.c (_gtk_style_peek_property_value): Reference
param spec when caching property values, since we unref it
later when we free the style.
* gtk/gtkoptionmenu.c (gtk_option_menu_get_props): Dont' free
values since they are retrieved with G_VALUE_NO_COPY_CONTENTS.
Mon Apr 2 10:47:57 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkwidget.c (gtk_widget_class_init): Fix
......
Mon Apr 2 15:06:13 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkstyle.c (_gtk_style_peek_property_value): Reference
param spec when caching property values, since we unref it
later when we free the style.
* gtk/gtkoptionmenu.c (gtk_option_menu_get_props): Dont' free
values since they are retrieved with G_VALUE_NO_COPY_CONTENTS.
Mon Apr 2 10:47:57 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkwidget.c (gtk_widget_class_init): Fix
......
Mon Apr 2 15:06:13 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkstyle.c (_gtk_style_peek_property_value): Reference
param spec when caching property values, since we unref it
later when we free the style.
* gtk/gtkoptionmenu.c (gtk_option_menu_get_props): Dont' free
values since they are retrieved with G_VALUE_NO_COPY_CONTENTS.
Mon Apr 2 10:47:57 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkwidget.c (gtk_widget_class_init): Fix
......
Mon Apr 2 15:06:13 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkstyle.c (_gtk_style_peek_property_value): Reference
param spec when caching property values, since we unref it
later when we free the style.
* gtk/gtkoptionmenu.c (gtk_option_menu_get_props): Dont' free
values since they are retrieved with G_VALUE_NO_COPY_CONTENTS.
Mon Apr 2 10:47:57 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkwidget.c (gtk_widget_class_init): Fix
......
Mon Apr 2 15:06:13 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkstyle.c (_gtk_style_peek_property_value): Reference
param spec when caching property values, since we unref it
later when we free the style.
* gtk/gtkoptionmenu.c (gtk_option_menu_get_props): Dont' free
values since they are retrieved with G_VALUE_NO_COPY_CONTENTS.
Mon Apr 2 10:47:57 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkwidget.c (gtk_widget_class_init): Fix
......
Mon Apr 2 15:06:13 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkstyle.c (_gtk_style_peek_property_value): Reference
param spec when caching property values, since we unref it
later when we free the style.
* gtk/gtkoptionmenu.c (gtk_option_menu_get_props): Dont' free
values since they are retrieved with G_VALUE_NO_COPY_CONTENTS.
Mon Apr 2 10:47:57 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkwidget.c (gtk_widget_class_init): Fix
......
Mon Apr 2 15:06:13 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkstyle.c (_gtk_style_peek_property_value): Reference
param spec when caching property values, since we unref it
later when we free the style.
* gtk/gtkoptionmenu.c (gtk_option_menu_get_props): Dont' free
values since they are retrieved with G_VALUE_NO_COPY_CONTENTS.
Mon Apr 2 10:47:57 2001 Owen Taylor <otaylor@redhat.com>
* gtk/gtkwidget.c (gtk_widget_class_init): Fix
......
......@@ -339,15 +339,14 @@ gtk_option_menu_get_props (GtkOptionMenu *option_menu,
NULL);
if (indicator_size)
{
props->indicator_size = *indicator_size;
gtk_requisition_free (indicator_size);
}
props->indicator_size = *indicator_size;
else
props->indicator_size = default_props.indicator_size;
if (indicator_spacing)
{
props->indicator_spacing = *indicator_spacing;
gtk_border_free (indicator_spacing);
}
props->indicator_spacing = *indicator_spacing;
else
props->indicator_spacing = default_props.indicator_spacing;
}
static void
......
......@@ -1311,6 +1311,8 @@ _gtk_style_peek_property_value (GtkStyle *style,
if (!rcprop)
g_param_value_set_default (pspec, &pcache->value);
g_param_spec_ref (pcache->pspec);
return &pcache->value;
}
......
......@@ -32,7 +32,6 @@ style "global-style-properties"
{
# xthickness = 20
GtkSpinButton::shadow_type = etched-out
GtkOptionMenu::indicator_spacing = { 10, 10, 10, 10 }
}
class "GtkWidget" style "global-style-properties"
......
......@@ -32,7 +32,6 @@ style "global-style-properties"
{
# xthickness = 20
GtkSpinButton::shadow_type = etched-out
GtkOptionMenu::indicator_spacing = { 10, 10, 10, 10 }
}
class "GtkWidget" style "global-style-properties"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment