X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/b3260bce473ab247edd8ca1d3aee4eb648b4b97e..31c8af3abb1150658652f506e76af7fa1bb86898:/src/os2/button.cpp diff --git a/src/os2/button.cpp b/src/os2/button.cpp index 19977b783a..133a6f6cd5 100644 --- a/src/os2/button.cpp +++ b/src/os2/button.cpp @@ -318,7 +318,28 @@ void wxButton::MakeOwnerDrawn() lStyle |= BS_USERBUTTON; ::WinSetWindowULong(GetHwnd(), QWL_STYLE, lStyle); } -} // end of wxCButton::MakeOwnerDrawn +} // end of wxButton::MakeOwnerDrawn + +WXDWORD wxButton::OS2GetStyle( + long lStyle +, WXDWORD* pdwExstyle +) const +{ + // + // Buttons never have an external border, they draw their own one + // + WXDWORD dwStyle = wxControl::OS2GetStyle( (lStyle & ~wxBORDER_MASK) | wxBORDER_NONE + ,pdwExstyle + ); + + // + // We must use WS_CLIPSIBLINGS with the buttons or they would draw over + // each other in any resizeable dialog which has more than one button in + // the bottom + // + dwStyle |= WS_CLIPSIBLINGS; + return dwStyle; +} // end of wxButton::OS2GetStyle MRESULT wxButton::WindowProc( WXUINT uMsg @@ -362,5 +383,5 @@ MRESULT wxButton::WindowProc( ,wParam ,lParam )); -} // end of wxW indowProc +} // end of wxWindowProc