mirror of
https://github.com/QIDITECH/QIDISlicer.git
synced 2026-01-30 23:48:44 +03:00
print_host
This commit is contained in:
@@ -2143,13 +2143,15 @@ void MainFrame::select_tab(size_t tab/* = size_t(-1)*/)
|
|||||||
bool isValidIPAddress = true;
|
bool isValidIPAddress = true;
|
||||||
DynamicPrintConfig *cfg_t = &(printer->config);
|
DynamicPrintConfig *cfg_t = &(printer->config);
|
||||||
|
|
||||||
|
const auto opt = cfg_t->option<ConfigOptionEnum<PrintHostType>>("host_type");
|
||||||
|
const auto host_type = opt != nullptr ? opt->value : htOctoPrint;
|
||||||
wxStringTokenizer tokenizer3((data->lower_name), wxT("*"), wxTOKEN_RET_EMPTY_ALL);
|
wxStringTokenizer tokenizer3((data->lower_name), wxT("*"), wxTOKEN_RET_EMPTY_ALL);
|
||||||
wxString printer_name = tokenizer3.GetNextToken();
|
wxString printer_name = tokenizer3.GetNextToken();
|
||||||
|
|
||||||
if (isValidIPAddress) {
|
if (isValidIPAddress) {
|
||||||
m_printer_view->AddButton(
|
m_printer_view->AddButton(
|
||||||
printer_name, host, (data->model_id), (data->fullname),
|
printer_name, host, (data->model_id), (data->fullname), (data->selected),
|
||||||
(data->selected), cfg_t);
|
(host_type == htMoonraker), cfg_t);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user