]> git.saurik.com Git - wxWidgets.git/commit
Simplify and correct MSW selection of background brush for children painting.
authorVadim Zeitlin <vadim@wxwidgets.org>
Fri, 21 May 2010 12:51:20 +0000 (12:51 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Fri, 21 May 2010 12:51:20 +0000 (12:51 +0000)
commitebfee17940b5123d0527b63bcf23e5f27002092e
tree6200f4e13cc167c2d7523c305955fe6bd6168175
parentd3eb13d2aa8b7f9e2da9921d4a64b9aa8488ff19
Simplify and correct MSW selection of background brush for children painting.

Check for the transparency of the window background in MSWGetBgBrush() itself
and let MSWGetBgBrushForChild() just return the brush to be used.

This required adding a MSW-specific hack to wxPanel to allow inheriting
background of wxNotebook by its children which is slightly ugly but is exactly
what we need to do in this case and makes the rest of the code much simpler.

Also add a possibility to set the background of the page containing the
control being tested to the widgets sample to test for background inheritance.
This shows problems with wxSlider and wxRadioBox backgrounds but they're not
new with this patch.

Closes #12057.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@64372 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
include/wx/generic/panelg.h
include/wx/msw/window.h
samples/widgets/widgets.cpp
src/generic/panelg.cpp
src/msw/control.cpp
src/msw/notebook.cpp
src/msw/statbox.cpp
src/msw/window.cpp