diff --git a/plugins/builtin/source/content/popups/hex_editor/popup_hex_editor_find.cpp b/plugins/builtin/source/content/popups/hex_editor/popup_hex_editor_find.cpp index c9221303d..bc67b02cb 100644 --- a/plugins/builtin/source/content/popups/hex_editor/popup_hex_editor_find.cpp +++ b/plugins/builtin/source/content/popups/hex_editor/popup_hex_editor_find.cpp @@ -47,10 +47,13 @@ namespace hex::plugin::builtin { } if(ImGuiExt::IconHyperlink(ICON_VS_SEARCH, "hex.builtin.view.hex_editor.search.advanced"_lang)) { - const auto& view = ContentRegistry::Views::getViewByName("hex.builtin.view.find.name"); - view->getWindowOpenState() = true; - ImGui::SetWindowFocus(view->getName().c_str()); - editor->closePopup(); + TaskManager::doLater([&editor] { + const auto& view = ContentRegistry::Views::getViewByName("hex.builtin.view.find.name"); + + view->getWindowOpenState() = true; + ImGui::SetWindowFocus(view->getName().c_str()); + editor->closePopup(); + }); } if (lastMode != *s_searchMode) {