Correct check for animating non-visible windows added in r75130.

Check whether the parent is not shown instead of checking the window itself
because the window is never shown when we're in process of showing it. We need
to avoid animations in the case when it still won't be shown even after
showing it, and this is achieved by checking its parent visibility.

Closes #15643.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_3_0_BRANCH@75131 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2013-11-05 17:00:56 +00:00
parent b6d00b3b15
commit 462d81dda4

View File

@@ -675,7 +675,8 @@ wxWindowMSW::MSWShowWithEffect(bool show,
unsigned timeout)
{
#if wxUSE_DYNLIB_CLASS
if ( effect == wxSHOW_EFFECT_NONE || !IsShownOnScreen() )
if ( effect == wxSHOW_EFFECT_NONE ||
(GetParent() && !GetParent()->IsShownOnScreen()) )
return Show(show);
if ( !wxWindowBase::Show(show) )