Cut down on unnecessary update events

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@51784 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart 2008-02-14 11:08:49 +00:00
parent 3570a1c6e5
commit df707c27b3
6 changed files with 6 additions and 6 deletions

View File

@ -2665,7 +2665,7 @@ void wxWindowGTK::OnInternalIdle()
}
}
if (wxUpdateUIEvent::CanUpdate(this) && IsShown())
if (wxUpdateUIEvent::CanUpdate(this) && IsShownOnScreen())
UpdateWindowUI(wxUPDATE_UI_FROMIDLE);
}

View File

@ -2968,7 +2968,7 @@ void wxWindowGTK::OnInternalIdle()
}
}
if (wxUpdateUIEvent::CanUpdate(this) && IsShown())
if (wxUpdateUIEvent::CanUpdate(this) && IsShownOnScreen())
UpdateWindowUI(wxUPDATE_UI_FROMIDLE);
}

View File

@ -2502,7 +2502,7 @@ void wxWindowMac::OnInternalIdle()
{
// This calls the UI-update mechanism (querying windows for
// menu/toolbar/control state information)
if (wxUpdateUIEvent::CanUpdate(this) && IsShown())
if (wxUpdateUIEvent::CanUpdate(this) && IsShownOnScreen())
UpdateWindowUI(wxUPDATE_UI_FROMIDLE);
}

View File

@ -1657,7 +1657,7 @@ void wxWindow::OnInternalIdle()
{
// This calls the UI-update mechanism (querying windows for
// menu/toolbar/control state information)
if (wxUpdateUIEvent::CanUpdate(this) && IsShown())
if (wxUpdateUIEvent::CanUpdate(this) && IsShownOnScreen())
UpdateWindowUI(wxUPDATE_UI_FROMIDLE);
}

View File

@ -1570,7 +1570,7 @@ void wxWindowMSW::OnInternalIdle()
}
#endif // !HAVE_TRACKMOUSEEVENT
if (wxUpdateUIEvent::CanUpdate(this) && IsShown())
if (wxUpdateUIEvent::CanUpdate(this) && IsShownOnScreen())
UpdateWindowUI(wxUPDATE_UI_FROMIDLE);
}

View File

@ -1317,7 +1317,7 @@ void wxWindowX11::OnInternalIdle()
// This calls the UI-update mechanism (querying windows for
// menu/toolbar/control state information)
if (wxUpdateUIEvent::CanUpdate((wxWindow*) this) && IsShown())
if (wxUpdateUIEvent::CanUpdate((wxWindow*) this) && IsShownOnScreen())
UpdateWindowUI(wxUPDATE_UI_FROMIDLE);
// Set the input focus if couldn't do it before