diff options
author | Ulf Lamping <ulf.lamping@web.de> | 2004-05-26 03:49:24 +0000 |
---|---|---|
committer | Ulf Lamping <ulf.lamping@web.de> | 2004-05-26 03:49:24 +0000 |
commit | 7d37fc9d23181cc3dfb42d42d2655a9b97ac6062 (patch) | |
tree | 1dd3c8757f1727f8591869b656d047a48c05c477 /gtk/proto_draw.c | |
parent | 3aaf65db46a1afc054911564f12a45ec2af63274 (diff) |
more code cleanup from dialog things:
changed window_xy (dialog) function calling in a lot of gtk files
cleanup of file selection code
cleanup in dlg_utils/file_dlg/ui_util
Please report any problems!!!
svn path=/trunk/; revision=11003
Diffstat (limited to 'gtk/proto_draw.c')
-rw-r--r-- | gtk/proto_draw.c | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/gtk/proto_draw.c b/gtk/proto_draw.c index 6d190fd058..2bd1d019a6 100644 --- a/gtk/proto_draw.c +++ b/gtk/proto_draw.c @@ -1,7 +1,7 @@ /* proto_draw.c * Routines for GTK+ packet display * - * $Id: proto_draw.c,v 1.100 2004/05/23 23:24:06 ulfl Exp $ + * $Id: proto_draw.c,v 1.101 2004/05/26 03:49:24 ulfl Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@ethereal.com> @@ -792,6 +792,14 @@ savehex_dlg_destroy_cb(void) savehex_dlg = NULL; } +static void +savehex_browse_file_cb(GtkWidget *file_bt, GtkWidget *file_te) +{ + file_selection_browse(file_bt, file_te, + "Ethereal: Export Selected Packet Bytes", FILE_SELECTION_SAVE); +} + + /* Forward declaration */ static void savehex_save_clicked_cb(GtkWidget * w, gpointer data); @@ -865,12 +873,7 @@ void savehex_cb(GtkWidget * w _U_, gpointer data _U_) /* File Browse button */ file_bt=BUTTON_NEW_FROM_STOCK(ETHEREAL_STOCK_BROWSE); - SIGNAL_CONNECT(file_bt, "clicked", select_file_cb, - "Ethereal: Export Selected Packet Bytes"); - - /* file entry for print dialog */ - OBJECT_SET_DATA(file_bt, E_FILE_TE_PTR_KEY, file_entry); - /* file entry for print dialog */ + SIGNAL_CONNECT(file_bt, "clicked", savehex_browse_file_cb, file_entry); gtk_tooltips_set_tip (tooltips, file_bt, ("Browse output filename in filesystem"), NULL); gtk_box_pack_start(GTK_BOX(file_box), file_bt, FALSE, TRUE, 0); @@ -966,7 +969,7 @@ savehex_save_clicked_cb(GtkWidget * w _U_, gpointer data _U_) } /* Get rid of the dialog box */ - gtk_widget_destroy(GTK_WIDGET(savehex_dlg)); + window_destroy(GTK_WIDGET(savehex_dlg)); } /* Update the progress bar this many times when reading a file. */ |