From a49c6912417465d01afc70d0c041fd943e0c6061 Mon Sep 17 00:00:00 2001 From: Lukas Matena Date: Thu, 16 Sep 2021 14:48:24 +0200 Subject: [PATCH] SendSystemInfoDialog now opens through CallAfter, GL extensions are sorted --- src/slic3r/GUI/GUI_App.cpp | 7 ++++--- src/slic3r/GUI/SendSystemInfoDialog.cpp | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/slic3r/GUI/GUI_App.cpp b/src/slic3r/GUI/GUI_App.cpp index 56f58a515..e1fcc029a 100644 --- a/src/slic3r/GUI/GUI_App.cpp +++ b/src/slic3r/GUI/GUI_App.cpp @@ -669,9 +669,6 @@ void GUI_App::post_init() if (app_config->get("show_hints") == "1" && ! is_gcode_viewer()) plater_->get_notification_manager()->push_hint_notification(true); - // 'Send system info' dialog - show_send_system_info_dialog_if_needed(); - // The extra CallAfter() is needed because of Mac, where this is the only way // to popup a modal dialog on start without screwing combo boxes. // This is ugly but I honestly found no better way to do it. @@ -685,6 +682,10 @@ void GUI_App::post_init() }); } + // 'Send system info' dialog. Again, a CallAfter is needed on mac. + // Without it, GL extensions did not show. + CallAfter([] { show_send_system_info_dialog_if_needed(); }); + #ifdef _WIN32 // Sets window property to mainframe so other instances can indentify it. OtherInstanceMessageHandler::init_windows_properties(mainframe, m_instance_hash_int); diff --git a/src/slic3r/GUI/SendSystemInfoDialog.cpp b/src/slic3r/GUI/SendSystemInfoDialog.cpp index 0d5e0c369..eead1f781 100644 --- a/src/slic3r/GUI/SendSystemInfoDialog.cpp +++ b/src/slic3r/GUI/SendSystemInfoDialog.cpp @@ -294,6 +294,7 @@ static std::string generate_system_info_json() std::string extensions_str = gl_get_string_safe(GL_EXTENSIONS, ""); std::vector extensions_list; boost::split(extensions_list, extensions_str, boost::is_any_of(" "), boost::token_compress_off); + std::sort(extensions_list.begin(), extensions_list.end()); pt::ptree extensions_node; for (const std::string& s : extensions_list) { if (s.empty())