mirror of
https://gitlab.freedesktop.org/libfprint/libfprint.git
synced 2025-11-15 07:38:12 +00:00
lib: Add more args to fpi_ssm callbacks
Pass the struct fp_dev and user_data to fpi_ssm callbacks, so that we might be able to get rid of the fpi_ssm_get_user_data(), and fpi_ssm_get_dev() as most drivers just get those from the ssm anyway in their callbacks.
This commit is contained in:
@@ -42,20 +42,28 @@ typedef struct fpi_ssm fpi_ssm;
|
||||
/**
|
||||
* ssm_completed_fn:
|
||||
* @ssm: a #fpi_ssm state machine
|
||||
* @dev: the #fp_dev fingerprint device
|
||||
* @user_data: the user data passed to fpi_ssm_new()
|
||||
*
|
||||
* The callback called when a state machine completes successfully,
|
||||
* as set when calling fpi_ssm_start().
|
||||
*/
|
||||
typedef void (*ssm_completed_fn)(fpi_ssm *ssm);
|
||||
typedef void (*ssm_completed_fn)(fpi_ssm *ssm,
|
||||
struct fp_dev *dev,
|
||||
void *user_data);
|
||||
|
||||
/**
|
||||
* ssm_handler_fn:
|
||||
* @ssm: a #fpi_ssm state machine
|
||||
* @dev: the #fp_dev fingerprint device
|
||||
* @user_data: the user data passed to fpi_ssm_new()
|
||||
*
|
||||
* The callback called when a state machine transitions from one
|
||||
* state to the next, as set when calling fpi_ssm_new().
|
||||
*/
|
||||
typedef void (*ssm_handler_fn)(fpi_ssm *ssm);
|
||||
typedef void (*ssm_handler_fn)(fpi_ssm *ssm,
|
||||
struct fp_dev *dev,
|
||||
void *user_data);
|
||||
|
||||
/* for library and drivers */
|
||||
fpi_ssm *fpi_ssm_new(struct fp_dev *dev,
|
||||
|
||||
Reference in New Issue
Block a user