X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/bbfa03228a5fc1f23565cf59ee29629bc4336d65..7dee4b2ba05f613f75afa3994320a1b547bb04c3:/src/common/init.cpp?ds=sidebyside diff --git a/src/common/init.cpp b/src/common/init.cpp index 63cf1f4ece..0fa42d7d8f 100644 --- a/src/common/init.cpp +++ b/src/common/init.cpp @@ -17,12 +17,18 @@ // headers // ---------------------------------------------------------------------------- -#ifdef __GNUG__ - #pragma implementation "appbase.h" +#include "wx/wxprec.h" + +#ifdef __BORLANDC__ + #pragma hdrstop +#endif //__BORLANDC__ + +#ifndef WX_PRECOMP + #include "wx/app.h" + #include "wx/debug.h" #endif -#include "wx/app.h" -#include "wx/debug.h" +#include "wx/module.h" // ---------------------------------------------------------------------------- // global vars @@ -33,12 +39,6 @@ wxApp * WXDLLEXPORT wxTheApp = NULL; wxAppInitializerFunction wxAppBase::m_appInitFn = (wxAppInitializerFunction)NULL; -#if wxUSE_THREADS - // List of events pending processing - wxList *wxPendingEvents = NULL; - wxCriticalSection *wxPendingEventsLocker = NULL; -#endif // wxUSE_THREADS - // ---------------------------------------------------------------------------- // private classes // ---------------------------------------------------------------------------- @@ -46,7 +46,7 @@ wxAppInitializerFunction class /* no WXDLLEXPORT */ wxConsoleApp : public wxApp { public: - virtual int OnRun() { wxFAIL_MSG(T("unreachable")); return 0; } + virtual int OnRun() { wxFAIL_MSG(wxT("unreachable")); return 0; } }; // ---------------------------------------------------------------------------- @@ -59,6 +59,32 @@ static size_t gs_nInitCount = 0; // implementation // ============================================================================ +// ---------------------------------------------------------------------------- +// stubs for some GUI functions +// ---------------------------------------------------------------------------- + +void WXDLLEXPORT wxExit() +{ + abort(); +} + +// Yield to other apps/messages +bool WXDLLEXPORT wxYield() +{ + // do nothing + return TRUE; +} + +// Yield to other apps/messages +void WXDLLEXPORT wxWakeUpIdle() +{ + // do nothing +} + +// ---------------------------------------------------------------------------- +// wxBase-specific functions +// ---------------------------------------------------------------------------- + bool WXDLLEXPORT wxInitialize() { if ( gs_nInitCount ) @@ -68,7 +94,7 @@ bool WXDLLEXPORT wxInitialize() } wxASSERT_MSG( !wxTheApp, - T("either call wxInitialize or create app, not both!") ); + wxT("either call wxInitialize or create app, not both!") ); wxClassInfo::InitializeClasses();