Merge pull request #10581 from matt123p/development

Put back SetOption40 support.
This commit is contained in:
Theo Arends 2021-01-17 16:37:10 +01:00 committed by GitHub
commit 221bf038d8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 0 deletions

View File

@ -270,6 +270,15 @@ void ButtonHandler(void) {
ExecuteCommand(scmnd, SRC_BUTTON);
}
}
else
{
if (Settings.param[P_HOLD_IGNORE] > 0) { // SetOption40 (0) - Do not ignore button hold
if (Button.hold_timer[button_index] > loops_per_second * Settings.param[P_HOLD_IGNORE] / 10) {
Button.hold_timer[button_index] = 0; // Reset button hold counter to stay below hold trigger
Button.press_counter[button_index] = 0; // Discard button press to disable functionality
}
}
}
}
}
}