From c4eabc3c523cf5b80bff388ff734f5b22e6cc6ab Mon Sep 17 00:00:00 2001 From: Ian Chua Date: Fri, 21 Aug 2026 14:14:23 +0800 Subject: [PATCH] fix: extend access code requirements t 0, 8 or more characters. --- src/slic3r/GUI/ReleaseNote.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/slic3r/GUI/ReleaseNote.cpp b/src/slic3r/GUI/ReleaseNote.cpp index 7b2d091176..fa6bab3eb3 100644 --- a/src/slic3r/GUI/ReleaseNote.cpp +++ b/src/slic3r/GUI/ReleaseNote.cpp @@ -1736,7 +1736,7 @@ void InputIpAddressDialog::set_machine_obj(MachineObject* obj) auto str_ip = m_input_ip->GetTextCtrl()->GetValue(); auto str_access_code = m_input_access_code->GetTextCtrl()->GetValue(); // ORCA enabling / disabling buttons with conditions enough to change its style - m_button_ok->Enable(isIp(str_ip.ToStdString()) && str_access_code.Length() == 8); + m_button_ok->Enable(isIp(str_ip.ToStdString()) && str_access_code.Length() >= 8); Layout(); Fit(); @@ -2056,10 +2056,6 @@ void InputIpAddressDialog::on_text(wxCommandEvent &evt) auto str_ip = m_input_ip->GetTextCtrl()->GetValue(); auto str_access_code = m_input_access_code->GetTextCtrl()->GetValue(); - if (str_access_code.empty()) { - str_access_code = "88888888"; - } - auto str_name = m_input_printer_name->GetTextCtrl()->GetValue().Strip(wxString::both); auto str_sn = m_input_sn->GetTextCtrl()->GetValue().Strip(wxString::both); bool invalid_access_code = true; @@ -2072,7 +2068,8 @@ void InputIpAddressDialog::on_text(wxCommandEvent &evt) } // ORCA enabling / disabling buttons with conditions enough to change its style - bool enable_btns = isIp(str_ip.ToStdString()) && str_access_code.Length() == 8 && invalid_access_code; + bool valid_access_code_length = str_access_code.Length() >= 8; + bool enable_btns = isIp(str_ip.ToStdString()) && valid_access_code_length && invalid_access_code; m_button_manual_setup->Enable(enable_btns); m_button_ok->Enable(enable_btns);