fix for wxComboBox::GetSelection from inside event handler
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12496 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -520,7 +520,10 @@ bool wxComboListBox::SetSelection(const wxString& value)
|
|||||||
|
|
||||||
void wxComboListBox::OnSelect(wxCommandEvent& event)
|
void wxComboListBox::OnSelect(wxCommandEvent& event)
|
||||||
{
|
{
|
||||||
// first let the user code have the event
|
// first update the combo and close the listbox
|
||||||
|
m_combo->OnSelect(event.GetString());
|
||||||
|
|
||||||
|
// next let the user code have the event
|
||||||
|
|
||||||
// all fields are already filled by the listbox, just change the event
|
// all fields are already filled by the listbox, just change the event
|
||||||
// type and send it to the combo
|
// type and send it to the combo
|
||||||
@@ -529,9 +532,6 @@ void wxComboListBox::OnSelect(wxCommandEvent& event)
|
|||||||
event2.SetEventObject(m_combo);
|
event2.SetEventObject(m_combo);
|
||||||
event2.SetId(m_combo->GetId());
|
event2.SetId(m_combo->GetId());
|
||||||
m_combo->ProcessEvent(event2);
|
m_combo->ProcessEvent(event2);
|
||||||
|
|
||||||
// next update the combo and close the listbox
|
|
||||||
m_combo->OnSelect(event.GetString());
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void wxComboListBox::OnShow()
|
void wxComboListBox::OnShow()
|
||||||
|
Reference in New Issue
Block a user