Add QIDI model and opptimize user avatars

This commit is contained in:
QIDI TECH
2024-09-20 09:38:18 +08:00
parent 71eb63a2eb
commit 73e8cede50
14 changed files with 35 additions and 46 deletions

View File

@@ -253,7 +253,7 @@ else ()
set(MACOSX_BUNDLE_ICON_FILE Icon.icns)
set(MACOSX_BUNDLE_BUNDLE_NAME "QIDI Studio")
set(MACOSX_BUNDLE_SHORT_VERSION_STRING ${SLIC3R_VERSION})
set(MACOSX_BUNDLE_COPYRIGHT "Copyright(C) 2021-2023 Lunkuo All Rights Reserved")
set(MACOSX_BUNDLE_COPYRIGHT "Copyright(C) 2024 QIDI All Rights Reserved")
endif()
add_custom_command(TARGET QIDIStudio POST_BUILD
COMMAND ln -sfn "${SLIC3R_RESOURCES_DIR}" "${BIN_RESOURCES_DIR}"

View File

@@ -3263,6 +3263,18 @@ GCode::LayerResult GCode::process_layer(
// QDS
int bed_temp = get_bed_temperature(first_extruder_id, false, print.config().curr_bed_type);
gcode += m_writer.set_bed_temperature(bed_temp);
//w32
{
int min_chamber_temp = 0;
min_chamber_temp = m_config.chamber_temperatures.get_at(m_writer.extruders().front().id());
for (const auto& extruder : m_writer.extruders())
min_chamber_temp = std::min(min_chamber_temp, m_config.chamber_temperatures.get_at(extruder.id()));
if ( print.config().support_chamber_temp_control.value && min_chamber_temp > 0) {
gcode += m_writer.set_chamber_temperature(min_chamber_temp, false);
}
}
// Mark the temperature transition from 1st to 2nd layer to be finished.
m_second_layer_things_done = true;
}

View File

@@ -12,7 +12,7 @@ PRODUCTVERSION @SLIC3R_VERSION@
VALUE "ProductName", "@SLIC3R_APP_NAME@ G-code Viewer"
VALUE "ProductVersion", "@SLIC3R_BUILD_ID@"
VALUE "InternalName", "@SLIC3R_APP_NAME@ G-code Viewer"
VALUE "LegalCopyright", "Copyright(C) 2021-2023 Lunkuo All Rights Reserved"
VALUE "LegalCopyright", "Copyright(C) 2024 QIDI All Rights Reserved"
VALUE "OriginalFilename", "qidi-gcodeviewer.exe"
}
}

View File

@@ -12,7 +12,7 @@ PRODUCTVERSION @SLIC3R_VERSION@
VALUE "ProductName", "@SLIC3R_APP_NAME@"
VALUE "ProductVersion", "@SLIC3R_BUILD_ID@"
VALUE "InternalName", "@SLIC3R_APP_NAME@"
VALUE "LegalCopyright", "Copyright(C) 2021-2023 Lunkuo All Rights Reserved"
VALUE "LegalCopyright", "Copyright(C) 2024 QIDI All Rights Reserved"
VALUE "OriginalFilename", "qidi-studio.exe"
}
}

View File

@@ -5,7 +5,7 @@
<key>CFBundleExecutable</key>
<string>@SLIC3R_APP_KEY@</string>
<key>CFBundleGetInfoString</key>
<string>@SLIC3R_APP_NAME@ Copyright(C) 2021-2023 Lunkuo All Rights Reserved</string>
<string>@SLIC3R_APP_NAME@ Copyright(C) 2024 QIDI All Rights Reserved</string>
<key>CFBundleIconFile</key>
<string>images/QIDIStudio.icns</string>
<key>CFBundleName</key>

View File

