Implement per-screen DPI on Windows, DPI change event, wxDialog & wxFrame mixin base classes

This commit is contained in:
Vojtech Kral 2019-04-02 12:00:50 +02:00
parent af05e5fc2c
commit 7e32f2df71
5 changed files with 159 additions and 2 deletions
src/slic3r/GUI

View file

@ -32,7 +32,7 @@ namespace Slic3r {
namespace GUI {
MainFrame::MainFrame() :
wxFrame(NULL, wxID_ANY, SLIC3R_BUILD, wxDefaultPosition, wxDefaultSize, wxDEFAULT_FRAME_STYLE, "mainframe"),
DPIFrame(NULL, wxID_ANY, SLIC3R_BUILD, wxDefaultPosition, wxDefaultSize, wxDEFAULT_FRAME_STYLE, "mainframe"),
m_printhost_queue_dlg(new PrintHostQueueDialog(this))
{
// Load the icon either from the exe, or from the ico file.
@ -256,6 +256,11 @@ bool MainFrame::can_delete_all() const
return (m_plater != nullptr) ? !m_plater->model().objects.empty() : false;
}
void MainFrame::on_dpi_changed(const wxRect &suggested_rect)
{
// TODO
}
void MainFrame::init_menubar()
{
#ifdef __APPLE__