]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/combobox.cpp
Move wxGetOSFHandle to include/wx/msw/private.h since it needs HANDLE anyway
[wxWidgets.git] / src / gtk / combobox.cpp
index 6c40b2d84a7a2535f3ae8cc45a4f0f6e27c99bb3..3217adb8038d67b92f0f13f4000ea55202e3c773 100644 (file)
@@ -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,17 +264,17 @@ 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
 
     // This is required for tool bar support
-    wxSize setsize = GetSize();
-    gtk_widget_set_usize( m_widget, setsize.x, setsize.y );
+//    wxSize setsize = GetSize();
+//    gtk_widget_set_usize( m_widget, setsize.x, setsize.y );
 
     return true;
 }
@@ -644,16 +644,6 @@ void wxComboBox::SetSelection( int n )
     EnableEvents();
 }
 
-bool wxComboBox::SetStringSelection( const wxString &string )
-{
-    wxCHECK_MSG( m_widget != NULL, false, wxT("invalid combobox") );
-
-    int res = FindString( string );
-    if (res == -1) return false;
-    SetSelection( res );
-    return true;
-}
-
 wxString wxComboBox::GetValue() const
 {
     GtkEntry *entry = GTK_ENTRY( GTK_COMBO(m_widget)->entry );
@@ -879,9 +869,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 );
 }