X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ee74faf934cedf222f52d7a785225ff45121472d..546bfbea8180aeee5a16f4abb34e721445277305:/src/msw/window.cpp diff --git a/src/msw/window.cpp b/src/msw/window.cpp index 3f8bd5c12b..4ee8e7b1f3 100644 --- a/src/msw/window.cpp +++ b/src/msw/window.cpp @@ -1084,7 +1084,8 @@ WXDWORD wxWindowMSW::MSWGetStyle(long flags, WXDWORD *exstyle) const if ( flags & wxCLIP_SIBLINGS ) 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; // 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_SIMPLE: + case wxBORDER_DEFAULT: break; case wxBORDER_STATIC: @@ -1113,7 +1115,6 @@ WXDWORD wxWindowMSW::MSWGetStyle(long flags, WXDWORD *exstyle) const *exstyle |= WS_EX_WINDOWEDGE; break; - case wxBORDER_DEFAULT: case wxBORDER_SUNKEN: *exstyle |= WS_EX_CLIENTEDGE; break; @@ -1644,15 +1645,6 @@ void wxWindowMSW::DoSetClientSize(int width, int height) break; } - if ( i == 3 ) - { - // how did it happen? maybe OnSize() handler does something really - // strange in this class? - wxFAIL_MSG( _T("logic error in DoSetClientSize") ); - - break; - } - int widthClient = width, heightClient = height; @@ -5157,6 +5149,7 @@ wxPoint wxGetMousePosition() { POINT pt; GetCursorPos( & pt ); + return wxPoint(pt.x, pt.y); }