create BS_GROUPBOX transparent
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@30653 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
e1d6e01c88
commit
65546961ea
@ -38,6 +38,8 @@
|
|||||||
#include "wx/log.h"
|
#include "wx/log.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include "wx/notebook.h"
|
||||||
|
|
||||||
#include "wx/msw/private.h"
|
#include "wx/msw/private.h"
|
||||||
|
|
||||||
#if wxUSE_TOOLTIPS
|
#if wxUSE_TOOLTIPS
|
||||||
@ -276,7 +278,7 @@ bool wxRadioBox::Create(wxWindow *parent,
|
|||||||
|
|
||||||
// create the static box
|
// create the static box
|
||||||
if ( !MSWCreateControl(wxT("BUTTON"), BS_GROUPBOX | WS_GROUP,
|
if ( !MSWCreateControl(wxT("BUTTON"), BS_GROUPBOX | WS_GROUP,
|
||||||
pos, size, title, 0) )
|
pos, size, title, WS_EX_TRANSPARENT) )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
// and now create the buttons
|
// and now create the buttons
|
||||||
@ -831,11 +833,23 @@ bool wxRadioBox::SetFont(const wxFont& font)
|
|||||||
|
|
||||||
WXLRESULT wxRadioBox::MSWWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam)
|
WXLRESULT wxRadioBox::MSWWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam)
|
||||||
{
|
{
|
||||||
|
#if RADIOBTN_PARENT_IS_RADIOBOX
|
||||||
switch ( nMsg )
|
switch ( nMsg )
|
||||||
{
|
{
|
||||||
|
// handle this message to set correct colours for our buttons here
|
||||||
case WM_CTLCOLORSTATIC:
|
case WM_CTLCOLORSTATIC:
|
||||||
return (WXLRESULT)GetStockObject(WHITE_BRUSH);
|
{
|
||||||
|
WXHDC hdc;
|
||||||
|
WXHWND hwnd;
|
||||||
|
UnpackCtlColor(wParam, lParam, &hdc, &hwnd);
|
||||||
|
|
||||||
|
WXHBRUSH hbr = MSWControlColor((WXHDC)hdc);
|
||||||
|
if ( hbr )
|
||||||
|
return (WXLRESULT)hbr;
|
||||||
|
//else: fall through to default window proc
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
#endif // RADIOBTN_PARENT_IS_RADIOBOX
|
||||||
|
|
||||||
return wxControl::MSWWindowProc(nMsg, wParam, lParam);
|
return wxControl::MSWWindowProc(nMsg, wParam, lParam);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user