FIX:fixed clicking on first item has no effect in search dialog

Change-Id: Ifdbbf06a8b5c780155e394003470f6fa39a2b4c2
This commit is contained in:
tao wang 2022-10-10 15:53:11 +08:00 committed by Lane.Wei
parent efec8fef2f
commit 0761cbd1cb
2 changed files with 3 additions and 3 deletions

View file

@ -365,8 +365,8 @@ void OptionsSearcher::show_dialog(Preset::Type type, wxWindow *parent, wxTextCtr
{
if (parent == nullptr || input == nullptr) return;
auto search_dialog = new SearchDialog(this, type, parent, input, ssearch_btn);
wxPoint pos = parent->ClientToScreen(wxPoint(0, 0));
pos.y += parent->GetRect().height;
wxPoint pos = input->GetParent()->ClientToScreen(wxPoint(0, 0));
pos.y += input->GetParent()->GetRect().height;
search_dialog->SetPosition(pos);
search_dialog->Popup();
}