From f995c63e1bc56dd2d098a06f130d55334979f38f Mon Sep 17 00:00:00 2001 From: Martin Szulecki Date: Fri, 24 Jul 2009 16:35:28 +0200 Subject: Add new NP_ITDBPREP_DID_END notification signaling music db refresh --- dev/main.c | 3 ++- include/libiphone/notification_proxy.h | 1 + src/NotificationProxy.h | 3 ++- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/dev/main.c b/dev/main.c index 33ebc2d..b4e5c34 100644 --- a/dev/main.c +++ b/dev/main.c @@ -113,10 +113,11 @@ int main(int argc, char *argv[]) printf("ERROR: Notification proxy could not be started.\n"); } if (gnp) { - const char *nspec[4] = { + const char *nspec[5] = { NP_SYNC_CANCEL_REQUEST, NP_SYNC_SUSPEND_REQUEST, NP_SYNC_RESUME_REQUEST, + NP_ITDBPREP_DID_END, NULL }; np_observe_notifications(gnp, nspec); diff --git a/include/libiphone/notification_proxy.h b/include/libiphone/notification_proxy.h index 8efb483..14d1b39 100644 --- a/include/libiphone/notification_proxy.h +++ b/include/libiphone/notification_proxy.h @@ -46,6 +46,7 @@ typedef struct np_client_int *np_client_t; #define NP_DS_DOMAIN_CHANGED "com.apple.mobile.data_sync.domain_changed" #define NP_APP_INSTALLED "com.apple.mobile.application_installed" #define NP_APP_UNINSTALLED "com.apple.mobile.application_uninstalled" +#define NP_ITDBPREP_DID_END "com.apple.itdbprep.notification.didEnd" iphone_error_t np_new_client ( iphone_device_t device, int dst_port, np_client_t *client ); iphone_error_t np_free_client ( np_client_t client ); diff --git a/src/NotificationProxy.h b/src/NotificationProxy.h index a10cde4..02f4251 100644 --- a/src/NotificationProxy.h +++ b/src/NotificationProxy.h @@ -28,7 +28,7 @@ struct np_client_int { GThread *notifier; }; -static const char *np_default_notifications[10] = { +static const char *np_default_notifications[11] = { NP_SYNC_SUSPEND_REQUEST, NP_SYNC_RESUME_REQUEST, NP_PHONE_NUMBER_CHANGED, @@ -38,6 +38,7 @@ static const char *np_default_notifications[10] = { NP_DS_DOMAIN_CHANGED, NP_APP_INSTALLED, NP_APP_UNINSTALLED, + NP_ITDBPREP_DID_END, NULL }; -- cgit v1.1-32-gdbae