mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-10 08:17:51 -06:00
Reworked sys_color_changed() functions
Fixed OSX specific bugs: - toolbar flashing for some mainframe sizes (Retina specific) - size of mainframe when settings layout in slNew mode Added missed icons to the "white" folder
This commit is contained in:
parent
c09d702045
commit
a56bbea140
17 changed files with 135 additions and 11 deletions
|
@ -89,6 +89,19 @@ DPIFrame(NULL, wxID_ANY, "", wxDefaultPosition, wxDefaultSize, wxDEFAULT_FRAME_S
|
|||
|
||||
m_loaded = true;
|
||||
|
||||
#ifdef __APPLE__
|
||||
// Using SetMinSize() on Mac messes up the window position in some cases
|
||||
// cf. https://groups.google.com/forum/#!topic/wx-users/yUKPBBfXWO0
|
||||
// So, if we haven't possibility to set MinSize() for the MainFrame,
|
||||
// set the MinSize() as a half of regular for the m_plater and m_tabpanel, when settings layout is in slNew mode
|
||||
// Otherwise, MainFrame will be maximized by height
|
||||
if (slNew) {
|
||||
wxSize size = wxGetApp().get_min_size();
|
||||
size.SetWidth(int(0.5*size.GetHeight()));
|
||||
m_plater->SetMinSize(size);
|
||||
m_tabpanel->SetMinSize(size);
|
||||
}
|
||||
#endif
|
||||
// initialize layout
|
||||
auto sizer = new wxBoxSizer(wxVERTICAL);
|
||||
if (m_plater && m_layout != slOld)
|
||||
|
@ -101,7 +114,7 @@ DPIFrame(NULL, wxID_ANY, "", wxDefaultPosition, wxDefaultSize, wxDEFAULT_FRAME_S
|
|||
SetSizer(sizer);
|
||||
Fit();
|
||||
|
||||
const wxSize min_size = wxSize(76*wxGetApp().em_unit(), 49*wxGetApp().em_unit());
|
||||
const wxSize min_size = wxGetApp().get_min_size(); //wxSize(76*wxGetApp().em_unit(), 49*wxGetApp().em_unit());
|
||||
#ifdef __APPLE__
|
||||
// Using SetMinSize() on Mac messes up the window position in some cases
|
||||
// cf. https://groups.google.com/forum/#!topic/wx-users/yUKPBBfXWO0
|
||||
|
@ -1471,7 +1484,7 @@ SettingsDialog::SettingsDialog(MainFrame* mainframe)
|
|||
|
||||
// wxNB_NOPAGETHEME: Disable Windows Vista theme for the Notebook background. The theme performance is terrible on Windows 10
|
||||
// with multiple high resolution displays connected.
|
||||
m_tabpanel = new wxNotebook(this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxNB_TOP | wxTAB_TRAVERSAL | wxNB_NOPAGETHEME);
|
||||
m_tabpanel = new wxNotebook(this, wxID_ANY, wxDefaultPosition, wxGetApp().get_min_size(), wxNB_TOP | wxTAB_TRAVERSAL | wxNB_NOPAGETHEME);
|
||||
#ifndef __WXOSX__ // Don't call SetFont under OSX to avoid name cutting in ObjectList
|
||||
m_tabpanel->SetFont(Slic3r::GUI::wxGetApp().normal_font());
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue