X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/fb39c7ecd74988b49b2356e154ef68ecaa320a8b..48c12cb1290224f44161d9af774170d5f0fae440:/src/msw/button.cpp diff --git a/src/msw/button.cpp b/src/msw/button.cpp index 9a8122e079..f9a84f98d2 100644 --- a/src/msw/button.cpp +++ b/src/msw/button.cpp @@ -97,6 +97,17 @@ bool wxButton::Create(wxWindow *parent, SetSize(pos.x, pos.y, size.x, size.y); + // bad hack added by Robert to make buttons at least + // 80 pixels wide. There are probably better ways... + // TODO. FIXME. + wxSize nsize( GetSize() ); + if ((nsize.x < 80) || (nsize.y < 23)) + { + if ((size.x == -1) && (nsize.x < 80)) nsize.x = 80; + if ((size.y == -1) && (nsize.y < 23)) nsize.y = 23; + SetSize( nsize ); + } + return TRUE; }