diff options
author | Aleksander Morgado <aleksander@aleksander.es> | 2013-11-17 14:50:22 +0100 |
---|---|---|
committer | Aleksander Morgado <aleksander@aleksander.es> | 2014-02-13 13:40:27 +0100 |
commit | 8122153a88b6f87962d2702c14b642d4f344eca2 (patch) | |
tree | feb1d3248907125275a70e2b0b4c349418ba0c33 /src/mm-port-serial.h | |
parent | 6e35f0a8881de9f5a81a9abb2db17a15fda618bc (diff) |
port-serial: use GIO Async API like method for flash()
Diffstat (limited to 'src/mm-port-serial.h')
-rw-r--r-- | src/mm-port-serial.h | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/src/mm-port-serial.h b/src/mm-port-serial.h index 34be2193..e724a28b 100644 --- a/src/mm-port-serial.h +++ b/src/mm-port-serial.h @@ -43,10 +43,6 @@ typedef struct _MMPortSerial MMPortSerial; typedef struct _MMPortSerialClass MMPortSerialClass; -typedef void (*MMSerialFlashFn) (MMPortSerial *port, - GError *error, - gpointer user_data); - typedef void (*MMSerialResponseFn) (MMPortSerial *port, GByteArray *response, GError *error, @@ -131,12 +127,14 @@ gboolean mm_port_serial_reopen_finish (MMPortSerial *port, GAsyncResult *res, GError **error); -gboolean mm_port_serial_flash (MMPortSerial *self, +void mm_port_serial_flash (MMPortSerial *self, guint32 flash_time, gboolean ignore_errors, - MMSerialFlashFn callback, + GAsyncReadyCallback callback, gpointer user_data); - +gboolean mm_port_serial_flash_finish (MMPortSerial *self, + GAsyncResult *res, + GError **error); void mm_port_serial_flash_cancel (MMPortSerial *self); gboolean mm_port_serial_get_flash_ok (MMPortSerial *self); |