#if defined(__WXMSW__)
#include "wx/msw/apptbase.h"
-#else
+#elif defined(__UNIX__)
+ #include "wx/unix/apptbase.h"
+#else // no platform-specific methods to add to wxAppTraits
typedef
// wxAppTraits must be a class because it was forward declared as class
class WXDLLEXPORT wxAppTraits : public wxAppTraitsBase
class WXDLLEXPORT wxConsoleAppTraits : public wxConsoleAppTraitsBase
{
public:
- virtual bool CreateEndProcessPipe();
+ virtual bool CreateEndProcessPipe(wxExecuteData& execData);
virtual bool IsWriteFDOfEndProcessPipe(wxExecuteData& execData, int fd);
virtual void DetachWriteFDOfEndProcessPipe(wxExecuteData& execData);
virtual int WaitForChild(wxExecuteData& execData);
#include "wx/app.h"
#include "wx/intl.h"
#include "wx/list.h"
+ #include "wx/log.h"
#include "wx/msgdlg.h"
#endif
#endif
}
#else // !MSW, !Mac
- wxFputs(out, stderr);
+ // FIXME: why is wxFputs() not defined under Linux?
+ fputs(out.mb_str(), stderr);
fflush(stderr);
#endif // platform
}
#if wxUSE_TIMER
#ifndef WX_PRECOMP
+ #include "wx/timer.h"
#endif
// ----------------------------------------------------------------------------
// global data
//-----------------------------------------------------------------------------
-wxApp *wxTheApp = (wxApp *) NULL;
-wxAppInitializerFunction wxAppBase::m_appInitFn = (wxAppInitializerFunction) NULL;
-
bool g_mainThreadLocked = FALSE;
gint g_pendingTag = 0;
#include "wx/utils.h"
#include "wx/string.h"
+#include "wx/apptrait.h"
#include "wx/intl.h"
#include "wx/log.h"
return gdk_window_get_visual( wxGetRootWindow()->window )->depth;
}
-int wxGetOsVersion(int *majorVsn, int *minorVsn)
+int wxGUIAppTraits::GetOSVersion(int *majorVsn, int *minorVsn)
{
- if (majorVsn) *majorVsn = GTK_MAJOR_VERSION;
- if (minorVsn) *minorVsn = GTK_MINOR_VERSION;
+ if (majorVsn)
+ *majorVsn = GTK_MAJOR_VERSION;
+ if (minorVsn)
+ *minorVsn = GTK_MINOR_VERSION;
- return wxGTK;
+ return wxGTK;
}
wxWindow* wxFindWindowAtPoint(const wxPoint& pt)
// global data
//-----------------------------------------------------------------------------
-wxApp *wxTheApp = (wxApp *) NULL;
-wxAppInitializerFunction wxAppBase::m_appInitFn = (wxAppInitializerFunction) NULL;
-
bool g_mainThreadLocked = FALSE;
gint g_pendingTag = 0;
#include "wx/utils.h"
#include "wx/string.h"
+#include "wx/apptrait.h"
#include "wx/intl.h"
#include "wx/log.h"
return gdk_window_get_visual( wxGetRootWindow()->window )->depth;
}
-int wxGetOsVersion(int *majorVsn, int *minorVsn)
+int wxGUIAppTraits::GetOSVersion(int *majorVsn, int *minorVsn)
{
- if (majorVsn) *majorVsn = GTK_MAJOR_VERSION;
- if (minorVsn) *minorVsn = GTK_MINOR_VERSION;
+ if (majorVsn)
+ *majorVsn = GTK_MAJOR_VERSION;
+ if (minorVsn)
+ *minorVsn = GTK_MINOR_VERSION;
- return wxGTK;
+ return wxGTK;
}
wxWindow* wxFindWindowAtPoint(const wxPoint& pt)
#include "wx/intl.h"
#include "wx/log.h"
#include "wx/app.h"
+#include "wx/apptrait.h"
#include "wx/utils.h"
#include "wx/process.h"
bool wxGUIAppTraits::IsWriteFDOfEndProcessPipe(wxExecuteData& execData, int fd)
{
- return fd == execData.pipeEndProcDetect[wxPipe::Write]
+ return fd == (execData.pipeEndProcDetect)[wxPipe::Write];
}
void wxGUIAppTraits::DetachWriteFDOfEndProcessPipe(wxExecuteData& execData)