mirror of
https://github.com/Rockbox/rockbox.git
synced 2026-05-12 19:53:18 -04:00
pass event data to usb_acknowledge
add second argument to usb_acknowledge. it can be used for more appropriate connection tracking that does not rely on timeout in the future. Change-Id: I8a44366b7c7a1f944524c4ba8ecd6d9673746a65
This commit is contained in:
parent
d5506dfa22
commit
1951c17e0b
33 changed files with 54 additions and 46 deletions
|
|
@ -38,6 +38,7 @@
|
|||
* Handled by the gui code since that's how events are delivered
|
||||
* TODO: this is an ugly kludge */
|
||||
bool is_usb_connected = false;
|
||||
intptr_t usb_connection_seqnum = 0;
|
||||
|
||||
static bool screenshot_enabled = false;
|
||||
|
||||
|
|
@ -71,7 +72,7 @@ void usb_mode(void)
|
|||
return;
|
||||
|
||||
splashf(0, "USB mode");
|
||||
usb_acknowledge(SYS_USB_CONNECTED_ACK);
|
||||
usb_acknowledge(SYS_USB_CONNECTED_ACK, usb_connection_seqnum);
|
||||
|
||||
while(is_usb_connected)
|
||||
get_button(TIMEOUT_BLOCK);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue