From 1f56efe5ea82ad101d33fd20ca8e0ff7e0777633 Mon Sep 17 00:00:00 2001 From: "chunmao.guo" Date: Tue, 23 May 2023 14:24:31 +0800 Subject: [PATCH] FIX: printer file system debug log Change-Id: Iac9520de0d844fe24e116b0b4f0491c560ff3c26 (cherry picked from commit c97f927110b9c96cc8d43f521f88ea0e77522ff7) --- src/slic3r/GUI/Printer/PrinterFileSystem.cpp | 3 ++- src/slic3r/GUI/Widgets/WebView.cpp | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/slic3r/GUI/Printer/PrinterFileSystem.cpp b/src/slic3r/GUI/Printer/PrinterFileSystem.cpp index 829b0a262..5c53add3e 100644 --- a/src/slic3r/GUI/Printer/PrinterFileSystem.cpp +++ b/src/slic3r/GUI/Printer/PrinterFileSystem.cpp @@ -915,7 +915,7 @@ boost::uint32_t PrinterFileSystem::SendRequest(int type, json const &req, callba auto msg = oss.str(); //OutputDebugStringA(msg.c_str()); //OutputDebugStringA("\n"); - BOOST_LOG_TRIVIAL(info) << "PrinterFileSystem::SendRequest: " << type << " msg: " << msg; + wxLogMessage("PrinterFileSystem::SendRequest: \n%s\n", msg); boost::unique_lock l(m_mutex); m_messages.push_back(msg); m_callbacks.push_back(callback); @@ -1013,6 +1013,7 @@ void PrinterFileSystem::HandleResponse(boost::unique_lock &l, Bamb json root; //OutputDebugStringA(msg.c_str()); //OutputDebugStringA("\n"); + wxLogMessage("PrinterFileSystem::HandleResponse: \n%s\n", msg); std::istringstream iss(msg); int cmd = 0; int seq = -1; diff --git a/src/slic3r/GUI/Widgets/WebView.cpp b/src/slic3r/GUI/Widgets/WebView.cpp index ea8372a39..78454c60c 100644 --- a/src/slic3r/GUI/Widgets/WebView.cpp +++ b/src/slic3r/GUI/Widgets/WebView.cpp @@ -241,7 +241,8 @@ void WebView::LoadUrl(wxWebView * webView, wxString const &url) bool WebView::RunScript(wxWebView *webView, wxString const &javascript) { - if (Slic3r::GUI::wxGetApp().app_config->get("internal_developer_mode") == "true") + if (Slic3r::GUI::wxGetApp().app_config->get("internal_developer_mode") == "true" + && javascript.find("studio_userlogin") == wxString::npos) wxLogMessage("Running JavaScript:\n%s\n", javascript); try {