mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-05-19 19:33:47 +00:00
FIX: the display problem of wxHyperlink on MAC15
jira: [STUDIO-11043] Change-Id: Ibc796e22d4dbee7f94d134f5b8444637f6e1390d (cherry picked from commit cf3ae1bd1acd17622762fc9275f92c7525649f52)
This commit is contained in:
@@ -558,11 +558,15 @@ SelectMachineDialog::SelectMachineDialog(Plater *plater)
|
|||||||
|
|
||||||
wxBoxSizer *sizer_advanced_options_title = new wxBoxSizer(wxHORIZONTAL);
|
wxBoxSizer *sizer_advanced_options_title = new wxBoxSizer(wxHORIZONTAL);
|
||||||
|
|
||||||
m_hyperlink = new wxHyperlinkCtrl(m_scroll_area, wxID_ANY, _L("Click here if you can't connect to the printer"),
|
m_connect_printer_help_hyperlink = new Label(m_scroll_area, _L("Click here if you can't connect to the printer ->"));
|
||||||
wxT("https://wiki.bambulab.com/en/software/bambu-studio/failed-to-connect-printer"), wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE);
|
m_connect_printer_help_hyperlink->SetForegroundColour(0x00ae42);
|
||||||
m_hyperlink->SetFont(::Label::Body_12);
|
m_connect_printer_help_hyperlink->SetBackgroundColour(*wxWHITE);
|
||||||
|
m_connect_printer_help_hyperlink->Bind(wxEVT_ENTER_WINDOW, [this](auto& e) { SetCursor(wxCURSOR_HAND); });
|
||||||
|
m_connect_printer_help_hyperlink->Bind(wxEVT_LEAVE_WINDOW, [this](auto& e) { SetCursor(wxCURSOR_ARROW); });
|
||||||
|
m_connect_printer_help_hyperlink->Bind(wxEVT_LEFT_DOWN, [this](auto& e) { wxLaunchDefaultBrowser(wxT("https://wiki.bambulab.com/en/software/bambu-studio/failed-to-connect-printer"));});
|
||||||
|
m_connect_printer_help_hyperlink->SetFont(::Label::Body_13);
|
||||||
|
|
||||||
sizer_advanced_options_title->Add(m_hyperlink, 0, wxALIGN_CENTER, 0);
|
sizer_advanced_options_title->Add(m_connect_printer_help_hyperlink, 0, wxALIGN_CENTER, 0);
|
||||||
sizer_advanced_options_title->Add(0, 0, 1, wxEXPAND, 0);
|
sizer_advanced_options_title->Add(0, 0, 1, wxEXPAND, 0);
|
||||||
|
|
||||||
m_options_other = new wxPanel(m_scroll_area);
|
m_options_other = new wxPanel(m_scroll_area);
|
||||||
@@ -3678,14 +3682,14 @@ void SelectMachineDialog::set_default()
|
|||||||
m_comboBox_printer->Show(true);
|
m_comboBox_printer->Show(true);
|
||||||
m_button_refresh->Show(true);
|
m_button_refresh->Show(true);
|
||||||
m_rename_normal_panel->Show(true);
|
m_rename_normal_panel->Show(true);
|
||||||
m_hyperlink->Show(true);
|
m_connect_printer_help_hyperlink->Show(true);
|
||||||
}
|
}
|
||||||
else if (m_print_type == PrintFromType::FROM_SDCARD_VIEW) {
|
else if (m_print_type == PrintFromType::FROM_SDCARD_VIEW) {
|
||||||
m_stext_printer_title->Show(false);
|
m_stext_printer_title->Show(false);
|
||||||
m_comboBox_printer->Show(true);
|
m_comboBox_printer->Show(true);
|
||||||
m_button_refresh->Show(false);
|
m_button_refresh->Show(false);
|
||||||
m_rename_normal_panel->Show(false);
|
m_rename_normal_panel->Show(false);
|
||||||
m_hyperlink->Show(false);
|
m_connect_printer_help_hyperlink->Show(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
//project name
|
//project name
|
||||||
|
|||||||
@@ -360,7 +360,7 @@ protected:
|
|||||||
TextInput* m_rename_input{nullptr};
|
TextInput* m_rename_input{nullptr};
|
||||||
wxTimer* m_refresh_timer{ nullptr };
|
wxTimer* m_refresh_timer{ nullptr };
|
||||||
wxScrolledWindow* m_sw_print_failed_info{nullptr};
|
wxScrolledWindow* m_sw_print_failed_info{nullptr};
|
||||||
wxHyperlinkCtrl* m_hyperlink{nullptr};
|
Label* m_connect_printer_help_hyperlink{nullptr};
|
||||||
ScalableBitmap * rename_editable{nullptr};
|
ScalableBitmap * rename_editable{nullptr};
|
||||||
ScalableBitmap * rename_editable_light{nullptr};
|
ScalableBitmap * rename_editable_light{nullptr};
|
||||||
wxStaticBitmap * timeimg{nullptr};
|
wxStaticBitmap * timeimg{nullptr};
|
||||||
|
|||||||
Reference in New Issue
Block a user