fixed repainting of windows without the wxFULL_REPAINT_ON_RESIZE style under wxMSW/Univ
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42518 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -124,20 +124,27 @@ bool wxWindow::Create(wxWindow *parent,
|
|||||||
{
|
{
|
||||||
long actualStyle = style;
|
long actualStyle = style;
|
||||||
|
|
||||||
// FIXME: may need this on other platforms
|
|
||||||
#ifdef __WXMSW__
|
|
||||||
actualStyle &= ~wxVSCROLL;
|
|
||||||
actualStyle &= ~wxHSCROLL;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
// we add wxCLIP_CHILDREN to get the same ("natural") behaviour under MSW
|
// we add wxCLIP_CHILDREN to get the same ("natural") behaviour under MSW
|
||||||
// as under the other platforms
|
// as under the other platforms
|
||||||
if ( !wxWindowNative::Create(parent, id, pos, size,
|
actualStyle |= wxCLIP_CHILDREN;
|
||||||
actualStyle | wxCLIP_CHILDREN,
|
|
||||||
name) )
|
#ifdef __WXMSW__
|
||||||
{
|
// FIXME: may need this on other platforms
|
||||||
|
actualStyle &= ~wxVSCROLL;
|
||||||
|
actualStyle &= ~wxHSCROLL;
|
||||||
|
|
||||||
|
// without this, borders (non-client areas in general) are not repainted
|
||||||
|
// correctly when resizing; apparently, native NC areas are fully repainted
|
||||||
|
// even without this style by MSW, but wxUniv implements client area
|
||||||
|
// itself, so it doesn't work correctly for us
|
||||||
|
//
|
||||||
|
// FIXME: this is very expensive, we need to fix the (commented-out) code
|
||||||
|
// in OnSize() instead
|
||||||
|
actualStyle |= wxFULL_REPAINT_ON_RESIZE;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if ( !wxWindowNative::Create(parent, id, pos, size, actualStyle, name) )
|
||||||
return false;
|
return false;
|
||||||
}
|
|
||||||
|
|
||||||
// Set full style again, including those we didn't want present
|
// Set full style again, including those we didn't want present
|
||||||
// when calling the base window Create().
|
// when calling the base window Create().
|
||||||
|
Reference in New Issue
Block a user