compilation fixes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@22488 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -68,13 +68,13 @@ public:
|
|||||||
|
|
||||||
// we need a special kind of auto pointer to wxApp which not only deletes the
|
// we need a special kind of auto pointer to wxApp which not only deletes the
|
||||||
// pointer it holds in its dtor but also resets the global application pointer
|
// pointer it holds in its dtor but also resets the global application pointer
|
||||||
wxDECLARE_SCOPED_PTR(wxApp, wxAppPtrBase);
|
wxDECLARE_SCOPED_PTR(wxAppConsole, wxAppPtrBase);
|
||||||
wxDEFINE_SCOPED_PTR(wxApp, wxAppPtrBase);
|
wxDEFINE_SCOPED_PTR(wxAppConsole, wxAppPtrBase);
|
||||||
|
|
||||||
class wxAppPtr : public wxAppPtrBase
|
class wxAppPtr : public wxAppPtrBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxAppPtr(wxApp *ptr = NULL) : wxAppPtrBase(ptr) { }
|
wxEXPLICIT wxAppPtr(wxAppConsole *ptr = NULL) : wxAppPtrBase(ptr) { }
|
||||||
~wxAppPtr()
|
~wxAppPtr()
|
||||||
{
|
{
|
||||||
if ( get() )
|
if ( get() )
|
||||||
@@ -85,7 +85,7 @@ public:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Set(wxApp *ptr)
|
void Set(wxAppConsole *ptr)
|
||||||
{
|
{
|
||||||
reset(ptr);
|
reset(ptr);
|
||||||
|
|
||||||
@@ -100,13 +100,13 @@ public:
|
|||||||
class wxCallAppCleanup
|
class wxCallAppCleanup
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxCallAppCleanup(wxApp *app) : m_app(app) { }
|
wxCallAppCleanup(wxAppConsole *app) : m_app(app) { }
|
||||||
~wxCallAppCleanup() { if ( m_app ) m_app->CleanUp(); }
|
~wxCallAppCleanup() { if ( m_app ) m_app->CleanUp(); }
|
||||||
|
|
||||||
void Dismiss() { m_app = NULL; }
|
void Dismiss() { m_app = NULL; }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
wxApp *m_app;
|
wxAppConsole *m_app;
|
||||||
};
|
};
|
||||||
|
|
||||||
// another tiny class which simply exists to ensure that wxEntryCleanup is
|
// another tiny class which simply exists to ensure that wxEntryCleanup is
|
||||||
|
Reference in New Issue
Block a user