Skip to content

Commit

Permalink
Fix enter event for search panel not working
Browse files Browse the repository at this point in the history
  • Loading branch information
Blake-Madden committed Aug 25, 2023
1 parent 9f6649f commit febbefc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ui/controls/searchpanel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ SearchPanel::SearchPanel(wxWindow *parent, wxWindowID id) :
wxBoxSizer* mainSizer = new wxBoxSizer(wxHORIZONTAL);

m_search = new wxSearchCtrl(this, ControlIDs::ID_SEARCH_TEXT_ENTRY, wxString{},
wxDefaultPosition, FromDIP(wxSize(200, -1)), wxTE_PROCESS_ENTER);
wxDefaultPosition, FromDIP(wxSize(200, -1)), 0);
mainSizer->Add(m_search, 0, wxTOP|wxBOTTOM, wxSizerFlags::GetDefaultBorder());

wxBitmapButton* nextButton = new wxBitmapButton(this, ControlIDs::ID_SEARCH_NEXT,
Expand Down Expand Up @@ -47,7 +47,7 @@ SearchPanel::SearchPanel(wxWindow *parent, wxWindowID id) :

m_search->SetMenu(searchOptionsMenu);

Bind(wxEVT_TEXT_ENTER, &SearchPanel::OnSearch, this, ControlIDs::ID_SEARCH_TEXT_ENTRY);
Bind(wxEVT_SEARCH, &SearchPanel::OnSearch, this, ControlIDs::ID_SEARCH_TEXT_ENTRY);
Bind(wxEVT_BUTTON, &SearchPanel::OnSearchButton, this, ControlIDs::ID_SEARCH_NEXT);
Bind(wxEVT_BUTTON, &SearchPanel::OnSearchButton, this, ControlIDs::ID_SEARCH_PREVIOUS);
}
Expand Down

0 comments on commit febbefc

Please sign in to comment.