Connect the destroy signal in the example instead of the ui file. Also set

* demos/gtk-demo/builder.c (do_builder): Connect the
    destroy signal in the example instead of the ui file.
    Also set the screen and title of the window.
    (#451345, Thomas Rydzynski)


svn path=/trunk/; revision=18251
This commit is contained in:
Johan Dahlin 2007-06-27 00:23:56 +00:00
parent a992482da2
commit 1d2955bcaf
3 changed files with 12 additions and 1 deletions

View File

@ -1,3 +1,10 @@
2007-06-26 Johan Dahlin <jdahlin@async.com.br>
* demos/gtk-demo/builder.c (do_builder): Connect the
destroy signal in the example instead of the ui file.
Also set the screen and title of the window.
(#451345, Thomas Rydzynski)
2007-06-26 Richard Hult <richard@imendio.com>
* gtk/gtkbuilder.c: (gtk_builder_value_from_string_type): Fix a

View File

@ -43,6 +43,10 @@ do_builder (GtkWidget *do_widget)
}
gtk_builder_connect_signals (builder, NULL);
window = GTK_WIDGET (gtk_builder_get_object (builder, "window1"));
gtk_window_set_screen (GTK_WINDOW (window),
gtk_widget_get_screen (do_widget));
g_signal_connect (window, "destroy",
G_CALLBACK (gtk_widget_destroyed), &window);
}
if (!GTK_WIDGET_VISIBLE (window))

View File

@ -141,7 +141,7 @@
<object class="GtkWindow" id="window1">
<property name="default_height">250</property>
<property name="default_width">440</property>
<signal name="destroy" handler="gtk_widget_destroyed"/>
<property name="title">builder</property>
<child>
<object class="GtkVBox" id="vbox1">
<property name="visible">True</property>