Avoid many -Wparentheses warnings from gtk/gtk.h with gcc8

Add wx/gtk/private/wrapgtk.h wrapping gtk/gtk.h in pragmas disabling
these warnings and include it everywhere instead of directly including
gtk/gtk.h.

Also include wx/gtk/private/gtk2-compat.h from this wrapper header as it
was included by 90% of the files including gtk/gtk.h itself and it seems
to be better and simpler to just always include it.
This commit is contained in:
Vadim Zeitlin
2018-05-20 18:43:16 +02:00
parent 8401d3fec9
commit c0b0562533
86 changed files with 79 additions and 164 deletions

View File

@@ -11,10 +11,9 @@
#ifndef _WX_GTK_PRIVATE_H_
#define _WX_GTK_PRIVATE_H_
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#include "wx/gtk/private/string.h"
#include "wx/gtk/private/gtk2-compat.h"
#ifndef G_VALUE_INIT
// introduced in GLib 2.30

View File

@@ -14,7 +14,7 @@
#include "wx/bmpbuttn.h"
#include "wx/toolbar.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
// ----------------------------------------------------------------------------
// wxAddRemoveImpl

View File

@@ -0,0 +1,19 @@
///////////////////////////////////////////////////////////////////////////////
// Name: wx/gtk/private/wrapgtk.h
// Purpose: Include gtk/gtk.h without warnings and with compatibility
// Author: Vadim Zeitlin
// Created: 2018-05-20
// Copyright: (c) 2018 Vadim Zeitlin <vadim@wxwidgets.org>
// Licence: wxWindows licence
///////////////////////////////////////////////////////////////////////////////
#ifndef _WX_GTK_PRIVATE_WRAPGTK_H_
#define _WX_GTK_PRIVATE_WRAPGTK_H_
wxGCC_WARNING_SUPPRESS(parentheses)
#include <gtk/gtk.h>
wxGCC_WARNING_RESTORE(parentheses)
#include "wx/gtk/private/gtk2-compat.h"
#endif // _WX_GTK_PRIVATE_WRAPGTK_H_

View File

@@ -38,8 +38,6 @@
typedef HWND wxNativeContainerWindowHandle;
typedef HWND wxNativeWindowHandle;
#elif defined(__WXGTK__)
#include <gtk/gtk.h>
// GdkNativeWindow is guint32 under GDK/X11 and gpointer under GDK/WIN32
#ifdef __UNIX__
typedef unsigned long wxNativeContainerWindowId;

View File

