void OnToggleSearchMenu(wxCommandEvent&);
void OnSearch(wxCommandEvent& event);
+ void OnSearchCancel(wxCommandEvent& event);
wxMenu* CreateTestMenu();
EVT_CHECKBOX(ID_MENU_CB, SearchCtrlWidgetsPage::OnToggleSearchMenu)
EVT_SEARCHCTRL_SEARCH_BTN(wxID_ANY, SearchCtrlWidgetsPage::OnSearch)
+ EVT_SEARCHCTRL_CANCEL_BTN(wxID_ANY, SearchCtrlWidgetsPage::OnSearchCancel)
END_EVENT_TABLE()
// ============================================================================
wxLogMessage("Search button: search for \"%s\".", event.GetString());
}
+void SearchCtrlWidgetsPage::OnSearchCancel(wxCommandEvent& event)
+{
+ wxLogMessage("Cancel button pressed.");
+
+ event.Skip();
+}
+
#endif // wxUSE_SEARCHCTRL