Move sc_usb out of sc_aoa

This will allow to initialize a USB device separately and pass it to
sc_aoa.

PR #2974 <https://github.com/Genymobile/scrcpy/pull/2974>
This commit is contained in:
Romain Vimont
2022-01-24 23:11:42 +01:00
parent 48e3ff284f
commit adda47b0f7
3 changed files with 27 additions and 25 deletions

View File

@@ -30,7 +30,7 @@ sc_hid_event_destroy(struct sc_hid_event *hid_event);
struct sc_hid_event_queue CBUF(struct sc_hid_event, 64);
struct sc_aoa {
struct sc_usb usb;
struct sc_usb *usb;
sc_thread thread;
sc_mutex mutex;
sc_cond event_cond;
@@ -41,7 +41,7 @@ struct sc_aoa {
};
bool
sc_aoa_init(struct sc_aoa *aoa, const char *serial, struct sc_acksync *acksync);
sc_aoa_init(struct sc_aoa *aoa, struct sc_usb *usb, struct sc_acksync *acksync);
void
sc_aoa_destroy(struct sc_aoa *aoa);