diff options
author | YuSanka <yusanka@gmail.com> | 2021-12-08 12:40:47 +0300 |
---|---|---|
committer | YuSanka <yusanka@gmail.com> | 2021-12-08 12:40:47 +0300 |
commit | 3d23907056f892bd426d5722614d8f3b60a3600b (patch) | |
tree | 9adf8227c6b9e22ef18ebd5e3a5795c41cc36b1f | |
parent | c9727b5a57d0e78c386130c1eee5bb330d3b7cee (diff) |
Fix of the position of "PrusaSlicer: Open hyperlink" Dialog
More info https://github.com/prusa3d/PrusaSlicer/issues/7419#issuecomment-988231014
-rw-r--r-- | src/slic3r/GUI/OptionsGroup.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/slic3r/GUI/OptionsGroup.cpp b/src/slic3r/GUI/OptionsGroup.cpp index 84bfd1f9f..958a912a2 100644 --- a/src/slic3r/GUI/OptionsGroup.cpp +++ b/src/slic3r/GUI/OptionsGroup.cpp @@ -2,6 +2,7 @@ #include "ConfigExceptions.hpp" #include "Plater.hpp" #include "GUI_App.hpp" +#include "Mainframe.hpp" #include "OG_CustomCtrl.hpp" #include "MsgDialog.hpp" #include "format.hpp" @@ -978,7 +979,8 @@ bool OptionsGroup::launch_browser(const std::string& path_end) bool launch = true; if (get_app_config()->get("suppress_hyperlinks").empty()) { - RichMessageDialog dialog(nullptr, _L("Open hyperlink in default browser?"), _L("PrusaSlicer: Open hyperlink"), wxYES_NO); + wxWindow* parent = wxGetApp().mainframe->m_tabpanel; + RichMessageDialog dialog(parent, _L("Open hyperlink in default browser?"), _L("PrusaSlicer: Open hyperlink"), wxYES_NO); dialog.ShowCheckBox(_L("Remember my choice")); int answer = dialog.ShowModal(); @@ -989,7 +991,7 @@ bool OptionsGroup::launch_browser(const std::string& path_end) _L("You will not be asked about it again on label hovering.") + "\n\n" + format_wxstr(_L("Visit \"Preferences\" and check \"%1%\"\nto changes your choice."), preferences_item); - MessageDialog msg_dlg(nullptr, msg, _L("PrusaSlicer: Don't ask me again"), wxOK | wxCANCEL | wxICON_INFORMATION); + MessageDialog msg_dlg(parent, msg, _L("PrusaSlicer: Don't ask me again"), wxOK | wxCANCEL | wxICON_INFORMATION); if (msg_dlg.ShowModal() == wxID_CANCEL) return false; |