@code
// Relays wxEVT_COMMAND_TEXT_UPDATED events of primary editor
// control to the OnEvent.
- propgrid->Connect(control->GetId(), wxEVT_COMMAND_TEXT_UPDATED,
- wxCommandEventHandler(wxPropertyGrid::OnCustomEditorEvent));
+ control->Connect(control->GetId(), wxEVT_COMMAND_TEXT_UPDATED,
+ wxCommandEventHandler(wxPropertyGrid::OnCustomEditorEvent),
+ NULL, propgrid);
@endcode
OnCustomEditorEvent will then forward events, first to
wxPGEditor::OnEvent() and then to wxPGProperty::OnEvent().
/** Handles events. Returns true if value in control was modified
(see wxPGProperty::OnEvent for more information).
+
+ @remarks wxPropertyGrid will automatically unfocus the editor when
+ wxEVT_COMMAND_TEXT_ENTER is received and when it results in
+ property value being modified. This happens regardless of
+ editor type (ie. behavior is same for any wxTextCtrl and
+ wxComboBox based editor).
*/
virtual bool OnEvent( wxPropertyGrid* propgrid, wxPGProperty* property,
wxWindow* wnd_primary, wxEvent& event ) const = 0;