]> Pileus Git - ~andy/gtk/commitdiff
Fix the default value of the tearoff-title property
authorMatthias Clasen <matthiasc@src.gnome.org>
Fri, 28 Dec 2007 05:49:21 +0000 (05:49 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Fri, 28 Dec 2007 05:49:21 +0000 (05:49 +0000)
svn path=/trunk/; revision=19257

ChangeLog
gtk/gtkcombobox.c

index 17ba4ca50d977414e8dd0cfc760ea935614e3377..c50d71d67c358e856c7e2ab6c7f620fd0b02f072 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2007-12-27  Matthias Clasen  <mclasen@redhat.com>
 
+       * gtk/gtkcombobox.c: Correct the default value for the 
+       tearoff-title property.
+
        * gtk/gtkcellrenderertext.c: Fix the default value for the
        wrap-mode and font-scale properties.
 
index 741bee258dc24861fff2c2aaad31cb9046b202cd..9682c4d85d1bf29af612c5336db6159c49db2ce1 100644 (file)
@@ -802,7 +802,7 @@ gtk_combo_box_class_init (GtkComboBoxClass *klass)
                                    g_param_spec_string ("tearoff-title",
                                                         P_("Tearoff Title"),
                                                         P_("A title that may be displayed by the window manager when the popup is torn-off"),
-                                                        "",
+                                                        NULL,
                                                         GTK_PARAM_READWRITE));
 
 
@@ -5523,13 +5523,17 @@ void
 gtk_combo_box_set_title (GtkComboBox *combo_box,
                         const gchar *title)
 {
+  GtkComboBoxPrivate *priv;
+
   g_return_if_fail (GTK_IS_COMBO_BOX (combo_box));
 
+  priv = combo_box->priv;
+
   if (strcmp (title ? title : "", 
-             combo_box->priv->tearoff_title ? combo_box->priv->tearoff_title : "") != 0)
+             priv->tearoff_title ? priv->tearoff_title : "") != 0)
     {
-      g_free (combo_box->priv->tearoff_title);
-      combo_box->priv->tearoff_title = g_strdup (title);
+      g_free (priv->tearoff_title);
+      priv->tearoff_title = g_strdup (title);
 
       gtk_combo_box_update_title (combo_box);