mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-25 05:01:09 +00:00
Remove two more places where we were unconditionally setting "visible",
2004-11-11 Matthias Clasen <mclasen@redhat.com> * gtk/gtkuimanager.c (update_node): Remove two more places where we were unconditionally setting "visible", causing unnecessary notifications. * gtk/gtkclipboard.c (gtk_clipboard_get_for_display): (gtk_clipboard_get): Clarify the docs. (#156638, Torsten Schoenfeld) (gtk_clipboard_finalize): Warn if the clipboard is still in its displays clipboard list.
This commit is contained in:
parent
41628edebb
commit
75eb3f9d2f
12
ChangeLog
12
ChangeLog
@ -1,5 +1,15 @@
|
|||||||
2004-11-11 Matthias Clasen <mclasen@redhat.com>
|
2004-11-11 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* gtk/gtkuimanager.c (update_node): Remove two more places
|
||||||
|
where we were unconditionally setting "visible", causing
|
||||||
|
unnecessary notifications.
|
||||||
|
|
||||||
|
* gtk/gtkclipboard.c (gtk_clipboard_get_for_display):
|
||||||
|
(gtk_clipboard_get): Clarify the docs. (#156638, Torsten
|
||||||
|
Schoenfeld)
|
||||||
|
(gtk_clipboard_finalize): Warn if the clipboard is still in
|
||||||
|
its displays clipboard list.
|
||||||
|
|
||||||
Considerably speed up GtkUIManager, by changing the semantics
|
Considerably speed up GtkUIManager, by changing the semantics
|
||||||
of the dirty flag. It is now propagated up the tree, and
|
of the dirty flag. It is now propagated up the tree, and
|
||||||
update_node() doesn't descend into clean subtrees. (#143668,
|
update_node() doesn't descend into clean subtrees. (#143668,
|
||||||
@ -44,7 +54,7 @@ Thu Nov 11 11:34:32 2004 Jonathan Blandford <jrb@redhat.com>
|
|||||||
by leaving room for the resize grip. (#157778, Christian Persch)
|
by leaving room for the resize grip. (#157778, Christian Persch)
|
||||||
|
|
||||||
* gdk/linux-fb/*: Fix many sparse warnings. (#157253,
|
* gdk/linux-fb/*: Fix many sparse warnings. (#157253,
|
||||||
Kjartan Maraas.
|
Kjartan Maraas).
|
||||||
|
|
||||||
* NEWS: Updates
|
* NEWS: Updates
|
||||||
|
|
||||||
|
@ -1,5 +1,15 @@
|
|||||||
2004-11-11 Matthias Clasen <mclasen@redhat.com>
|
2004-11-11 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* gtk/gtkuimanager.c (update_node): Remove two more places
|
||||||
|
where we were unconditionally setting "visible", causing
|
||||||
|
unnecessary notifications.
|
||||||
|
|
||||||
|
* gtk/gtkclipboard.c (gtk_clipboard_get_for_display):
|
||||||
|
(gtk_clipboard_get): Clarify the docs. (#156638, Torsten
|
||||||
|
Schoenfeld)
|
||||||
|
(gtk_clipboard_finalize): Warn if the clipboard is still in
|
||||||
|
its displays clipboard list.
|
||||||
|
|
||||||
Considerably speed up GtkUIManager, by changing the semantics
|
Considerably speed up GtkUIManager, by changing the semantics
|
||||||
of the dirty flag. It is now propagated up the tree, and
|
of the dirty flag. It is now propagated up the tree, and
|
||||||
update_node() doesn't descend into clean subtrees. (#143668,
|
update_node() doesn't descend into clean subtrees. (#143668,
|
||||||
@ -44,7 +54,7 @@ Thu Nov 11 11:34:32 2004 Jonathan Blandford <jrb@redhat.com>
|
|||||||
by leaving room for the resize grip. (#157778, Christian Persch)
|
by leaving room for the resize grip. (#157778, Christian Persch)
|
||||||
|
|
||||||
* gdk/linux-fb/*: Fix many sparse warnings. (#157253,
|
* gdk/linux-fb/*: Fix many sparse warnings. (#157253,
|
||||||
Kjartan Maraas.
|
Kjartan Maraas).
|
||||||
|
|
||||||
* NEWS: Updates
|
* NEWS: Updates
|
||||||
|
|
||||||
|
@ -1,5 +1,15 @@
|
|||||||
2004-11-11 Matthias Clasen <mclasen@redhat.com>
|
2004-11-11 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* gtk/gtkuimanager.c (update_node): Remove two more places
|
||||||
|
where we were unconditionally setting "visible", causing
|
||||||
|
unnecessary notifications.
|
||||||
|
|
||||||
|
* gtk/gtkclipboard.c (gtk_clipboard_get_for_display):
|
||||||
|
(gtk_clipboard_get): Clarify the docs. (#156638, Torsten
|
||||||
|
Schoenfeld)
|
||||||
|
(gtk_clipboard_finalize): Warn if the clipboard is still in
|
||||||
|
its displays clipboard list.
|
||||||
|
|
||||||
Considerably speed up GtkUIManager, by changing the semantics
|
Considerably speed up GtkUIManager, by changing the semantics
|
||||||
of the dirty flag. It is now propagated up the tree, and
|
of the dirty flag. It is now propagated up the tree, and
|
||||||
update_node() doesn't descend into clean subtrees. (#143668,
|
update_node() doesn't descend into clean subtrees. (#143668,
|
||||||
@ -44,7 +54,7 @@ Thu Nov 11 11:34:32 2004 Jonathan Blandford <jrb@redhat.com>
|
|||||||
by leaving room for the resize grip. (#157778, Christian Persch)
|
by leaving room for the resize grip. (#157778, Christian Persch)
|
||||||
|
|
||||||
* gdk/linux-fb/*: Fix many sparse warnings. (#157253,
|
* gdk/linux-fb/*: Fix many sparse warnings. (#157253,
|
||||||
Kjartan Maraas.
|
Kjartan Maraas).
|
||||||
|
|
||||||
* NEWS: Updates
|
* NEWS: Updates
|
||||||
|
|
||||||
|
@ -1,5 +1,15 @@
|
|||||||
2004-11-11 Matthias Clasen <mclasen@redhat.com>
|
2004-11-11 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* gtk/gtkuimanager.c (update_node): Remove two more places
|
||||||
|
where we were unconditionally setting "visible", causing
|
||||||
|
unnecessary notifications.
|
||||||
|
|
||||||
|
* gtk/gtkclipboard.c (gtk_clipboard_get_for_display):
|
||||||
|
(gtk_clipboard_get): Clarify the docs. (#156638, Torsten
|
||||||
|
Schoenfeld)
|
||||||
|
(gtk_clipboard_finalize): Warn if the clipboard is still in
|
||||||
|
its displays clipboard list.
|
||||||
|
|
||||||
Considerably speed up GtkUIManager, by changing the semantics
|
Considerably speed up GtkUIManager, by changing the semantics
|
||||||
of the dirty flag. It is now propagated up the tree, and
|
of the dirty flag. It is now propagated up the tree, and
|
||||||
update_node() doesn't descend into clean subtrees. (#143668,
|
update_node() doesn't descend into clean subtrees. (#143668,
|
||||||
@ -44,7 +54,7 @@ Thu Nov 11 11:34:32 2004 Jonathan Blandford <jrb@redhat.com>
|
|||||||
by leaving room for the resize grip. (#157778, Christian Persch)
|
by leaving room for the resize grip. (#157778, Christian Persch)
|
||||||
|
|
||||||
* gdk/linux-fb/*: Fix many sparse warnings. (#157253,
|
* gdk/linux-fb/*: Fix many sparse warnings. (#157253,
|
||||||
Kjartan Maraas.
|
Kjartan Maraas).
|
||||||
|
|
||||||
* NEWS: Updates
|
* NEWS: Updates
|
||||||
|
|
||||||
|
@ -194,13 +194,22 @@ gtk_clipboard_finalize (GObject *object)
|
|||||||
{
|
{
|
||||||
GtkClipboard *clipboard;
|
GtkClipboard *clipboard;
|
||||||
GtkWidget *clipboard_widget;
|
GtkWidget *clipboard_widget;
|
||||||
|
GSList *clipboards;
|
||||||
|
|
||||||
clipboard = GTK_CLIPBOARD (object);
|
clipboard = GTK_CLIPBOARD (object);
|
||||||
|
|
||||||
|
clipboards = g_object_get_data (G_OBJECT (clipboard->display), "gtk-clipboard-list");
|
||||||
|
if (g_slist_index (clipboards, clipboard) >= 0)
|
||||||
|
g_warning ("GtkClipboard prematurely finalized");
|
||||||
|
|
||||||
clipboard_widget = get_clipboard_widget (clipboard->display);
|
clipboard_widget = get_clipboard_widget (clipboard->display);
|
||||||
|
|
||||||
clipboard_unset (clipboard);
|
clipboard_unset (clipboard);
|
||||||
|
|
||||||
|
clipboards = g_object_get_data (G_OBJECT (clipboard->display), "gtk-clipboard-list");
|
||||||
|
clipboards = g_slist_remove (clipboards, clipboard);
|
||||||
|
g_object_set_data (G_OBJECT (clipboard->display), "gtk-clipboard-list", clipboards);
|
||||||
|
|
||||||
if (g_main_loop_is_running (clipboard->store_loop))
|
if (g_main_loop_is_running (clipboard->store_loop))
|
||||||
{
|
{
|
||||||
g_main_loop_quit (clipboard->store_loop);
|
g_main_loop_quit (clipboard->store_loop);
|
||||||
@ -227,10 +236,9 @@ clipboard_display_closed (GdkDisplay *display,
|
|||||||
|
|
||||||
clipboards = g_object_get_data (G_OBJECT (display), "gtk-clipboard-list");
|
clipboards = g_object_get_data (G_OBJECT (display), "gtk-clipboard-list");
|
||||||
g_object_run_dispose (G_OBJECT (clipboard));
|
g_object_run_dispose (G_OBJECT (clipboard));
|
||||||
g_object_unref (clipboard);
|
|
||||||
clipboards = g_slist_remove (clipboards, clipboard);
|
clipboards = g_slist_remove (clipboards, clipboard);
|
||||||
|
|
||||||
g_object_set_data (G_OBJECT (display), "gtk-clipboard-list", clipboards);
|
g_object_set_data (G_OBJECT (display), "gtk-clipboard-list", clipboards);
|
||||||
|
g_object_unref (clipboard);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -268,8 +276,9 @@ clipboard_display_closed (GdkDisplay *display,
|
|||||||
* Return value: the appropriate clipboard object. If no
|
* Return value: the appropriate clipboard object. If no
|
||||||
* clipboard already exists, a new one will
|
* clipboard already exists, a new one will
|
||||||
* be created. Once a clipboard object has
|
* be created. Once a clipboard object has
|
||||||
* been created, it is persistent for all time and
|
* been created, it is persistent and, since
|
||||||
* cannot be freed.
|
* it is owned by GTK+, must not be freed or
|
||||||
|
* unrefd.
|
||||||
*
|
*
|
||||||
* Since: 2.2
|
* Since: 2.2
|
||||||
**/
|
**/
|
||||||
@ -295,8 +304,9 @@ gtk_clipboard_get_for_display (GdkDisplay *display,
|
|||||||
* Return value: the appropriate clipboard object. If no
|
* Return value: the appropriate clipboard object. If no
|
||||||
* clipboard already exists, a new one will
|
* clipboard already exists, a new one will
|
||||||
* be created. Once a clipboard object has
|
* be created. Once a clipboard object has
|
||||||
* been created, it is persistent for all time and
|
* been created, it is persistent and, since
|
||||||
* cannot be freed.
|
* it is owned by GTK+, must not be freed or
|
||||||
|
* unrefd.
|
||||||
**/
|
**/
|
||||||
GtkClipboard *
|
GtkClipboard *
|
||||||
gtk_clipboard_get (GdkAtom selection)
|
gtk_clipboard_get (GdkAtom selection)
|
||||||
|
@ -2110,9 +2110,12 @@ update_node (GtkUIManager *self,
|
|||||||
menu = gtk_menu_item_get_submenu (GTK_MENU_ITEM (info->proxy));
|
menu = gtk_menu_item_get_submenu (GTK_MENU_ITEM (info->proxy));
|
||||||
siblings = gtk_container_get_children (GTK_CONTAINER (menu));
|
siblings = gtk_container_get_children (GTK_CONTAINER (menu));
|
||||||
if (siblings != NULL && GTK_IS_TEAROFF_MENU_ITEM (siblings->data))
|
if (siblings != NULL && GTK_IS_TEAROFF_MENU_ITEM (siblings->data))
|
||||||
g_object_set (G_OBJECT (siblings->data),
|
{
|
||||||
"visible", self->private_data->add_tearoffs && !in_popup,
|
if (self->private_data->add_tearoffs && !in_popup)
|
||||||
NULL);
|
gtk_widget_show (GTK_WIDGET (siblings->data));
|
||||||
|
else
|
||||||
|
gtk_widget_hide (GTK_WIDGET (siblings->data));
|
||||||
|
}
|
||||||
g_list_free (siblings);
|
g_list_free (siblings);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2207,9 +2210,12 @@ update_node (GtkUIManager *self,
|
|||||||
menu = gtk_menu_item_get_submenu (GTK_MENU_ITEM (info->proxy));
|
menu = gtk_menu_item_get_submenu (GTK_MENU_ITEM (info->proxy));
|
||||||
siblings = gtk_container_get_children (GTK_CONTAINER (menu));
|
siblings = gtk_container_get_children (GTK_CONTAINER (menu));
|
||||||
if (siblings != NULL && GTK_IS_TEAROFF_MENU_ITEM (siblings->data))
|
if (siblings != NULL && GTK_IS_TEAROFF_MENU_ITEM (siblings->data))
|
||||||
g_object_set (G_OBJECT (siblings->data),
|
{
|
||||||
"visible", self->private_data->add_tearoffs && !in_popup,
|
if (self->private_data->add_tearoffs && !in_popup)
|
||||||
NULL);
|
gtk_widget_show (GTK_WIDGET (siblings->data));
|
||||||
|
else
|
||||||
|
gtk_widget_hide (GTK_WIDGET (siblings->data));
|
||||||
|
}
|
||||||
g_list_free (siblings);
|
g_list_free (siblings);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user