X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/7728856b75c201016a30145673bc8a85be96fdfe..4f8ffae1099d921986411f59bdbd62b764b0491f:/include/wx/mac/app.h diff --git a/include/wx/mac/app.h b/include/wx/mac/app.h index 23b4cb0a60..0b32e7983b 100644 --- a/include/wx/mac/app.h +++ b/include/wx/mac/app.h @@ -12,7 +12,7 @@ #ifndef _WX_APP_H_ #define _WX_APP_H_ -#if defined(__GNUG__) && !defined(__APPLE__) +#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) #pragma interface "app.h" #endif @@ -52,8 +52,11 @@ class WXDLLEXPORT wxApp: public wxAppBase virtual bool Initialized(); virtual bool Pending() ; virtual void Dispatch() ; + + virtual void Exit(); + virtual bool Yield(bool onlyIfNeeded = FALSE); - virtual bool ProcessIdle(); + virtual void WakeUpIdle(); virtual void SetPrintMode(int mode) { m_printMode = mode; } virtual int GetPrintMode() const { return m_printMode; } @@ -67,14 +70,6 @@ class WXDLLEXPORT wxApp: public wxAppBase void OnEndSession(wxCloseEvent& event); void OnQueryEndSession(wxCloseEvent& event); - // Send idle event to all top-level windows. - // Returns TRUE if more idle time is requested. - bool SendIdleEvents(); - - // Send idle event to window and all subwindows - // Returns TRUE if more idle time is requested. - bool SendIdleEvents(wxWindowMac* win); - // Windows only, but for compatibility... inline void SetAuto3D(bool flag) { m_auto3D = flag; } inline bool GetAuto3D() const { return m_auto3D; } @@ -87,14 +82,16 @@ protected: public: // Implementation - static bool Initialize(); - static void CleanUp(); + virtual bool Initialize(int& argc, wxChar **argv); + virtual void CleanUp(); - void DeletePendingObjects(); bool IsExiting() { return !m_keepGoing ; } #if TARGET_CARBON + // the installed application event handler WXEVENTHANDLERREF MacGetEventHandler() { return m_macEventHandler ; } WXEVENTHANDLERREF MacGetCurrentEventHandlerCallRef() { return m_macCurrentEventHandlerCallRef ; } + void MacSetCurrentEvent( WXEVENTREF event , WXEVENTHANDLERCALLREF handler ) + { m_macCurrentEvent = event ; m_macCurrentEventHandlerCallRef = handler ; } #endif public: @@ -111,8 +108,8 @@ private: // mac specifics #if TARGET_CARBON - WXEVENTHANDLERREF m_macEventHandler ; - WXEVENTHANDLERCALLREF m_macCurrentEventHandlerCallRef ; + WXEVENTHANDLERREF m_macEventHandler ; + WXEVENTHANDLERCALLREF m_macCurrentEventHandlerCallRef ; #endif WXEVENTREF m_macCurrentEvent ;