From: Mattia Barbon Date: Thu, 18 Aug 2005 00:35:02 +0000 (+0000) Subject: Avoid some -Wundef warning. Check for __WXGTK__ using defined, X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/8c624a14ad2e1c8cef5e382e715324b4f1f090e3 Avoid some -Wundef warning. Check for __WXGTK__ using defined, not plain #if. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@35218 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/setup.h.in b/setup.h.in index 41ac395a69..3094b511cf 100644 --- a/setup.h.in +++ b/setup.h.in @@ -507,6 +507,8 @@ #define wxUSE_DC_CACHEING 0 +#define wxUSE_GADGETS 0 + /* * Supports bool type */ diff --git a/src/common/popupcmn.cpp b/src/common/popupcmn.cpp index 5150d08a04..e29d8d2619 100644 --- a/src/common/popupcmn.cpp +++ b/src/common/popupcmn.cpp @@ -259,7 +259,7 @@ void wxPopupTransientWindow::Popup(wxWindow *winFocus) // subclass the window which has the focus, and not winFocus passed in or // otherwise everything else breaks down m_focus = FindFocus(); -#elif __WXGTK__ +#elif defined(__WXGTK__) // GTK+ catches the activate events from the popup // window, not the focus events from the child window m_focus = this; diff --git a/src/motif/choice.cpp b/src/motif/choice.cpp index 24857bdf41..8ce104a578 100644 --- a/src/motif/choice.cpp +++ b/src/motif/choice.cpp @@ -189,7 +189,7 @@ wxChoice::~wxChoice() int wxChoice::DoAppend(const wxString& item) { Widget w = XtVaCreateManagedWidget (wxStripMenuCodes(item), -#if USE_GADGETS +#if wxUSE_GADGETS xmPushButtonGadgetClass, (Widget) m_menuWidget, #else xmPushButtonWidgetClass, (Widget) m_menuWidget, diff --git a/src/motif/statbmp.cpp b/src/motif/statbmp.cpp index 5d39f69069..f576c57c84 100644 --- a/src/motif/statbmp.cpp +++ b/src/motif/statbmp.cpp @@ -55,7 +55,7 @@ bool wxStaticBitmap::Create(wxWindow *parent, wxWindowID id, Widget parentWidget = (Widget) parent->GetClientWidget(); m_mainWidget = (WXWidget) XtVaCreateManagedWidget ("staticBitmap", -#if USE_GADGETS +#if wxUSE_GADGETS xmLabelGadgetClass, parentWidget, #else xmLabelWidgetClass, parentWidget,