X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/9a83f860948059b0273b5cc6d9e43fadad3ebfca..01495abf8755b0be46b4c65d6c7c48e9460f102b:/samples/widgets/filectrl.cpp diff --git a/samples/widgets/filectrl.cpp b/samples/widgets/filectrl.cpp index a27367db31..2c4f633259 100644 --- a/samples/widgets/filectrl.cpp +++ b/samples/widgets/filectrl.cpp @@ -6,7 +6,7 @@ // Created: 28 Jul 2007 // Id: $Id$ // Copyright: (c) 2007 Diaa M. Sami -// License: wxWindows license +// Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// // ============================================================================ @@ -130,6 +130,7 @@ BEGIN_EVENT_TABLE( FileCtrlWidgetsPage, WidgetsPage ) EVT_CHECKBOX( wxID_ANY, FileCtrlWidgetsPage::OnCheckBox ) EVT_RADIOBOX( wxID_ANY, FileCtrlWidgetsPage::OnRadioBox ) + EVT_FILECTRL_FILTERCHANGED( wxID_ANY, FileCtrlWidgetsPage::OnFileCtrl ) EVT_FILECTRL_FOLDERCHANGED( wxID_ANY, FileCtrlWidgetsPage::OnFileCtrl ) EVT_FILECTRL_SELECTIONCHANGED( wxID_ANY, FileCtrlWidgetsPage::OnFileCtrl ) EVT_FILECTRL_FILEACTIVATED( wxID_ANY, FileCtrlWidgetsPage::OnFileCtrl ) @@ -317,6 +318,11 @@ void FileCtrlWidgetsPage::OnFileCtrl( wxFileCtrlEvent& event ) { wxLogMessage("Selection changed event: %s", wxJoin(event.GetFiles(), ' ')); } + else if ( event.GetEventType() == wxEVT_FILECTRL_FILTERCHANGED ) + { + wxLogMessage("Filter changed event: filter %d selected", + event.GetFilterIndex() + 1); + } } #endif // wxUSE_FILECTRL