@@ -143,6 +143,8 @@ protected:
#elif defined(__WXGTK__)
#include <gtk/gtk.h>
class NativeWindow : public wxNativeWindow
{
public:

View File

@@ -42,13 +42,8 @@
#endif
#ifdef __WXGTK__
#include <gtk/gtk.h>
#include "wx/renderer.h"
#ifdef __WXGTK20__
#include "wx/gtk/private/gtk2-compat.h"
#else
#define gtk_widget_is_drawable GTK_WIDGET_DRAWABLE
#endif
#include "wx/gtk/private/wrapgtk.h"
#ifdef __WXGTK3__
#include "wx/graphics.h"
#include "wx/gtk/private.h"

View File

@@ -222,8 +222,7 @@ wxEND_EVENT_TABLE()
#else
// __WXGTK20__
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
static void
gtk_pseudo_window_realized_callback( GtkWidget *m_widget, void *WXUNUSED(win) )

View File

@@ -36,8 +36,6 @@
#include "wx/gtk/dc.h"
#include "wx/gtk/private.h"
#include <gtk/gtk.h>
#include "wx/aui/auibook.h"
#include "wx/aui/tabartgtk.h"
#include "wx/renderer.h"

View File

@@ -42,12 +42,7 @@
#endif // __WXUNIVERSAL__
#ifdef __WXGTK__
#include <gtk/gtk.h>
#if GTK_CHECK_VERSION(2,0,0)
#include "wx/gtk/private/gtk2-compat.h"
#else
#define gtk_widget_get_window(x) x->window
#endif
#include "wx/gtk/private/wrapgtk.h"
#elif defined(__WXMSW__)
#include "wx/msw/private.h"
#elif defined(__WXX11__)

View File

@@ -104,7 +104,7 @@
#endif
#if wxUSE_GUI && defined(__WXGTK__)
#include <gtk/gtk.h> // for GTK_XXX_VERSION constants
#include "wx/gtk/private/wrapgtk.h" // for GTK_XXX_VERSION constants
#endif
#if wxUSE_GUI && defined(__WXQT__)

View File

@@ -83,7 +83,7 @@ using namespace std;
#endif
#ifdef __WXGTK__
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#include "wx/fontutil.h"
#ifndef __WXGTK3__
#include "wx/gtk/dc.h"

View File

@@ -18,7 +18,7 @@
#if wxUSE_SPLASH
#ifdef __WXGTK20__
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#endif
#include "wx/splash.h"

View File

@@ -27,9 +27,7 @@
#endif
#ifdef __WXGTK20__
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#endif
// we only have to do it here when we use wxStatusBarGeneric in addition to the

View File

@@ -26,9 +26,7 @@
#include "wx/window.h"
#endif //WX_PRECOMP
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
// ----------------------------------------------------------------------------
// GtkArray: temporary array of GTK strings

View File

@@ -28,8 +28,7 @@
#include "wx/math.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
// Macro return the specified expression only if GTK+ run time version is less
// than 2.20 and compiling it only if it is less than 3.0 (which is why this

View File

@@ -25,8 +25,6 @@
#include "wx/gtk/private.h"
#include "wx/gtk/private/object.h"
#include <gtk/gtk.h>
// ============================================================================
// implementation

View File

@@ -18,8 +18,7 @@
#include "wx/stockitem.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
// ----------------------------------------------------------------------------
// GTK callbacks

View File

@@ -28,7 +28,6 @@
#include "wx/apptrait.h"
#include "wx/fontmap.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/mimetype.h"

View File

@@ -21,7 +21,6 @@
#include "wx/artprov.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#if !GTK_CHECK_VERSION(2,8,0)

View File

@@ -10,10 +10,8 @@
#if wxDEBUG_LEVEL
#include <gtk/gtk.h>
#include "wx/gtk/assertdlg_gtk.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private.h"
#include "wx/gtk/assertdlg_gtk.h"
#include "wx/gtk/private/mnemonics.h"
#include "wx/translation.h"
#include "wx/stockitem.h"

View File

@@ -23,8 +23,6 @@
#include "wx/gtk/private/object.h"
#include "wx/gtk/private.h"
#include <gtk/gtk.h>
GdkWindow* wxGetTopLevelGDK();
#ifndef __WXGTK3__

View File

@@ -29,7 +29,6 @@
#include "wx/log.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
// ============================================================================

View File

@@ -17,9 +17,7 @@
#include "wx/stockitem.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/list.h"
// ----------------------------------------------------------------------------

View File

@@ -19,7 +19,7 @@
#include "wx/calctrl.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
extern "C" {

View File

@@ -13,8 +13,7 @@
#include "wx/checkbox.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
#include "wx/gtk/private/eventsdisabler.h"
//-----------------------------------------------------------------------------

View File

@@ -14,7 +14,6 @@
#include "wx/checklst.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/treeview.h"

View File

@@ -16,9 +16,7 @@
#include "wx/arrstr.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/eventsdisabler.h"
// ----------------------------------------------------------------------------

View File

@@ -20,7 +20,7 @@
#include "wx/clrpicker.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
// ============================================================================
// implementation

View File

@@ -23,9 +23,7 @@
#include "wx/sizer.h"
#include "wx/panel.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
// the lines below duplicate the same definitions in collpaneg.cpp, if we have
// another implementation of this class we should extract them to a common file

View File

@@ -23,9 +23,7 @@
#include "wx/intl.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/dialogcount.h"
extern "C" {

View File

@@ -20,9 +20,7 @@
#include "wx/arrstr.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
// ----------------------------------------------------------------------------
// GTK callbacks

View File

@@ -22,7 +22,6 @@
#include "wx/utils.h"
#include "wx/sysopt.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/mnemonics.h"

View File

@@ -18,9 +18,8 @@
#include "wx/log.h"
#endif // WX_PRECOMP
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#include "wx/gtk/private/object.h"
#include "wx/gtk/private/gtk2-compat.h"
GdkWindow* wxGetTopLevelGDK();

View File

@@ -32,11 +32,9 @@
#include "wx/gtk/dcclient.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/event.h"
#include "wx/gtk/private/gdkconv.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/list.h"
#include "wx/gtk/private/treeview.h"
using namespace wxGTKImpl;

View File

@@ -19,7 +19,7 @@
#include "wx/icon.h"
#include "wx/gtk/dc.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
wxGTKCairoDCImpl::wxGTKCairoDCImpl(wxDC* owner)
: wxGCDCImpl(owner)

View File

@@ -11,7 +11,7 @@
#include "wx/gtk/dcmemory.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
//-----------------------------------------------------------------------------
// wxMemoryDCImpl

View File

@@ -11,7 +11,7 @@
#include "wx/gtk/dcscreen.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
//-----------------------------------------------------------------------------
// wxScreenDCImpl

View File

@@ -19,8 +19,7 @@
#include "wx/scopedptr.h"
#include "wx/modalhook.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
#include "wx/gtk/private/dialogcount.h"
wxDEFINE_TIED_SCOPED_PTR_TYPE(wxGUIEventLoop)

View File

@@ -14,11 +14,10 @@
#endif
#include "wx/utils.h" // wxClientDisplayRect
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#ifdef GDK_WINDOWING_X11
#include <gdk/gdkx.h>
#endif
#include "wx/gtk/private/gtk2-compat.h"
#if !defined(GDK_WINDOWING_WIN32)

View File

@@ -24,8 +24,7 @@
#include "wx/scopeguard.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
//----------------------------------------------------------------------------
// global data

View File

@@ -34,8 +34,7 @@
#include "wx/private/eventloopsourcesmanager.h"
#include "wx/apptrait.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
GdkWindow* wxGetTopLevelGDK();

View File

@@ -19,7 +19,6 @@
#include "wx/msgdlg.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/mnemonics.h"

View File

@@ -28,10 +28,8 @@
#include "wx/filename.h"
#include <glib.h>
#include <gtk/gtk.h>
#include "wx/gtk/private/string.h"
#include "wx/gtk/private.h"
#include "wx/gtk/private/string.h"
// ============================================================================
// implementation

View File

@@ -25,7 +25,6 @@
#include "wx/filepicker.h"
#include "wx/tooltip.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
// ============================================================================

View File

@@ -17,8 +17,7 @@
#include "wx/statusbr.h"
#endif // WX_PRECOMP
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
// ----------------------------------------------------------------------------
// event tables

View File

@@ -13,7 +13,7 @@
#include "wx/gauge.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
//-----------------------------------------------------------------------------
// wxGauge

View File

@@ -15,9 +15,8 @@
#include "wx/glcanvas.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#include <gdk/gdkx.h>
#include "wx/gtk/private/gtk2-compat.h"
#if WXWIN_COMPATIBILITY_2_8

View File

@@ -29,7 +29,6 @@
#ifndef WX_PRECOMP
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
// ----------------------------------------------------------------------------

View File

@@ -28,15 +28,14 @@
#include "wx/tooltip.h"
#endif
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/eventsdisabler.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/object.h"
#include "wx/gtk/private/treeentry_gtk.h"
#include "wx/gtk/private/treeview.h"
#include <gdk/gdkkeysyms.h>
//-----------------------------------------------------------------------------
// data
//-----------------------------------------------------------------------------

View File

@@ -25,9 +25,7 @@
#include "wx/accel.h"
#include "wx/stockitem.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/mnemonics.h"
// Number of currently open modal dialogs, defined in src/gtk/toplevel.cpp.

View File

@@ -13,11 +13,10 @@
#include "wx/gtk/mimetype.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#include "wx/gtk/private/string.h"
#include "wx/gtk/private/object.h"
#include "wx/gtk/private/gtk2-compat.h"
#if defined(__UNIX__)
wxString wxGTKMimeTypesManagerImpl::GetIconFromMimeType(const wxString& mime)

View File

@@ -24,8 +24,7 @@
#include "wx/gtk/dcclient.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
#include "wx/gtk/private/gtk3-compat.h"
//-----------------------------------------------------------------------------

View File

@@ -25,7 +25,6 @@
#include "wx/modalhook.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/messagetype.h"
#include "wx/gtk/private/mnemonics.h"

View File

@@ -27,8 +27,7 @@
#include "wx/nativewin.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
#ifdef GDK_WINDOWING_X11
#include <gdk/gdkx.h>

View File

@@ -31,8 +31,7 @@
#include "wx/graphics.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
// ----------------------------------------------------------------------------
// wxNonOwnedWindowShapeImpl: base class for region and path-based classes.

View File

@@ -24,9 +24,7 @@
#include "wx/imaglist.h"
#include "wx/fontutil.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
//-----------------------------------------------------------------------------
// wxGtkNotebookPage

View File

@@ -16,7 +16,7 @@
#ifndef WX_PRECOMP
#endif // WX_PRECOMP
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#include "wx/gtk/private/win_gtk.h"

View File

@@ -34,7 +34,7 @@
#include "wx/paper.h"
#include "wx/modalhook.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#if GTK_CHECK_VERSION(2,14,0)
#include <gtk/gtkunixprint.h>
@@ -46,7 +46,6 @@
wxFORCE_LINK_THIS_MODULE(gtk_print)
#include "wx/gtk/private/object.h"
#include "wx/gtk/private/gtk2-compat.h"
// Useful to convert angles from degrees to radians.
static const double DEG2RAD = M_PI / 180.0;

View File

@@ -27,7 +27,6 @@
#include "wx/module.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
// ----------------------------------------------------------------------------

View File

@@ -17,10 +17,9 @@
#include "wx/tooltip.h"
#endif
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include <gdk/gdkkeysyms.h>
//-----------------------------------------------------------------------------
// wxGTKRadioButtonInfo

View File

@@ -13,9 +13,7 @@
#include "wx/radiobut.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
//-----------------------------------------------------------------------------
// data

View File

@@ -37,9 +37,7 @@
#include "wx/gtk/dc.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#if defined(__WXGTK3__) && !GTK_CHECK_VERSION(3,14,0)
#define GTK_STATE_FLAG_CHECKED (1 << 11)

View File

@@ -18,8 +18,7 @@
#include "wx/scrolwin.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
// ----------------------------------------------------------------------------
// wxScrollHelper implementation

View File

@@ -20,9 +20,8 @@
#include "wx/fontutil.h"
#include "wx/fontenum.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#include "wx/gtk/private/win_gtk.h"
#include "wx/gtk/private/gtk2-compat.h"
bool wxGetFrameExtents(GdkWindow* window, int* left, int* right, int* top, int* bottom);

View File

@@ -18,8 +18,7 @@
#include "wx/math.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
#include "wx/gtk/private/eventsdisabler.h"
//-----------------------------------------------------------------------------

View File

@@ -14,7 +14,7 @@
#include "wx/spinbutt.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
//-----------------------------------------------------------------------------
// data

View File

@@ -20,9 +20,7 @@
#include "wx/wxcrtvararg.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
//-----------------------------------------------------------------------------
// data

View File

@@ -13,7 +13,7 @@
#include "wx/statbmp.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
//-----------------------------------------------------------------------------
// wxStaticBitmap

View File

@@ -13,8 +13,7 @@
#include "wx/statbox.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
#include "wx/gtk/private/win_gtk.h"
// constants taken from GTK sources

View File

@@ -13,8 +13,7 @@
#if wxUSE_STATLINE
#include <gtk/gtk.h>
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/wrapgtk.h"
//-----------------------------------------------------------------------------
// wxStaticLine

View File

@@ -13,7 +13,6 @@
#include "wx/stattext.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
//-----------------------------------------------------------------------------

View File

@@ -23,14 +23,13 @@
#include "wx/icon.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#ifdef GDK_WINDOWING_X11
#include <gdk/gdkx.h>
#endif
#ifndef __WXGTK3__
#include "eggtrayicon.h"
#endif
#include "wx/gtk/private/gtk2-compat.h"
wxGCC_WARNING_SUPPRESS(deprecated-declarations)

View File

@@ -29,9 +29,7 @@
#include <sys/stat.h>
#include <ctype.h>
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/gtk3-compat.h"
// ----------------------------------------------------------------------------

View File

@@ -33,9 +33,7 @@
#include "wx/textcompleter.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/object.h"
#include "wx/gtk/private/string.h"

View File

@@ -20,7 +20,6 @@
#include "wx/button.h"
#endif
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/eventsdisabler.h"
#include "wx/gtk/private/list.h"

View File

@@ -14,7 +14,7 @@
#include "wx/gtk/private/timer.h"
#include "wx/app.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
// ----------------------------------------------------------------------------
// wxTimerImpl

View File

@@ -14,9 +14,7 @@
#include "wx/toolbar.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/gtk3-compat.h"
// ----------------------------------------------------------------------------

View File

@@ -32,18 +32,16 @@
#include "wx/evtloop.h"
#include "wx/sysopt.h"
#include <gtk/gtk.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk3-compat.h"
#include "wx/gtk/private/win_gtk.h"
#ifdef GDK_WINDOWING_X11
#include <gdk/gdkx.h>
#include <X11/Xatom.h> // XA_CARDINAL
#include "wx/unix/utilsx11.h"
#endif
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/gtk3-compat.h"
#include "wx/gtk/private/win_gtk.h"
// ----------------------------------------------------------------------------
// data
// ----------------------------------------------------------------------------

View File

@@ -25,7 +25,7 @@
#include "wx/gtk/private/timer.h"
#include "wx/evtloop.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#ifdef GDK_WINDOWING_WIN32
#include <gdk/gdkwin32.h>
#endif
@@ -54,8 +54,6 @@
#include "wx/unix/utilsx11.h"
#endif
#include "wx/gtk/private/gtk2-compat.h"
GdkWindow* wxGetTopLevelGDK();
//----------------------------------------------------------------------------

View File

@@ -8,13 +8,8 @@
#include "wx/wxprec.h"
#include "wx/defs.h"
#include <gtk/gtk.h>
#include "wx/gtk/private/win_gtk.h"
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/win_gtk.h"
/*
wxPizza is a custom GTK+ widget derived from GtkFixed. A custom widget

View File

@@ -37,16 +37,15 @@
#include <ctype.h>
#include <gtk/gtk.h>
#include <gdk/gdkkeysyms.h>
#include "wx/gtk/private.h"
#include "wx/gtk/private/gtk2-compat.h"
#include "wx/gtk/private/gtk3-compat.h"
#include "wx/gtk/private/event.h"
#include "wx/gtk/private/win_gtk.h"
#include "wx/private/textmeasure.h"
using namespace wxGTKImpl;
#include <gdk/gdkkeysyms.h>
#ifdef GDK_WINDOWING_X11
#include <gdk/gdkx.h>
#include "wx/x11/private/wrapxkb.h"

View File

@@ -34,9 +34,8 @@
#include "wx/vector.h" // wxVector<wxString>
#ifdef __WXGTK__
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#include <gdk/gdkx.h>
#include "wx/gtk/private/gtk2-compat.h"
#endif
//-----------------------------------------------------------------------------

View File

@@ -28,9 +28,8 @@
#include "wx/vector.h" // wxVector<wxString>
#ifdef __WXGTK__
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#include <gdk/gdkx.h>
#include "wx/gtk/private/gtk2-compat.h"
#endif
//=============================================================================

View File

@@ -64,7 +64,7 @@
// ----------------------------------------------------------------------------
#if defined(__WXGTK__)
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#include <gdk/gdkx.h>
#define GetDisplay() GDK_DISPLAY()
#define GetXWindow(wxwin) GDK_WINDOW_XWINDOW((wxwin)->m_widget->window)

View File

@@ -28,7 +28,7 @@
#include "wx/unix/utilsx11.h"
#ifdef __WXGTK3__
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
GtkWidget* wxGetTopLevelGTK();
#endif

View File

@@ -37,12 +37,9 @@
#endif
#ifdef __WXGTK__
#include <gtk/gtk.h>
#include "wx/gtk/private/wrapgtk.h"
#ifdef GDK_WINDOWING_X11
#include <gdk/gdkx.h>
#ifdef __WXGTK20__
#include "wx/gtk/private/gtk2-compat.h" // gdk_window_get_screen()
#endif
#endif
GdkWindow* wxGetTopLevelGDK();
GtkWidget* wxGetTopLevelGTK();