misc fixes for (absense of) the borders
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14345 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -69,6 +69,10 @@ bool wxStaticLine::Create(wxWindow *parent,
|
|||||||
|
|
||||||
WXDWORD wxStaticLine::MSWGetStyle(long style, WXDWORD *exstyle) const
|
WXDWORD wxStaticLine::MSWGetStyle(long style, WXDWORD *exstyle) const
|
||||||
{
|
{
|
||||||
|
// we never have border
|
||||||
|
style &= ~wxBORDER_MASK;
|
||||||
|
style |= wxBORDER_NONE;
|
||||||
|
|
||||||
WXDWORD msStyle = wxControl::MSWGetStyle(style, exstyle);
|
WXDWORD msStyle = wxControl::MSWGetStyle(style, exstyle);
|
||||||
|
|
||||||
// add our default styles
|
// add our default styles
|
||||||
|
@@ -357,6 +357,12 @@ void wxTextCtrl::AdoptAttributesFromHWND()
|
|||||||
|
|
||||||
WXDWORD wxTextCtrl::MSWGetStyle(long style, WXDWORD *exstyle) const
|
WXDWORD wxTextCtrl::MSWGetStyle(long style, WXDWORD *exstyle) const
|
||||||
{
|
{
|
||||||
|
// default border for the text controls is the sunken one
|
||||||
|
if ( (style & wxBORDER_MASK) == wxBORDER_DEFAULT )
|
||||||
|
{
|
||||||
|
style |= wxBORDER_SUNKEN;
|
||||||
|
}
|
||||||
|
|
||||||
long msStyle = wxControl::MSWGetStyle(style, exstyle);
|
long msStyle = wxControl::MSWGetStyle(style, exstyle);
|
||||||
|
|
||||||
// default styles
|
// default styles
|
||||||
|
@@ -1084,7 +1084,8 @@ WXDWORD wxWindowMSW::MSWGetStyle(long flags, WXDWORD *exstyle) const
|
|||||||
if ( flags & wxCLIP_SIBLINGS )
|
if ( flags & wxCLIP_SIBLINGS )
|
||||||
style |= WS_CLIPSIBLINGS;
|
style |= WS_CLIPSIBLINGS;
|
||||||
|
|
||||||
if ( (flags & wxBORDER_MASK) != wxBORDER_NONE )
|
wxBorder border = (wxBorder)(flags & wxBORDER_MASK);
|
||||||
|
if ( border != wxBORDER_NONE && border != wxBORDER_DEFAULT )
|
||||||
style |= WS_BORDER;
|
style |= WS_BORDER;
|
||||||
|
|
||||||
// now deal with ext style if the caller wants it
|
// now deal with ext style if the caller wants it
|
||||||
@@ -1103,6 +1104,7 @@ WXDWORD wxWindowMSW::MSWGetStyle(long flags, WXDWORD *exstyle) const
|
|||||||
|
|
||||||
case wxBORDER_NONE:
|
case wxBORDER_NONE:
|
||||||
case wxBORDER_SIMPLE:
|
case wxBORDER_SIMPLE:
|
||||||
|
case wxBORDER_DEFAULT:
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case wxBORDER_STATIC:
|
case wxBORDER_STATIC:
|
||||||
@@ -1113,7 +1115,6 @@ WXDWORD wxWindowMSW::MSWGetStyle(long flags, WXDWORD *exstyle) const
|
|||||||
*exstyle |= WS_EX_WINDOWEDGE;
|
*exstyle |= WS_EX_WINDOWEDGE;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case wxBORDER_DEFAULT:
|
|
||||||
case wxBORDER_SUNKEN:
|
case wxBORDER_SUNKEN:
|
||||||
*exstyle |= WS_EX_CLIENTEDGE;
|
*exstyle |= WS_EX_CLIENTEDGE;
|
||||||
break;
|
break;
|
||||||
|
Reference in New Issue
Block a user