diff options
author | Ulf Lamping <ulf.lamping@web.de> | 2004-06-21 05:48:15 +0000 |
---|---|---|
committer | Ulf Lamping <ulf.lamping@web.de> | 2004-06-21 05:48:15 +0000 |
commit | 527ad5b35d073e3628e46bb6173d70fb3550ba59 (patch) | |
tree | 12a3756764f7c5d1857e6e16fecdf5394804014a /gtk/file_dlg.c | |
parent | 4ee816d8841f2f6b4436e94c95f1d4ff999f17e4 (diff) |
use the "correct" resize function for the file selection dialog
svn path=/trunk/; revision=11202
Diffstat (limited to 'gtk/file_dlg.c')
-rw-r--r-- | gtk/file_dlg.c | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/gtk/file_dlg.c b/gtk/file_dlg.c index 46a0584bdc..28d0f42ba8 100644 --- a/gtk/file_dlg.c +++ b/gtk/file_dlg.c @@ -1,7 +1,7 @@ /* file_dlg.c * Dialog boxes for handling files * - * $Id: file_dlg.c,v 1.119 2004/06/20 18:36:16 ulfl Exp $ + * $Id: file_dlg.c,v 1.120 2004/06/21 05:48:15 ulfl Exp $ * * Ethereal - Network traffic analyzer * By Gerald Combs <gerald@ethereal.com> @@ -416,7 +416,13 @@ file_open_cmd(GtkWidget *w) file_open_w = file_selection_new("Ethereal: Open Capture File", FILE_SELECTION_OPEN); +#if (GTK_MAJOR_VERSION == 2 && GTK_MINOR_VERSION >= 4) || GTK_MAJOR_VERSION > 2 + /* it's annoying, that the file chooser dialog is already shown here, + so we cannot use the correct gtk_window_set_default_size() to resize it */ + WIDGET_SET_SIZE(GTK_WINDOW(file_open_w), DEF_WIDTH, DEF_HEIGHT); +#else gtk_window_set_default_size(GTK_WINDOW(file_open_w), DEF_WIDTH, DEF_HEIGHT); +#endif #if GTK_MAJOR_VERSION < 2 /* Accelerator group for the accelerators (or, as they're called in @@ -727,8 +733,13 @@ file_merge_cmd(GtkWidget *w) file_merge_w = file_selection_new("Ethereal: Merge with Capture File", FILE_SELECTION_OPEN); - /* window is already shown here, gtk_window_set_default_size() will not work */ - WIDGET_SET_SIZE(file_merge_w, DEF_WIDTH, DEF_HEIGHT); +#if (GTK_MAJOR_VERSION == 2 && GTK_MINOR_VERSION >= 4) || GTK_MAJOR_VERSION > 2 + /* it's annoying, that the file chooser dialog is already shown here, + so we cannot use the correct gtk_window_set_default_size() to resize it */ + WIDGET_SET_SIZE(GTK_WINDOW(file_open_w), DEF_WIDTH, DEF_HEIGHT); +#else + gtk_window_set_default_size(GTK_WINDOW(file_open_w), DEF_WIDTH, DEF_HEIGHT); +#endif #if GTK_MAJOR_VERSION < 2 /* Accelerator group for the accelerators (or, as they're called in |