]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/listbox.cpp
check for error in GetSelection(long *, long *); clean up SetSelect(long, long)
[wxWidgets.git] / src / gtk1 / listbox.cpp
index d8810ddae08a9a1170624ff9a3d1f597483d0dd9..70203eb2db04f41625f84543cf32cb0c00fe3147 100644 (file)
@@ -194,7 +194,7 @@ gtk_listbox_button_release_callback( GtkWidget * WXUNUSED(widget),
         n = -1;
     }
 
-    event.m_commandInt = n;
+    event.SetInt(n);
 
     listbox->GetEventHandler()->ProcessEvent( event );
 
@@ -320,7 +320,7 @@ gtk_listbox_key_press_callback( GtkWidget *widget, GdkEventKey *gdk_event, wxLis
             {
                 n = -1;
             }
-            new_event.m_commandInt = n;
+            new_event.SetInt(n);
             listbox->GetEventHandler()->ProcessEvent( new_event );
         }
     }
@@ -393,7 +393,7 @@ static void gtk_listitem_select_cb( GtkWidget *widget,
         n = -1;
     }
 
-    event.m_commandInt = n;
+    event.SetInt(n);
 
 //    No longer required with new code in wxLB_SINGLE
 //    listbox->GetEventHandler()->AddPendingEvent( event );
@@ -649,11 +649,11 @@ void wxListBox::GtkAddItem( const wxString &item, int pos )
     else
         gtk_list_insert_items( GTK_LIST (m_list), gitem_list, pos );
 
-    gtk_signal_connect( GTK_OBJECT(list_item), "select",
+    gtk_signal_connect_after( GTK_OBJECT(list_item), "select",
       GTK_SIGNAL_FUNC(gtk_listitem_select_callback), (gpointer)this );
 
     if (HasFlag(wxLB_MULTIPLE) || HasFlag(wxLB_EXTENDED))
-        gtk_signal_connect( GTK_OBJECT(list_item), "deselect",
+        gtk_signal_connect_after( GTK_OBJECT(list_item), "deselect",
           GTK_SIGNAL_FUNC(gtk_listitem_deselect_callback), (gpointer)this );
 
     gtk_signal_connect( GTK_OBJECT(list_item),