Handle setting palette when effect is still on default solid and will not display it

This commit is contained in:
Scott Bailey 2021-05-01 12:53:34 -07:00
parent 90e8ae1457
commit 845dcabe0c

View File

@ -592,6 +592,9 @@ void decodeIRJson(uint32_t code)
{
// repeatable action
lastValidCode = code;
} if (effectCurrent == 0 && cmdStr.indexOf("FP=") > -1) {
// setting palette but it wont show because effect is solid
effectCurrent = FX_MODE_GRADIENT;
}
if (!cmdStr.startsWith("win&")) {
cmdStr = "win&" + cmdStr;
@ -599,7 +602,7 @@ void decodeIRJson(uint32_t code)
handleSet(nullptr, cmdStr, false);
}
} else if (!jsonCmdObj.isNull()) {
serializeJson(jsonCmdObj, Serial);
// command is JSON object
deserializeState(jsonCmdObj);
}
}