Applied patch [ 588734 ] Makes ProcessIdle() virtual
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16341 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -255,6 +255,9 @@ wxMSW:
|
|||||||
- fixed a condition where a thread can hang during
|
- fixed a condition where a thread can hang during
|
||||||
message/event processing
|
message/event processing
|
||||||
- increased space between wxRadioBox label and first radio button
|
- increased space between wxRadioBox label and first radio button
|
||||||
|
- don't fail to register remaining window classes if one fails to register
|
||||||
|
- set window proc for non-control windows to avoid problems
|
||||||
|
with multiple wxWindows apps running simultaneously
|
||||||
|
|
||||||
wxGTK:
|
wxGTK:
|
||||||
|
|
||||||
|
@@ -11,8 +11,8 @@ returns a boolean value which indicates whether processing should continue (TRUE
|
|||||||
You call \helpref{wxApp::SetTopWindow}{wxappsettopwindow} to let wxWindows know
|
You call \helpref{wxApp::SetTopWindow}{wxappsettopwindow} to let wxWindows know
|
||||||
about the top window.
|
about the top window.
|
||||||
|
|
||||||
Note that the program's command line arguments, represented by {\it
|
Note that the program's command line arguments, represented by {\it argc}
|
||||||
argc} and {\it argv}, are available from within wxApp member functions.
|
and {\it argv}, are available from within wxApp member functions.
|
||||||
|
|
||||||
An application closes by destroying all windows. Because all frames must
|
An application closes by destroying all windows. Because all frames must
|
||||||
be destroyed for the application to exit, it is advisable to use parent
|
be destroyed for the application to exit, it is advisable to use parent
|
||||||
@@ -37,8 +37,9 @@ IMPLEMENT_APP(DerivedApp)
|
|||||||
|
|
||||||
bool DerivedApp::OnInit()
|
bool DerivedApp::OnInit()
|
||||||
{
|
{
|
||||||
wxFrame *the_frame = new wxFrame(NULL, argv[0]);
|
wxFrame *the_frame = new wxFrame(NULL, ID_MYFRAME, argv[0]);
|
||||||
...
|
...
|
||||||
|
the_frame->Show(TRUE);
|
||||||
SetTopWindow(the_frame);
|
SetTopWindow(the_frame);
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
@@ -151,6 +151,8 @@ public:
|
|||||||
// Override: rarely.
|
// Override: rarely.
|
||||||
virtual void OnFatalException() { }
|
virtual void OnFatalException() { }
|
||||||
|
|
||||||
|
virtual bool ProcessIdle() = 0;
|
||||||
|
|
||||||
// the worker functions - usually not used directly by the user code
|
// the worker functions - usually not used directly by the user code
|
||||||
// -----------------------------------------------------------------
|
// -----------------------------------------------------------------
|
||||||
|
|
||||||
|
@@ -47,6 +47,7 @@ public:
|
|||||||
virtual bool Pending();
|
virtual bool Pending();
|
||||||
virtual void Dispatch();
|
virtual void Dispatch();
|
||||||
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
||||||
|
virtual bool ProcessIdle();
|
||||||
|
|
||||||
// implementation only from now on
|
// implementation only from now on
|
||||||
void OnIdle( wxIdleEvent &event );
|
void OnIdle( wxIdleEvent &event );
|
||||||
@@ -57,7 +58,6 @@ public:
|
|||||||
static bool InitialzeVisual();
|
static bool InitialzeVisual();
|
||||||
static void CleanUp();
|
static void CleanUp();
|
||||||
|
|
||||||
bool ProcessIdle();
|
|
||||||
void DeletePendingObjects();
|
void DeletePendingObjects();
|
||||||
|
|
||||||
#ifdef __WXDEBUG__
|
#ifdef __WXDEBUG__
|
||||||
|
@@ -47,6 +47,7 @@ public:
|
|||||||
virtual bool Pending();
|
virtual bool Pending();
|
||||||
virtual void Dispatch();
|
virtual void Dispatch();
|
||||||
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
||||||
|
virtual bool ProcessIdle();
|
||||||
|
|
||||||
// implementation only from now on
|
// implementation only from now on
|
||||||
void OnIdle( wxIdleEvent &event );
|
void OnIdle( wxIdleEvent &event );
|
||||||
@@ -57,7 +58,6 @@ public:
|
|||||||
static bool InitialzeVisual();
|
static bool InitialzeVisual();
|
||||||
static void CleanUp();
|
static void CleanUp();
|
||||||
|
|
||||||
bool ProcessIdle();
|
|
||||||
void DeletePendingObjects();
|
void DeletePendingObjects();
|
||||||
|
|
||||||
#ifdef __WXDEBUG__
|
#ifdef __WXDEBUG__
|
||||||
|
@@ -53,6 +53,7 @@ class WXDLLEXPORT wxApp: public wxAppBase
|
|||||||
virtual bool Pending() ;
|
virtual bool Pending() ;
|
||||||
virtual void Dispatch() ;
|
virtual void Dispatch() ;
|
||||||
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
||||||
|
virtual bool ProcessIdle();
|
||||||
|
|
||||||
virtual void SetPrintMode(int mode) { m_printMode = mode; }
|
virtual void SetPrintMode(int mode) { m_printMode = mode; }
|
||||||
virtual int GetPrintMode() const { return m_printMode; }
|
virtual int GetPrintMode() const { return m_printMode; }
|
||||||
@@ -87,7 +88,6 @@ public:
|
|||||||
|
|
||||||
virtual bool OnInit();
|
virtual bool OnInit();
|
||||||
void DeletePendingObjects();
|
void DeletePendingObjects();
|
||||||
bool ProcessIdle();
|
|
||||||
bool IsExiting() { return !m_keepGoing ; }
|
bool IsExiting() { return !m_keepGoing ; }
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
@@ -47,6 +47,7 @@ public:
|
|||||||
virtual bool Initialized();
|
virtual bool Initialized();
|
||||||
virtual bool Pending();
|
virtual bool Pending();
|
||||||
virtual void Dispatch();
|
virtual void Dispatch();
|
||||||
|
virtual bool ProcessIdle();
|
||||||
|
|
||||||
// implementation only from now on
|
// implementation only from now on
|
||||||
void OnIdle(wxIdleEvent &event);
|
void OnIdle(wxIdleEvent &event);
|
||||||
@@ -56,7 +57,7 @@ public:
|
|||||||
static bool Initialize();
|
static bool Initialize();
|
||||||
static void CleanUp();
|
static void CleanUp();
|
||||||
|
|
||||||
bool ProcessIdle();
|
virtual bool ProcessIdle();
|
||||||
void DeletePendingObjects();
|
void DeletePendingObjects();
|
||||||
|
|
||||||
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
||||||
|
@@ -54,6 +54,7 @@ public:
|
|||||||
virtual bool Pending();
|
virtual bool Pending();
|
||||||
virtual void Dispatch();
|
virtual void Dispatch();
|
||||||
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
||||||
|
virtual bool ProcessIdle();
|
||||||
|
|
||||||
virtual bool OnInitGui();
|
virtual bool OnInitGui();
|
||||||
|
|
||||||
@@ -93,7 +94,6 @@ public:
|
|||||||
static void CleanUp();
|
static void CleanUp();
|
||||||
|
|
||||||
void DeletePendingObjects();
|
void DeletePendingObjects();
|
||||||
bool ProcessIdle();
|
|
||||||
|
|
||||||
// Motif-specific
|
// Motif-specific
|
||||||
WXAppContext GetAppContext() const { return m_appContext; }
|
WXAppContext GetAppContext() const { return m_appContext; }
|
||||||
|
@@ -42,6 +42,7 @@ public:
|
|||||||
virtual bool Pending();
|
virtual bool Pending();
|
||||||
virtual void Dispatch();
|
virtual void Dispatch();
|
||||||
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
||||||
|
virtual bool ProcessIdle();
|
||||||
|
|
||||||
virtual void SetPrintMode(int mode) { m_printMode = mode; }
|
virtual void SetPrintMode(int mode) { m_printMode = mode; }
|
||||||
virtual int GetPrintMode() const { return m_printMode; }
|
virtual int GetPrintMode() const { return m_printMode; }
|
||||||
@@ -97,7 +98,6 @@ public:
|
|||||||
// ---------------
|
// ---------------
|
||||||
|
|
||||||
void DeletePendingObjects();
|
void DeletePendingObjects();
|
||||||
bool ProcessIdle();
|
|
||||||
|
|
||||||
#if wxUSE_RICHEDIT
|
#if wxUSE_RICHEDIT
|
||||||
// initialize the richedit DLL of (at least) given version, return TRUE if
|
// initialize the richedit DLL of (at least) given version, return TRUE if
|
||||||
|
@@ -77,6 +77,7 @@ public:
|
|||||||
virtual bool Pending(void) ;
|
virtual bool Pending(void) ;
|
||||||
virtual void Dispatch(void);
|
virtual void Dispatch(void);
|
||||||
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
||||||
|
virtual bool ProcessIdle(void);
|
||||||
|
|
||||||
virtual void SetPrintMode(int mode) { m_nPrintMode = mode; }
|
virtual void SetPrintMode(int mode) { m_nPrintMode = mode; }
|
||||||
virtual int GetPrintMode(void) const { return m_nPrintMode; }
|
virtual int GetPrintMode(void) const { return m_nPrintMode; }
|
||||||
@@ -129,7 +130,6 @@ public:
|
|||||||
virtual bool DoMessage(void);
|
virtual bool DoMessage(void);
|
||||||
virtual bool ProcessMessage(WXMSG* pMsg);
|
virtual bool ProcessMessage(WXMSG* pMsg);
|
||||||
void DeletePendingObjects(void);
|
void DeletePendingObjects(void);
|
||||||
bool ProcessIdle(void);
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
int m_nCmdShow;
|
int m_nCmdShow;
|
||||||
|
@@ -55,6 +55,7 @@ public:
|
|||||||
virtual bool Pending();
|
virtual bool Pending();
|
||||||
virtual void Dispatch();
|
virtual void Dispatch();
|
||||||
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
virtual bool Yield(bool onlyIfNeeded = FALSE);
|
||||||
|
virtual bool ProcessIdle();
|
||||||
|
|
||||||
virtual bool OnInitGui();
|
virtual bool OnInitGui();
|
||||||
|
|
||||||
@@ -87,7 +88,6 @@ public:
|
|||||||
static void CleanUp();
|
static void CleanUp();
|
||||||
|
|
||||||
void DeletePendingObjects();
|
void DeletePendingObjects();
|
||||||
bool ProcessIdle();
|
|
||||||
|
|
||||||
WXWindow GetTopLevelWidget() const { return m_topLevelWidget; }
|
WXWindow GetTopLevelWidget() const { return m_topLevelWidget; }
|
||||||
WXColormap GetMainColormap(WXDisplay* display);
|
WXColormap GetMainColormap(WXDisplay* display);
|
||||||
|
Reference in New Issue
Block a user