X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/899544330f37440c140b72a014c518a911b5b7a4..65d30b79509577b6f0cb93bae48f3915e368f57d:/src/gtk1/checkbox.cpp diff --git a/src/gtk1/checkbox.cpp b/src/gtk1/checkbox.cpp index c61796d946..c895b7c82c 100644 --- a/src/gtk1/checkbox.cpp +++ b/src/gtk1/checkbox.cpp @@ -50,7 +50,7 @@ static void gtk_checkbox_toggled_callback(GtkWidget *WXUNUSED(widget), wxCommandEvent event(wxEVT_COMMAND_CHECKBOX_CLICKED, cb->GetId()); event.SetInt(cb->GetValue()); event.SetEventObject(cb); - cb->GetEventHandler()->ProcessEvent(event); + cb->HandleWindowEvent(event); } } @@ -77,6 +77,7 @@ bool wxCheckBox::Create(wxWindow *parent, m_acceptsFocus = true; m_blockEvent = false; + WXValidateStyle(&style); if (!PreCreation( parent, pos, size ) || !CreateBase( parent, id, pos, size, style, validator, name )) { @@ -84,11 +85,6 @@ bool wxCheckBox::Create(wxWindow *parent, return false; } - wxASSERT_MSG( (style & wxCHK_ALLOW_3RD_STATE_FOR_USER) == 0 || - (style & wxCHK_3STATE) != 0, - wxT("Using wxCHK_ALLOW_3RD_STATE_FOR_USER") - wxT(" style flag for a 2-state checkbox is useless") ); - if ( style & wxALIGN_RIGHT ) { // VZ: as I don't know a way to create a right aligned checkbox with