mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-12-09 05:05:20 -05:00
Button queue handling is split from main button driver
First half of https://gerrit.rockbox.org/r/c/rockbox/+/570 Change-Id: Icc64dfd8194c18f69564ed5f8bf7dd70a4330eb9
This commit is contained in:
parent
5954a2fd48
commit
da9d67a0fe
30 changed files with 266 additions and 221 deletions
|
|
@ -133,12 +133,12 @@ int button_read_device(void)
|
|||
if ((~GPIOA_INPUT_VAL & 0x40) != rec_switch)
|
||||
{
|
||||
if (rec_switch) {
|
||||
queue_post(&button_queue,BUTTON_REC_SW_OFF,0);
|
||||
queue_post(&button_queue,BUTTON_REC_SW_OFF|BUTTON_REL,0);
|
||||
button_queue_post(BUTTON_REC_SW_OFF,0);
|
||||
button_queue_post(BUTTON_REC_SW_OFF|BUTTON_REL,0);
|
||||
}
|
||||
else {
|
||||
queue_post(&button_queue,BUTTON_REC_SW_ON,0);
|
||||
queue_post(&button_queue,BUTTON_REC_SW_ON|BUTTON_REL,0);
|
||||
button_queue_post(BUTTON_REC_SW_ON,0);
|
||||
button_queue_post(BUTTON_REC_SW_ON|BUTTON_REL,0);
|
||||
}
|
||||
rec_switch = ~GPIOA_INPUT_VAL & 0x40;
|
||||
backlight_on();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue