]> git.saurik.com Git - wxWidgets.git/blobdiff - src/osx/listbox_osx.cpp
fix wxGTK1 compilation after wxTextEntry DoGetValue() change
[wxWidgets.git] / src / osx / listbox_osx.cpp
index e138470caee91944ed8a8da4bc066ee755c9e393..3b74cc851e2a05ddfcd64275d7d11763e6c86803 100644 (file)
@@ -370,4 +370,23 @@ void wxListBox::SetString(unsigned int n, const wxString& s)
     GetListPeer()->UpdateLine(n);
 }
 
     GetListPeer()->UpdateLine(n);
 }
 
+//
+// common event handling
+//
+
+void wxListBox::HandleLineEvent( unsigned int n, bool doubleClick )
+{
+    wxCommandEvent event( doubleClick ? wxEVT_COMMAND_LISTBOX_DOUBLECLICKED : 
+        wxEVT_COMMAND_LISTBOX_SELECTED, GetId() );
+    event.SetEventObject( this );
+    if ( HasClientObjectData() )
+        event.SetClientObject( GetClientObject(n) );
+    else if ( HasClientUntypedData() )
+        event.SetClientData( GetClientData(n) );
+    event.SetString( GetString(n) );
+    event.SetInt( n );
+    event.SetExtraLong( 1 );
+    HandleWindowEvent(event);
+}
+
 #endif // wxUSE_LISTBOX
 #endif // wxUSE_LISTBOX