X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e5d05b907c823c87f7d4f92e535c15a7ee0124f2..b78df8565cd3ffe87a7ef376e1121f08d219ba2d:/src/osx/button_osx.cpp?ds=sidebyside diff --git a/src/osx/button_osx.cpp b/src/osx/button_osx.cpp index 12b630c412..52208f4ed2 100644 --- a/src/osx/button_osx.cpp +++ b/src/osx/button_osx.cpp @@ -34,6 +34,18 @@ bool wxButton::Create(wxWindow *parent, const wxValidator& validator, const wxString& name) { + // FIXME: this hack is needed because we're called from + // wxBitmapButton::Create() with this style and we currently use a + // different wxWidgetImpl method (CreateBitmapButton() rather than + // CreateButton()) for creating bitmap buttons, but we really ought + // to unify the creation of buttons of all kinds and then remove + // this check + if ( style & wxBU_NOTEXT ) + { + return wxControl::Create(parent, id, pos, size, style, + validator, name); + } + wxString label(lbl); if (label.empty() && wxIsStockID(id) && !(id == wxID_HELP)) label = wxGetStockLabel(id);