NEW:multi printer manager filtering O1D
jira:[STUDIO-10745] Change-Id: I30dff6fe2e64b9079b6794d1c9da46358a6a97c3
This commit is contained in:
parent
ccb70f415c
commit
8da9e674a2
|
@ -5,7 +5,7 @@
|
||||||
namespace Slic3r {
|
namespace Slic3r {
|
||||||
namespace GUI {
|
namespace GUI {
|
||||||
|
|
||||||
|
|
||||||
MultiMachinePage::MultiMachinePage(wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style)
|
MultiMachinePage::MultiMachinePage(wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style)
|
||||||
: wxPanel(parent, id, pos, size, style)
|
: wxPanel(parent, id, pos, size, style)
|
||||||
{
|
{
|
||||||
|
@ -15,7 +15,7 @@ MultiMachinePage::MultiMachinePage(wxWindow* parent, wxWindowID id, const wxPoin
|
||||||
SetSizerAndFit(m_main_sizer);
|
SetSizerAndFit(m_main_sizer);
|
||||||
Layout();
|
Layout();
|
||||||
Fit();
|
Fit();
|
||||||
|
|
||||||
wxGetApp().UpdateDarkUIWin(this);
|
wxGetApp().UpdateDarkUIWin(this);
|
||||||
|
|
||||||
init_timer();
|
init_timer();
|
||||||
|
@ -315,7 +315,7 @@ MultiMachinePickPage::MultiMachinePickPage(Plater* plater /*= nullptr*/)
|
||||||
|
|
||||||
auto line_top = new wxPanel(this, wxID_ANY, wxDefaultPosition, wxSize(-1, 1), wxTAB_TRAVERSAL);
|
auto line_top = new wxPanel(this, wxID_ANY, wxDefaultPosition, wxSize(-1, 1), wxTAB_TRAVERSAL);
|
||||||
line_top->SetBackgroundColour(wxColour(166, 169, 170));
|
line_top->SetBackgroundColour(wxColour(166, 169, 170));
|
||||||
|
|
||||||
m_label = new Label(this, _L("Select connected printers (0/6)"));
|
m_label = new Label(this, _L("Select connected printers (0/6)"));
|
||||||
|
|
||||||
scroll_macine_list = new wxScrolledWindow(this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxVSCROLL);
|
scroll_macine_list = new wxScrolledWindow(this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxVSCROLL);
|
||||||
|
@ -376,8 +376,8 @@ void MultiMachinePickPage::update_selected_count()
|
||||||
|
|
||||||
if (m_selected_count > PICK_DEVICE_MAX) {
|
if (m_selected_count > PICK_DEVICE_MAX) {
|
||||||
MessageDialog msg_wingow(nullptr, wxString::Format(_L("The maximum number of printers that can be selected is %d"), PICK_DEVICE_MAX), "", wxAPPLY | wxOK);
|
MessageDialog msg_wingow(nullptr, wxString::Format(_L("The maximum number of printers that can be selected is %d"), PICK_DEVICE_MAX), "", wxAPPLY | wxOK);
|
||||||
if (msg_wingow.ShowModal() == wxOK) {
|
if (msg_wingow.ShowModal() == wxOK) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -426,6 +426,10 @@ void MultiMachinePickPage::refresh_user_device()
|
||||||
std::vector<std::string> subscribe_list;
|
std::vector<std::string> subscribe_list;
|
||||||
|
|
||||||
for (auto it = user_machine.begin(); it != user_machine.end(); ++it) {
|
for (auto it = user_machine.begin(); it != user_machine.end(); ++it) {
|
||||||
|
if (it->second->m_extder_data.total_extder_count > 1) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
DevicePickItem* di = new DevicePickItem(scroll_macine_list, it->second);
|
DevicePickItem* di = new DevicePickItem(scroll_macine_list, it->second);
|
||||||
|
|
||||||
di->Bind(EVT_MULTI_DEVICE_SELECTED_FINHSH, [this, di](auto& e) {
|
di->Bind(EVT_MULTI_DEVICE_SELECTED_FINHSH, [this, di](auto& e) {
|
||||||
|
|
Loading…
Reference in New Issue