feature add get pc name function

This commit is contained in:
alves
2025-12-16 18:08:20 +08:00
parent 6688f3c0ed
commit 399fbc7a33
2 changed files with 5 additions and 0 deletions

View File

@@ -1030,6 +1030,8 @@ void MainFrame::get_local_webview_version()
std::ifstream json_file(versionFilePath);
if (!json_file.is_open()) {
std::ifstream json_file(versionFilePath);
BOOST_LOG_TRIVIAL(error) << "check flutter version error with file path:" << versionFilePath;
return;
}
nlohmann::json json_data;

View File

@@ -20,6 +20,7 @@
#include <boost/nowide/convert.hpp>
#include <boost/property_tree/ptree.hpp>
#include <boost/property_tree/json_parser.hpp>
#include <boost/asio/ip/host_name.hpp>
#include <slic3r/GUI/Widgets/WebView.hpp>
@@ -90,6 +91,8 @@ bool WCP_Logger::set_level(wxString& level)
}
}
std::string WCP_Logger::get_pc_name() { return boost::asio::ip::host_name(); }
// Add a log message to the queue
void WCP_Logger::add_log(const wxString& content, bool is_web = false, wxString time = "", wxString module = "Default", wxString level = "debug")
{