mirror of
https://gitlab.freedesktop.org/libfprint/libfprint.git
synced 2026-06-11 18:38:07 +00:00
virtual-device: Mark finger as needed only after we start scanning
In case we sent a sleep event to the device we may want to wait it to emit the finger needed state before the timeout is completed. So add a function to manage this for all the scan cases
This commit is contained in:
@@ -41,13 +41,12 @@ dev_identify (FpDevice *dev)
|
||||
GPtrArray *prints;
|
||||
g_autofree char *scan_id = NULL;
|
||||
|
||||
fpi_device_get_identify_data (dev, &prints);
|
||||
fpi_device_report_finger_status (dev, FP_FINGER_STATUS_NEEDED);
|
||||
|
||||
scan_id = process_cmds (self, TRUE, &error);
|
||||
if (should_wait_for_command (self, error))
|
||||
scan_id = start_scan_command (self, &error);
|
||||
if (g_error_matches (error, G_IO_ERROR, G_IO_ERROR_PENDING))
|
||||
return;
|
||||
|
||||
fpi_device_get_identify_data (dev, &prints);
|
||||
|
||||
if (scan_id)
|
||||
{
|
||||
GVariant *data = NULL;
|
||||
|
||||
Reference in New Issue
Block a user