mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-11 08:47:52 -06:00
ConfigWizard: Bugfixes
This commit is contained in:
parent
b0f54e5709
commit
7d969a6f36
6 changed files with 96 additions and 56 deletions
|
@ -351,21 +351,26 @@ void GUI_App::persist_window_geometry(wxTopLevelWindow *window)
|
|||
});
|
||||
|
||||
window_pos_restore(window, name);
|
||||
#ifdef _WIN32
|
||||
// On windows, the wxEVT_SHOW is not received if the window is created maximized
|
||||
// cf. https://groups.google.com/forum/#!topic/wx-users/c7ntMt6piRI
|
||||
// so we sanitize the position right away
|
||||
window_pos_sanitize(window);
|
||||
#else
|
||||
// On other platforms on the other hand it's needed to wait before the window is actually on screen
|
||||
// and some initial round of events is complete otherwise position / display index is not reported correctly.
|
||||
window->Bind(wxEVT_SHOW, [=](wxShowEvent &event) {
|
||||
CallAfter([=]() {
|
||||
window_pos_sanitize(window);
|
||||
});
|
||||
event.Skip();
|
||||
|
||||
// #ifdef _WIN32
|
||||
// // On windows, the wxEVT_SHOW is not received if the window is created maximized
|
||||
// // cf. https://groups.google.com/forum/#!topic/wx-users/c7ntMt6piRI
|
||||
// // so we sanitize the position right away
|
||||
// window_pos_sanitize(window);
|
||||
// #else
|
||||
// // On other platforms on the other hand it's needed to wait before the window is actually on screen
|
||||
// // and some initial round of events is complete otherwise position / display index is not reported correctly.
|
||||
// window->Bind(wxEVT_SHOW, [=](wxShowEvent &event) {
|
||||
// CallAfter([=]() {
|
||||
// window_pos_sanitize(window);
|
||||
// });
|
||||
// event.Skip();
|
||||
// });
|
||||
// #endif
|
||||
|
||||
on_window_geometry(window, [=]() {
|
||||
window_pos_sanitize(window);
|
||||
});
|
||||
#endif
|
||||
}
|
||||
|
||||
void GUI_App::load_project(wxWindow *parent, wxString& input_file)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue