wxBase/GUI separation: 1st step, wxMSW should build, all the rest is broken
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@21342 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -32,23 +32,15 @@
|
||||
|
||||
#include "wx/module.h"
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// global vars
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
WXDLLEXPORT wxApp *wxTheApp = NULL;
|
||||
|
||||
wxAppInitializerFunction
|
||||
wxAppBase::m_appInitFn = (wxAppInitializerFunction)NULL;
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// private classes
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class /* no WXDLLEXPORT */ wxConsoleApp : public wxApp
|
||||
// we need a dummy app object if the user doesn't want to create a real one
|
||||
class wxDummyConsoleApp : public wxApp
|
||||
{
|
||||
public:
|
||||
virtual int OnRun() { wxFAIL_MSG(wxT("unreachable")); return 0; }
|
||||
virtual int OnRun() { wxFAIL_MSG( _T("unreachable code") ); return 0; }
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
@@ -68,21 +60,6 @@ static size_t gs_nInitCount = 0;
|
||||
// implementation
|
||||
// ============================================================================
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// stubs for some GUI functions
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
void WXDLLEXPORT wxExit()
|
||||
{
|
||||
abort();
|
||||
}
|
||||
|
||||
// Yield to other apps/messages
|
||||
void WXDLLEXPORT wxWakeUpIdle()
|
||||
{
|
||||
// do nothing
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// wxBase-specific functions
|
||||
// ----------------------------------------------------------------------------
|
||||
@@ -103,7 +80,7 @@ bool WXDLLEXPORT wxInitialize()
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
wxTheApp = new wxConsoleApp;
|
||||
wxTheApp = new wxDummyConsoleApp;
|
||||
|
||||
if ( !wxTheApp )
|
||||
{
|
||||
|
Reference in New Issue
Block a user