Actually apply button pulldown

Properly follow ternary else() chain, help out by pre-pending if()
Resolve #2239, thanks to @sigmafx
This commit is contained in:
Max Prokhorov
2020-05-01 21:54:53 +03:00
committed by GitHub
parent ff2718e8ca
commit e60c561f70

View File

@@ -79,9 +79,9 @@ constexpr const debounce_event::types::Config _buttonDecodeConfigBitmask(const u
((bitmask & ButtonMask::DefaultHigh)
? debounce_event::types::PinValue::High
: debounce_event::types::PinValue::Low),
((bitmask & ButtonMask::SetPullup)
? debounce_event::types::PinMode::InputPullup : (bitmask & ButtonMask::SetPulldown)
? debounce_event::types::PinMode::InputPullup : debounce_event::types::PinMode::Input)
((bitmask & ButtonMask::SetPullup) ? debounce_event::types::PinMode::InputPullup
: (bitmask & ButtonMask::SetPulldown) ? debounce_event::types::PinMode::InputPulldown
: debounce_event::types::PinMode::Input)
};
}