[gtk+] widget: Unset window-unfocused in gtk_widget_unparent()
- From: Rui Matos <rtcm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] widget: Unset window-unfocused in gtk_widget_unparent()
- Date: Wed, 7 Dec 2011 22:45:59 +0000 (UTC)
commit 7a6babfd0270fe42bf81223178fcd3f94ebd1a05
Author: Rui Matos <tiagomatos gmail com>
Date: Fri Dec 2 15:21:20 2011 +0000
widget: Unset window-unfocused in gtk_widget_unparent()
Widgets without a parent aren't inside a toplevel window so we must remove
window-unfocused as it doesn't make sense outside a toplevel.
https://bugzilla.gnome.org/show_bug.cgi?id=661428
gtk/gtkwidget.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c
index daa5c29..8d772df 100644
--- a/gtk/gtkwidget.c
+++ b/gtk/gtkwidget.c
@@ -3784,6 +3784,9 @@ gtk_widget_unparent (GtkWidget *widget)
gtk_widget_queue_compute_expand (old_parent);
}
+ /* Unset window-unfocused since we are no longer inside a toplevel window */
+ gtk_widget_unset_state_flags (widget, GTK_STATE_FLAG_WINDOW_UNFOCUSED);
+
g_signal_emit (widget, widget_signals[PARENT_SET], 0, old_parent);
if (toplevel)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]