diff options
author | Peter Wu <peter@lekensteyn.nl> | 2016-08-29 18:38:45 +0200 |
---|---|---|
committer | Peter Wu <peter@lekensteyn.nl> | 2016-09-01 08:27:59 +0000 |
commit | 77ae30ffc598a56e71e0f57e151d0b6801110b03 (patch) | |
tree | b9d073c9c77e93b5ab130bbae33768cef779d965 /ui/gtk/fileset_dlg.c | |
parent | 717ca58264f1c745c3efb8d9da0050d52b51bb1f (diff) |
gtk: fix compilation with GTK+ before 2.18
Removed in v1.99.2rc0-399-g43f09e6, but some includes are still needed.
Basically I looked for the functions defined in the
ui/gtk/old-gtk-compat.h header file that were in files below ui/gtk/.
Then I matched it against the removed part in the above commit and added
the header back at its old place. In two other cases, the header was
only needed for Windows.
If the above commit did not reference the file, I checked which function
was in use and added the header on top, removing redundant conditionals.
Reported and tested by a user of GTK+ 2.12.12 on top of v2.0.5.
Change-Id: I649eec1e5531070f88c99d893c4920306f56d849
Reviewed-on: https://code.wireshark.org/review/17371
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Diffstat (limited to 'ui/gtk/fileset_dlg.c')
-rw-r--r-- | ui/gtk/fileset_dlg.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/ui/gtk/fileset_dlg.c b/ui/gtk/fileset_dlg.c index fb0aadba18..bb0e04d7fe 100644 --- a/ui/gtk/fileset_dlg.c +++ b/ui/gtk/fileset_dlg.c @@ -37,6 +37,7 @@ #include "ui/gtk/menus.h" #include "ui/gtk/help_dlg.h" #include "ui/gtk/fileset_dlg.h" +#include "ui/gtk/old-gtk-compat.h" @@ -213,11 +214,7 @@ fileset_dlg_add_file(fileset_entry *entry, void *window _U_) { if (row <= 18) { GtkRequisition requisition; -#if GTK_CHECK_VERSION(3,0,0) gtk_widget_get_preferred_size(fs_grid, &requisition, NULL); -#else - gtk_widget_size_request(fs_grid, &requisition); -#endif /* XXX use gtk_window_set_default_size()? */ gtk_widget_set_size_request(fs_sw, -1, requisition.height); gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(fs_sw), GTK_POLICY_NEVER, GTK_POLICY_NEVER); |