diff options
author | Ulf Lamping <ulf.lamping@web.de> | 2004-05-23 23:24:07 +0000 |
---|---|---|
committer | Ulf Lamping <ulf.lamping@web.de> | 2004-05-23 23:24:07 +0000 |
commit | cc6836803788de14432c597fcda0ad3154b421e4 (patch) | |
tree | cd34c8b0e8333865247f8af8e7405c950d565350 /gtk/summary_dlg.c | |
parent | 9332549e99c7bee165fa47b3332e683d39cbcdad (diff) | |
download | wireshark-cc6836803788de14432c597fcda0ad3154b421e4.tar.gz wireshark-cc6836803788de14432c597fcda0ad3154b421e4.tar.bz2 wireshark-cc6836803788de14432c597fcda0ad3154b421e4.zip |
use new functions in window API (ui_util.h),
use window_new instead of dlg_window_new for the statistics windows
(as these are no dialog windows)
do some code cleanup
svn path=/trunk/; revision=10979
Diffstat (limited to 'gtk/summary_dlg.c')
-rw-r--r-- | gtk/summary_dlg.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/gtk/summary_dlg.c b/gtk/summary_dlg.c index c332711fac..8ac4a0ecb5 100644 --- a/gtk/summary_dlg.c +++ b/gtk/summary_dlg.c @@ -1,7 +1,7 @@ /* summary_dlg.c * Routines for capture file summary window * - * $Id: summary_dlg.c,v 1.32 2004/05/22 19:56:19 ulfl Exp $ + * $Id: summary_dlg.c,v 1.33 2004/05/23 23:24:06 ulfl Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@ethereal.com> @@ -107,7 +107,7 @@ summary_open_cb(GtkWidget *w _U_, gpointer d _U_) seconds = summary.stop_time - summary.start_time; disp_seconds = summary.filtered_stop - summary.filtered_start; - sum_open_w = dlg_window_new("Ethereal: Summary"); + sum_open_w = window_new(GTK_WINDOW_TOPLEVEL, "Ethereal: Summary"); /* Container for each row of widgets */ main_vb = gtk_vbox_new(FALSE, 12); @@ -303,14 +303,12 @@ summary_open_cb(GtkWidget *w _U_, gpointer d _U_) gtk_container_add(GTK_CONTAINER(main_vb), bbox); close_bt = OBJECT_GET_DATA(bbox, GTK_STOCK_CLOSE); - SIGNAL_CONNECT_OBJECT(close_bt, "clicked", gtk_widget_destroy, sum_open_w); - gtk_widget_grab_default(close_bt); + window_set_cancel_button(sum_open_w, close_bt, window_cancel_button_cb); + gtk_widget_grab_focus(close_bt); - /* Catch the "key_press_event" signal in the window, so that we can catch - the ESC key being pressed and act as if the "Close" button had - been selected. */ - dlg_set_cancel(sum_open_w, close_bt); + SIGNAL_CONNECT(sum_open_w, "delete_event", window_delete_event_cb, NULL); gtk_widget_show_all(sum_open_w); + window_present(sum_open_w); } |