height = 0;
// if our parent had prepared a defer window handle for us, use it
- wxWindowMSW *parent =
-#ifdef __WXUNIVERSAL__
- wxDynamicCast(m_parent, wxWindowMSW)
-#else
- m_parent
-#endif
- ;
+ wxWindowMSW *parent = GetParent();
HDWP hdwp = parent ? (HDWP)parent->m_hDWP : NULL;
if ( hdwp )
{
{
wxLogLastError(_T("EndDeferWindowPos"));
}
-
- m_hDWP = NULL;
}
break;
#endif // __SMARTPHONE__
{
if ( m_hasBgCol )
{
+ // our background colour applies to:
+ // 1. this window itself, always
+ // 2. all children unless the colour is "not inheritable"
+ // 3. immediate transparent children which should show the same
+ // background as we do, but not for transparent grandchildren
+ // which use the background of their immediate parent instead
if ( m_inheritBgCol ||
child == this ||
- child->HasTransparentBackground() )
+ (child->HasTransparentBackground() &&
+ child->GetParent() == this) )
{
return GetBackgroundColour();
}