state-handler: simplify displaySet()

Simplify the function with a switch
This commit is contained in:
Vasily Davydov
2022-10-25 15:21:53 +03:00
parent cd06e2b3ba
commit 566d1d2659
2 changed files with 20 additions and 23 deletions

View File

@@ -60,12 +60,7 @@ enum _bars
enum _mode
{
MANUAL,
AUTO
};
enum _display
{
MODES,
AUTO,
SENSORS
};
@@ -105,9 +100,9 @@ public:
*
* AUTO MODE: P. SET: XXPa P. CURR: XXPa
*
* @param sensors the current printing mode
* @param mode the current printing mode
*/
void displaySet (bool sensors);
void displaySet (size_t mode);
/** Handle the given event of the current state
*