m_oldSize.x = -1;
m_oldSize.y = -1;
+
+ m_hasDialogBackground = FALSE;
}
bool wxWindow::Create(wxWindow *parent,
// if we should always have the scrollbar, do show it
if ( GetWindowStyle() & wxALWAYS_SHOW_SB )
{
+#if wxUSE_TWO_WINDOWS
+ SetInsertIntoMain( TRUE );
+#endif
m_scrollbarVert = new wxScrollBar(this, -1,
wxDefaultPosition, wxDefaultSize,
wxSB_VERTICAL);
+#if wxUSE_TWO_WINDOWS
+ SetInsertIntoMain( FALSE );
+#endif
// and position it
PositionScrollbars();
bool wxWindow::DoDrawBackground(wxDC& dc)
{
- // FIXME: leaving this code in leads to partial bg redraws sometimes under
- // MSW
+ // FIXME: Leaving this code in leads to partial bg redraws
+ // sometimes under MSW.
+ // The same happens under X11 because it has a clear
+ // region and an update region and these are sometimes
+ // different. RR.
wxRect rect;
-#ifndef __WXMSW__
+// #ifndef __WXMSW__
+#if 0
rect = GetUpdateRegion().GetBox();
if ( !rect.width && !rect.height )
#endif
PositionScrollbars();
}
-#ifndef __WXMSW__
+#if 0 // ndef __WXMSW__
// Refresh the area (strip) previously occupied by the border
if (HasFlag( wxNO_FULL_REPAINT_ON_RESIZE ) && IsShown())
{
wxPoint pt = wxWindowBase::GetClientAreaOrigin();
+#if wxUSE_TWO_WINDOWS
+#else
if ( m_renderer )
pt += m_renderer->GetBorderDimensions(GetBorder()).GetPosition();
+#endif
return pt;
}
if ( !scrollbar )
{
// create it
+#if wxUSE_TWO_WINDOWS
+ SetInsertIntoMain( TRUE );
+#endif
scrollbar = new wxScrollBar(this, -1,
wxDefaultPosition, wxDefaultSize,
orient & wxVERTICAL ? wxSB_VERTICAL
: wxSB_HORIZONTAL);
+#if wxUSE_TWO_WINDOWS
+ SetInsertIntoMain( FALSE );
+#endif
if ( orient & wxVERTICAL )
m_scrollbarVert = scrollbar;
else
// give the window a chance to relayout
if ( hasClientSizeChanged )
{
+#if wxUSE_TWO_WINDOWS
+ wxWindowNative::SetSize( GetSize() );
+#else
wxSizeEvent event(GetSize());
(void)GetEventHandler()->ProcessEvent(event);
+#endif
}
}