fix(color): Source selection for curve display (#2894)
This commit is contained in:
@@ -297,13 +297,19 @@ void CurveEdit::onEvent(event_t event)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void CurveEdit::checkEvents()
|
void CurveEdit::checkEvents()
|
||||||
{
|
{
|
||||||
if (!lockSource) {
|
if (!lockSource) {
|
||||||
int16_t val = getMovedSource(MIXSRC_FIRST_INPUT);
|
int16_t val = getMovedSource(MIXSRC_FIRST_INPUT);
|
||||||
if (val) {
|
if (val > 0) {
|
||||||
CurveEdit::currentSource = val + 1 - MIXSRC_FIRST_INPUT;
|
if (val > NUM_STICKS + NUM_POTS + NUM_SLIDERS)
|
||||||
TRACE("source=%d", CurveEdit::currentSource);
|
CurveEdit::currentSource = val + 1 - MIXSRC_FIRST_INPUT;
|
||||||
|
else {
|
||||||
|
CurveEdit::currentSource = expoAddress(val - 1)->srcRaw;
|
||||||
|
TRACE("Detected source=%d", val);
|
||||||
|
}
|
||||||
|
TRACE("Applied source=%d", CurveEdit::currentSource);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
FormField::checkEvents();
|
FormField::checkEvents();
|
||||||
|
|||||||
Reference in New Issue
Block a user