made ProvideBackground() const
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@17329 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -83,7 +83,7 @@ public:
|
||||
|
||||
#ifdef __WXUNIVERSAL__
|
||||
virtual bool IsCanvasWindow() const { return TRUE; }
|
||||
virtual bool ProvidesBackground() { return TRUE; }
|
||||
virtual bool ProvidesBackground() const { return TRUE; }
|
||||
#endif
|
||||
|
||||
WX_DECLARE_CONTROL_CONTAINER();
|
||||
|
@@ -143,7 +143,7 @@ public:
|
||||
virtual int GetMinWidth() const;
|
||||
virtual int GetMinHeight() const;
|
||||
|
||||
virtual bool ProvidesBackground() { return TRUE; }
|
||||
virtual bool ProvidesBackground() const { return TRUE; }
|
||||
|
||||
protected:
|
||||
// handle titlebar button click event
|
||||
|
@@ -179,7 +179,7 @@ public:
|
||||
// to be used with function above: transparent windows get
|
||||
// their background from parents that return TRUE here,
|
||||
// so this is mostly for wxPanel, wxTopLevelWindow etc.
|
||||
virtual bool ProvidesBackground() { return FALSE; }
|
||||
virtual bool ProvidesBackground() const { return FALSE; }
|
||||
|
||||
// return TRUE if this control can be highlighted when the mouse is over
|
||||
// it (the theme decides itself whether it is really highlighted or not)
|
||||
|
@@ -274,7 +274,8 @@ bool wxWindow::DoDrawBackground(wxDC& dc)
|
||||
rect.width = size.x;
|
||||
rect.height = size.y;
|
||||
|
||||
if (HasTransparentBackground() && GetParent() && GetParent()->ProvidesBackground())
|
||||
wxWindow * const parent = GetParent();
|
||||
if ( HasTransparentBackground() && parent && parent->ProvidesBackground() )
|
||||
{
|
||||
wxASSERT( !IsTopLevel() );
|
||||
|
||||
@@ -294,7 +295,7 @@ bool wxWindow::DoDrawBackground(wxDC& dc)
|
||||
rect.y = pos.y;
|
||||
|
||||
// Let parent draw the background
|
||||
GetParent()->EraseBackground( dc, rect );
|
||||
parent->EraseBackground( dc, rect );
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -915,7 +916,7 @@ void wxWindow::ScrollWindow(int dx, int dy, const wxRect *rect)
|
||||
|
||||
wxWindowNative::ScrollWindow(dx, dy, rect);
|
||||
|
||||
#else
|
||||
#else // !wxX11
|
||||
|
||||
// before scrolling it, ensure that we don't have any unpainted areas
|
||||
Update();
|
||||
@@ -971,7 +972,7 @@ void wxWindow::ScrollWindow(int dx, int dy, const wxRect *rect)
|
||||
child->Move(child->GetPosition() + offset);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
#endif // wxX11/!wxX11
|
||||
}
|
||||
|
||||
wxRect wxWindow::ScrollNoRefresh(int dx, int dy, const wxRect *rectTotal)
|
||||
|
Reference in New Issue
Block a user