[gtk+] demos/gtk-demo/infobar.c: Do not use gtk_dialog_run()
- From: Javier JardÃn <jjardon src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] demos/gtk-demo/infobar.c: Do not use gtk_dialog_run()
- Date: Mon, 27 Feb 2012 17:13:49 +0000 (UTC)
commit f8ca9a86b2db668f7f36a2a95a3fae739a3f6257
Author: Javier JardÃn <jjardon gnome org>
Date: Mon Feb 27 11:07:08 2012 +0000
demos/gtk-demo/infobar.c: Do not use gtk_dialog_run()
demos/gtk-demo/infobar.c | 9 +++++++--
1 files changed, 7 insertions(+), 2 deletions(-)
---
diff --git a/demos/gtk-demo/infobar.c b/demos/gtk-demo/infobar.c
index d717852..0cb58e6 100644
--- a/demos/gtk-demo/infobar.c
+++ b/demos/gtk-demo/infobar.c
@@ -21,8 +21,13 @@ on_bar_response (GtkInfoBar *info_bar,
"You clicked a button on an info bar");
gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (dialog),
"Your response has id %d", response_id);
- gtk_dialog_run (GTK_DIALOG (dialog));
- gtk_widget_destroy (dialog);
+
+ g_signal_connect_swapped (dialog,
+ "response",
+ G_CALLBACK (gtk_widget_destroy),
+ dialog);
+
+ gtk_widget_show_all (dialog);
}
GtkWidget *
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]