made wxIsInsideYield global -- will be fixed when we have some better way to test if we're inside wxYield() from wxApp
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15526 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -87,12 +87,14 @@ void wxExit()
|
|||||||
// wxYield
|
// wxYield
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
|
||||||
|
// not static because used by textctrl.cpp
|
||||||
|
//
|
||||||
|
// MT-FIXME
|
||||||
|
bool wxIsInsideYield = FALSE;
|
||||||
|
|
||||||
bool wxApp::Yield(bool onlyIfNeeded)
|
bool wxApp::Yield(bool onlyIfNeeded)
|
||||||
{
|
{
|
||||||
// MT-FIXME
|
if ( wxIsInsideYield )
|
||||||
static bool s_inYield = FALSE;
|
|
||||||
|
|
||||||
if ( s_inYield )
|
|
||||||
{
|
{
|
||||||
if ( !onlyIfNeeded )
|
if ( !onlyIfNeeded )
|
||||||
{
|
{
|
||||||
@@ -110,7 +112,7 @@ bool wxApp::Yield(bool onlyIfNeeded)
|
|||||||
}
|
}
|
||||||
#endif // wxUSE_THREADS
|
#endif // wxUSE_THREADS
|
||||||
|
|
||||||
s_inYield = TRUE;
|
wxIsInsideYield = TRUE;
|
||||||
|
|
||||||
if (!g_isIdle)
|
if (!g_isIdle)
|
||||||
{
|
{
|
||||||
@@ -139,7 +141,7 @@ bool wxApp::Yield(bool onlyIfNeeded)
|
|||||||
// let the logs be flashed again
|
// let the logs be flashed again
|
||||||
wxLog::Resume();
|
wxLog::Resume();
|
||||||
|
|
||||||
s_inYield = FALSE;
|
wxIsInsideYield = FALSE;
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
@@ -87,12 +87,14 @@ void wxExit()
|
|||||||
// wxYield
|
// wxYield
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
|
|
||||||
|
// not static because used by textctrl.cpp
|
||||||
|
//
|
||||||
|
// MT-FIXME
|
||||||
|
bool wxIsInsideYield = FALSE;
|
||||||
|
|
||||||
bool wxApp::Yield(bool onlyIfNeeded)
|
bool wxApp::Yield(bool onlyIfNeeded)
|
||||||
{
|
{
|
||||||
// MT-FIXME
|
if ( wxIsInsideYield )
|
||||||
static bool s_inYield = FALSE;
|
|
||||||
|
|
||||||
if ( s_inYield )
|
|
||||||
{
|
{
|
||||||
if ( !onlyIfNeeded )
|
if ( !onlyIfNeeded )
|
||||||
{
|
{
|
||||||
@@ -110,7 +112,7 @@ bool wxApp::Yield(bool onlyIfNeeded)
|
|||||||
}
|
}
|
||||||
#endif // wxUSE_THREADS
|
#endif // wxUSE_THREADS
|
||||||
|
|
||||||
s_inYield = TRUE;
|
wxIsInsideYield = TRUE;
|
||||||
|
|
||||||
if (!g_isIdle)
|
if (!g_isIdle)
|
||||||
{
|
{
|
||||||
@@ -139,7 +141,7 @@ bool wxApp::Yield(bool onlyIfNeeded)
|
|||||||
// let the logs be flashed again
|
// let the logs be flashed again
|
||||||
wxLog::Resume();
|
wxLog::Resume();
|
||||||
|
|
||||||
s_inYield = FALSE;
|
wxIsInsideYield = FALSE;
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user