_conncect_after() should be used for controls emitting
command events so as to not confuse GTK+ if the user intercepts them too early. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@31764 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -122,7 +122,7 @@ gtk_combo_select_child_callback( GtkList *WXUNUSED(list), GtkWidget *WXUNUSED(wi
|
||||
gtk_signal_disconnect_by_func( GTK_OBJECT(GTK_COMBO(combo->GetHandle())->entry),
|
||||
GTK_SIGNAL_FUNC(gtk_text_changed_callback), (gpointer)combo );
|
||||
combo->SetValue( combo->GetStringSelection() );
|
||||
gtk_signal_connect( GTK_OBJECT(GTK_COMBO(combo->GetHandle())->entry), "changed",
|
||||
gtk_signal_connect_after( GTK_OBJECT(GTK_COMBO(combo->GetHandle())->entry), "changed",
|
||||
GTK_SIGNAL_FUNC(gtk_text_changed_callback), (gpointer)combo );
|
||||
|
||||
// throw a SELECTED event only if the combobox popup is hidden
|
||||
@@ -264,10 +264,10 @@ bool wxComboBox::Create( wxWindow *parent, wxWindowID id, const wxString& value,
|
||||
gtk_signal_connect( GTK_OBJECT(GTK_COMBO(combo)->popwin), "show",
|
||||
GTK_SIGNAL_FUNC(gtk_popup_show_callback), (gpointer)this );
|
||||
|
||||
gtk_signal_connect( GTK_OBJECT(combo->entry), "changed",
|
||||
gtk_signal_connect_after( GTK_OBJECT(combo->entry), "changed",
|
||||
GTK_SIGNAL_FUNC(gtk_text_changed_callback), (gpointer)this );
|
||||
|
||||
gtk_signal_connect( GTK_OBJECT(combo->list), "select-child",
|
||||
gtk_signal_connect_after( GTK_OBJECT(combo->list), "select-child",
|
||||
GTK_SIGNAL_FUNC(gtk_combo_select_child_callback), (gpointer)this );
|
||||
|
||||
SetBestSize(size); // need this too because this is a wxControlWithItems
|
||||
@@ -879,9 +879,9 @@ void wxComboBox::DisableEvents()
|
||||
|
||||
void wxComboBox::EnableEvents()
|
||||
{
|
||||
gtk_signal_connect( GTK_OBJECT(GTK_COMBO(m_widget)->list), "select-child",
|
||||
gtk_signal_connect_after( GTK_OBJECT(GTK_COMBO(m_widget)->list), "select-child",
|
||||
GTK_SIGNAL_FUNC(gtk_combo_select_child_callback), (gpointer)this );
|
||||
gtk_signal_connect( GTK_OBJECT(GTK_COMBO(m_widget)->entry), "changed",
|
||||
gtk_signal_connect_after( GTK_OBJECT(GTK_COMBO(m_widget)->entry), "changed",
|
||||
GTK_SIGNAL_FUNC(gtk_text_changed_callback), (gpointer)this );
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user