Avoid copying the set_name by interning it.
2005-12-27 Matthias Clasen <mclasen@redhat.com> * gtk/gtkbindings.c (gtk_binding_set_new): Avoid copying the set_name by interning it.
This commit is contained in:
parent
165b7ad3d3
commit
779c7ea8df
3 changed files with 11 additions and 2 deletions
|
|
@ -1,3 +1,8 @@
|
|||
2005-12-27 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gtk/gtkbindings.c (gtk_binding_set_new): Avoid copying
|
||||
the set_name by interning it.
|
||||
|
||||
2005-12-26 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gdk/x11/gdkdisplay-x11.c (gdk_display_open): Precache atoms
|
||||
|
|
|
|||
|
|
@ -1,3 +1,8 @@
|
|||
2005-12-27 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gtk/gtkbindings.c (gtk_binding_set_new): Avoid copying
|
||||
the set_name by interning it.
|
||||
|
||||
2005-12-26 Matthias Clasen <mclasen@redhat.com>
|
||||
|
||||
* gdk/x11/gdkdisplay-x11.c (gdk_display_open): Precache atoms
|
||||
|
|
|
|||
|
|
@ -558,7 +558,7 @@ gtk_binding_set_new (const gchar *set_name)
|
|||
g_return_val_if_fail (set_name != NULL, NULL);
|
||||
|
||||
binding_set = g_new (GtkBindingSet, 1);
|
||||
binding_set->set_name = g_strdup (set_name);
|
||||
binding_set->set_name = g_intern_string (set_name);
|
||||
binding_set->widget_path_pspecs = NULL;
|
||||
binding_set->widget_class_pspecs = NULL;
|
||||
binding_set->class_branch_pspecs = NULL;
|
||||
|
|
@ -1442,7 +1442,6 @@ binding_set_delete (GtkBindingSet *binding_set)
|
|||
free_pattern_specs (binding_set->widget_class_pspecs);
|
||||
free_pattern_specs (binding_set->class_branch_pspecs);
|
||||
|
||||
g_free (binding_set->set_name);
|
||||
g_free (binding_set);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue