diff --git a/src/slic3r/GUI/MainFrame.cpp b/src/slic3r/GUI/MainFrame.cpp index ecd1ddea2..505a45125 100644 --- a/src/slic3r/GUI/MainFrame.cpp +++ b/src/slic3r/GUI/MainFrame.cpp @@ -58,9 +58,9 @@ wxFrame(NULL, wxID_ANY, SLIC3R_BUILD, wxDefaultPosition, wxDefaultSize, wxDEFAUL SLIC3R_VERSION + _(L(" - Remember to check for updates at http://github.com/prusa3d/slic3r/releases"))); - // m_appController->set_model(m_plater->model); - // m_appController->set_print(m_plater->print); - // m_plater->appController = m_appController; + m_appController->set_model(&m_plater->model()); + m_appController->set_print(&m_plater->print()); + GUI::set_gui_appctl(); // Make the global status bar and its progress indicator available in C++ diff --git a/src/slic3r/GUI/Plater.cpp b/src/slic3r/GUI/Plater.cpp index f2d42806c..4944ac6c6 100644 --- a/src/slic3r/GUI/Plater.cpp +++ b/src/slic3r/GUI/Plater.cpp @@ -1156,8 +1156,8 @@ std::vector Plater::priv::load_model_objects(const ModelObjectPtrs &mode update(); _3DScene::zoom_to_volumes(canvas3D); - // TODO - // $self->object_list_changed; + object_list_changed(); + // $self->schedule_background_process; return obj_idxs; @@ -1687,7 +1687,8 @@ Plater::~Plater() } Sidebar& Plater::sidebar() { return *p->sidebar; } -Model& Plater::model() { return p->model; } +Model& Plater::model() { return p->model; } +Print& Plater::print() { return p->print; } void Plater::load_files(const std::vector &input_files) { p->load_files(input_files); } diff --git a/src/slic3r/GUI/Plater.hpp b/src/slic3r/GUI/Plater.hpp index f8f24e2bc..ac641e6b1 100644 --- a/src/slic3r/GUI/Plater.hpp +++ b/src/slic3r/GUI/Plater.hpp @@ -16,6 +16,7 @@ class wxBoxSizer; namespace Slic3r { class Model; +class Print; namespace GUI { @@ -91,7 +92,8 @@ public: ~Plater(); Sidebar& sidebar(); - Model& model(); + Model& model(); + Print& print(); void load_files(const std::vector &input_files);