ENH: do not show the functions if it is not supported
Change-Id: Iaee9c756f40fd26c376160e9cda305bee88d713b Signed-off-by: Stone Li <stone.li@bambulab.com>
This commit is contained in:
@@ -1807,6 +1807,7 @@ void StatusPanel::update_ams(MachineObject *obj)
|
||||
// update obj in sub dlg
|
||||
if (m_ams_setting_dlg) {
|
||||
m_ams_setting_dlg->obj = obj;
|
||||
|
||||
if (obj && m_ams_setting_dlg->IsShown()) {
|
||||
m_ams_setting_dlg->update_insert_material_read_mode(obj->ams_insert_flag);
|
||||
m_ams_setting_dlg->update_starting_read_mode(obj->ams_power_on_flag);
|
||||
@@ -2445,6 +2446,7 @@ void StatusPanel::on_ams_setting_click(SimpleEvent &event)
|
||||
try {
|
||||
int ams_id_int = atoi(ams_id.c_str());
|
||||
m_ams_setting_dlg->ams_id = ams_id_int;
|
||||
m_ams_setting_dlg->ams_support_remain = obj->ams_support_remain;
|
||||
m_ams_setting_dlg->Show();
|
||||
} catch (...) {
|
||||
;
|
||||
|
||||
Reference in New Issue
Block a user