mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-06-22 19:50:44 +00:00
ENH: clean codes about device
JIRA: [STUDIO-13609] Change-Id: I591de7033360b9570600006cfbce2148a8d031d5 (cherry picked from commit e9c774be8f4c89b8dafa14ef56913612fb68bd0c)
This commit is contained in:
18
src/slic3r/GUI/DeviceCore/DevLamp.cpp
Normal file
18
src/slic3r/GUI/DeviceCore/DevLamp.cpp
Normal file
@@ -0,0 +1,18 @@
|
||||
#include "DevLamp.h"
|
||||
|
||||
static Slic3r::DevLamp::LIGHT_EFFECT _light_effect_parse(std::string effect_str)
|
||||
{
|
||||
if (effect_str.compare("on") == 0)
|
||||
return Slic3r::DevLamp::LIGHT_EFFECT_ON;
|
||||
else if (effect_str.compare("off") == 0)
|
||||
return Slic3r::DevLamp::LIGHT_EFFECT_OFF;
|
||||
else if (effect_str.compare("flashing") == 0)
|
||||
return Slic3r::DevLamp::LIGHT_EFFECT_FLASHING;
|
||||
|
||||
return Slic3r::DevLamp::LIGHT_EFFECT_UNKOWN;
|
||||
}
|
||||
|
||||
void Slic3r::DevLamp::SetChamberLight(const std::string& status)
|
||||
{
|
||||
m_chamber_light = _light_effect_parse(status);
|
||||
}
|
||||
Reference in New Issue
Block a user