@@ -242,7 +242,7 @@ AboutDialog::AboutDialog()
//B
// version
{
vesizer->Add(0, FromDIP(165), 1, wxEXPAND, FromDIP(5));
vesizer->Add(0, FromDIP(190), 1, wxEXPAND, FromDIP(5));
auto version_text = GUI_App::format_display_version();
#if QDT_INTERNAL_TESTING
wxString versionText = QDT_INTERNAL_TESTING == 1 ? _L("Internal Version") : _L("Beta Version");
@@ -260,19 +260,19 @@ AboutDialog::AboutDialog()
version_font.SetPointSize(FromDIP(16));
version->SetFont(version_font);
version->SetForegroundColour(wxColour("#FFFFFD"));
version->SetBackgroundColour(wxColour("#4479FB"));
version->SetBackgroundColour(wxColour("#303ab2"));
vesizer->Add(version, 0, wxALL | wxALIGN_CENTER_HORIZONTAL, FromDIP(5));
#if QDT_INTERNAL_TESTING
wxString plugin_version = wxString::Format("Plugin Version: %s", wxGetApp().getAgent() ? wxGetApp().getAgent()->get_version() : "");
wxStaticText *plugin_version_text = new wxStaticText(this, wxID_ANY, plugin_version, wxDefaultPosition, wxDefaultSize);
plugin_version_text->SetForegroundColour(wxColour("#FFFFFE"));
plugin_version_text->SetBackgroundColour(wxColour("#4479FB"));
plugin_version_text->SetBackgroundColour(wxColour("#303ab2"));
vesizer->Add(plugin_version_text, 0, wxALL | wxALIGN_CENTER_HORIZONTAL, FromDIP(5));
wxString build_time = wxString::Format("Build Time: %s", std::string(SLIC3R_BUILD_TIME));
wxStaticText* build_time_text = new wxStaticText(this, wxID_ANY, build_time, wxDefaultPosition, wxDefaultSize);
build_time_text->SetForegroundColour(wxColour("#FFFFFE"));
build_time_text->SetBackgroundColour(wxColour("#4479FB"));
build_time_text->SetBackgroundColour(wxColour("#303ab2"));
vesizer->Add(build_time_text, 0, wxALL | wxALIGN_CENTER_HORIZONTAL, FromDIP(5));
#endif
vesizer->Add(0, 0, 1, wxEXPAND, FromDIP(5));
@@ -331,7 +331,7 @@ AboutDialog::AboutDialog()
copyright_hor_sizer->Add(copyright_ver_sizer, 0, wxLEFT, FromDIP(20));
wxStaticText *html_text = new wxStaticText(this, wxID_ANY, "Copyright(C) 2021-2024 Lunkuo All Rights Reserved", wxDefaultPosition, wxDefaultSize);
wxStaticText *html_text = new wxStaticText(this, wxID_ANY, "Copyright(C) 2024 QIDI All Rights Reserved", wxDefaultPosition, wxDefaultSize);
html_text->SetForegroundColour(wxColour(107, 107, 107));
copyright_ver_sizer->Add(html_text, 0, wxALL , 0);

View File

@@ -96,8 +96,6 @@
#include "Notebook.hpp"
#include "Widgets/Label.hpp"
#include "Widgets/ProgressDialog.hpp"
#include <io.h>
#include <cstdio>
//QDS: DailyTip and UserGuide Dialog
#include "WebDownPluginDlg.hpp"
@@ -3956,18 +3954,9 @@ void GUI_App::get_login_info()
{
m_user_name = "";
wxGetApp().app_config->set("user_token", "");
wxGetApp().app_config->set("user_head_url", "");
wxGetApp().app_config->set("user_head_name", "");
wxString user_head_path = (boost::filesystem::path(Slic3r::data_dir()) / "user" / head_name).make_preferred().string();
wxString strJS = wxString::Format("SetUserOffline()");
GUI::wxGetApp().run_script_left(strJS);
//y34
std::ifstream file(user_head_path);
if (file.good())
{
file.close();
remove(user_head_path.c_str());
}
m_qidi_login = false;
}
else
@@ -4003,22 +3992,8 @@ void GUI_App::get_login_info()
}
else
{
std::string head_name = wxGetApp().app_config->get("user_head_name");
//y34
if (!head_name.empty())
{
wxString user_head_path = (boost::filesystem::path(Slic3r::data_dir()) / "user" / head_name).make_preferred().string();
std::ifstream file(user_head_path);
if (file.good())
{
file.close();
remove(user_head_path.c_str());
}
}
m_user_name = "";
wxGetApp().app_config->set("user_token", "");
wxGetApp().app_config->set("user_head_url", "");
wxGetApp().app_config->set("user_head_name", "");
wxString strJS = wxString::Format("SetUserOffline()");
GUI::wxGetApp().run_script_left(strJS);
m_qidi_login = false;

View File

@@ -500,7 +500,7 @@ wxMenu* MenuFactory::append_submenu_add_generic(wxMenu* menu, ModelVolumeType ty
//B
if (type == ModelVolumeType::INVALID) {
sub_menu->AppendSeparator();
for (auto &item : { L("3DBenchy"), L("ksr FDMTest")}) {
for (auto &item : { L("QIDI"), L("3DBenchy"), L("ksr FDMTest")}) {
append_menu_item(
sub_menu, wxID_ANY, _(item), "", [type, item](wxCommandEvent &) { obj_list()->load_generic_subobject(item, type); }, "", menu);
}

View File

@@ -2106,6 +2106,9 @@ static TriangleMesh create_mesh(const std::string& type_name, const BoundingBoxf
mesh.ReadSTLFile((Slic3r::resources_dir() + "/model/torus.stl").c_str(), true, nullptr);
else if (type_name == "Rounded Rectangle")
mesh.ReadSTLFile((Slic3r::resources_dir() + "/model/rounded_rectangle.stl").c_str(), true, nullptr);
//ZY3
else if (type_name == "QIDI")
mesh.ReadSTLFile((Slic3r::resources_dir() + "/model/QIDI.stl").c_str(), true, nullptr);
else if (type_name == "3DBenchy")
mesh.ReadSTLFile((Slic3r::resources_dir() + "/model/3DBenchy.stl").c_str(), true, nullptr);
else if (type_name == "ksr FDMTest")

View File

@@ -1950,6 +1950,9 @@ bool MainFrame::get_enable_print_status()
{
enable = false;
}
//y37
if(m_plater->only_gcode_mode())
enable = false;
enable = enable && !is_all_plates;
}
else if (m_print_select == eExportGcode)

View File

@@ -1317,7 +1317,7 @@ SelectMachineDialog::SelectMachineDialog(Plater *plater, wxString title)
// wxString hyperlink_1 = wxString::Format(L"https://wiki.qidi3d.com/%s/software/qidi-studio/fluidd", region);
// m_hyperlink = new wxHyperlinkCtrl(m_panel_prepare, wxID_ANY, _L("Click here if you can't connect to the printer"), hyperlink_1, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE);
wxString hyperlink_2 = wxString::Format(L"https://wiki.qidi3d.com/%s/software/qidi-studio/troubleshooting/connect-send-problem", region);
m_hyperlink = new wxHyperlinkCtrl(m_panel_prepare, wxID_ANY, _L("Click here if you failed to send the task"), hyperlink_2, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE);
m_hyperlink = new wxHyperlinkCtrl(m_panel_prepare, wxID_ANY, _L("Click here if you failed to send the print job"), hyperlink_2, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE);
hyperlink_sizer->Add(m_hyperlink, 0, wxALIGN_CENTER | wxALL, 5);
m_sizer_prepare->Add(hyperlink_sizer, 0, wxALIGN_CENTER | wxALL, 5);

View File

@@ -492,12 +492,12 @@ wxBitmap create_scaled_bitmap_of_login(const std::string& bmp_name_in,
Slic3r::GUI::wxGetApp().dark_mode();
// Try loading an SVG first, then PNG if SVG is not found:
wxBitmap* bmp;
wxBitmap* bmp{nullptr};
if(!bmp_name.empty())
bmp = cache.load_login_png(bmp_name, width, height, grayscale, resize ? win->FromDIP(10) * 0.1f : 0.f);
else
{
if(px_cnt > 50)
if (px_cnt > 50)
bmp = cache.load_png("user_dark", width, height, grayscale, resize ? win->FromDIP(10) * 0.1f : 0.f);
else
{
@@ -505,11 +505,8 @@ wxBitmap create_scaled_bitmap_of_login(const std::string& bmp_name_in,
bmp = cache.load_png("user_dark_tiny", width, height, grayscale, resize ? win->FromDIP(10) * 0.1f : 0.f);
}
}
if (bmp == nullptr) {
// Neither SVG nor PNG has been found, raise error
if (bmp == nullptr)
throw Slic3r::RuntimeError("Could not load bitmap: " + bmp_name);
}
return *bmp;
}

View File

@@ -175,10 +175,9 @@ wxString OctoPrint::get_test_ok_msg () const
wxString OctoPrint::get_test_failed_msg (wxString &msg) const
{
return GUI::from_u8((boost::format("%s: %s\n\n%s")
% _utf8(L("Could not connect to OctoPrint"))
% std::string(msg.ToUTF8())
% _utf8(L("Note: OctoPrint version at least 1.1.0 is required."))).str());
return GUI::from_u8((boost::format("%s: %s\n")
% _utf8(L("Could not connect to Moonraker"))
% std::string(msg.ToUTF8())).str());
}
bool OctoPrint::upload(PrintHostUpload upload_data, ProgressFn prorgess_fn, ErrorFn error_fn) const