From d30ef769524e1e8bc720ff1713b8d928be0a335e Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Thu, 11 Sep 2008 11:20:33 +0000 Subject: [PATCH] get rid of __WXCOCOA__ check in common CreateLogTarget(), the right way to do this is to override wxUSE_LOG_DIALOG option in wxCocoa-specific chkconf.h git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@55546 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/chkconf.h | 2 ++ include/wx/cocoa/chkconf.h | 22 ++++++++++++++++++++++ src/common/appcmn.cpp | 4 +--- 3 files changed, 25 insertions(+), 3 deletions(-) create mode 100644 include/wx/cocoa/chkconf.h diff --git a/include/wx/chkconf.h b/include/wx/chkconf.h index 36095513db..5ba0f6c5d2 100644 --- a/include/wx/chkconf.h +++ b/include/wx/chkconf.h @@ -1022,6 +1022,8 @@ # include "wx/msw/chkconf.h" #elif defined(__WXGTK__) # include "wx/gtk/chkconf.h" +#elif defined(__WXCOCOA__) +# include "wx/cocoa/chkconf.h" #elif defined(__WXMAC__) # include "wx/osx/chkconf.h" #elif defined(__OS2__) diff --git a/include/wx/cocoa/chkconf.h b/include/wx/cocoa/chkconf.h new file mode 100644 index 0000000000..738df173f6 --- /dev/null +++ b/include/wx/cocoa/chkconf.h @@ -0,0 +1,22 @@ +/* + * Name: wx/cocoa/chkconf.h + * Purpose: wxCocoa-specific config settings checks + * Author: Vadim Zeitlin + * Created: 2008-09-11 + * RCS-ID: $Id$ + * Copyright: (c) 2008 Vadim Zeitlin + * Licence: wxWindows licence + */ + +/* THIS IS A C FILE, DON'T USE C++ FEATURES (IN PARTICULAR COMMENTS) IN IT */ + +#ifndef _WX_COCOA_CHKCONF_H_ +#define _WX_COCOA_CHKCONF_H_ + +/* + wxLogDialog doesn't currently work correctly in wxCocoa. + */ +#undef wxUSE_LOG_DIALOG +#define wxUSE_LOG_DIALOG 0 + +#endif // _WX_COCOA_CHKCONF_H_ diff --git a/src/common/appcmn.cpp b/src/common/appcmn.cpp index 2df9a21aaf..41f3958d47 100644 --- a/src/common/appcmn.cpp +++ b/src/common/appcmn.cpp @@ -419,9 +419,7 @@ bool wxAppBase::SendIdleEvents(wxWindow* win, wxIdleEvent& event) wxLog *wxGUIAppTraitsBase::CreateLogTarget() { -// DE: One day I'll remove this but right now the generic dialog used for this -// just doesn't work right at all on wxCocoa. -#if wxUSE_LOGGUI && !defined(__WXCOCOA__) +#if wxUSE_LOGGUI return new wxLogGui; #else // we must have something! -- 2.45.2