Disable rotary encoder rotation while pressed (will hopefully prevent some of the common unwanted edits when pressing, thanks 3djc for the idea)
This commit is contained in:
@@ -94,7 +94,7 @@ uint8_t keyDown()
|
||||
void checkRotaryEncoder()
|
||||
{
|
||||
uint32_t newpos = ROTARY_ENCODER_POSITION();
|
||||
if (newpos != rotencPosition) {
|
||||
if (newpos != rotencPosition && !keyState(KEY_ENTER)) {
|
||||
if ((rotencPosition & 0x01) ^ ((newpos & 0x02) >> 1)) {
|
||||
--rotencValue[0];
|
||||
}
|
||||
|
||||
@@ -89,7 +89,7 @@ uint8_t keyDown()
|
||||
void checkRotaryEncoder()
|
||||
{
|
||||
uint32_t newpos = ROTARY_ENCODER_POSITION();
|
||||
if (newpos != rotencPosition) {
|
||||
if (newpos != rotencPosition && !keyState(KEY_ENTER)) {
|
||||
if ((rotencPosition & 0x01) ^ ((newpos & 0x02) >> 1)) {
|
||||
--rotencValue[0];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user