diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/notification_proxy.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/notification_proxy.c b/src/notification_proxy.c index b82378a..7d84e30 100644 --- a/src/notification_proxy.c +++ b/src/notification_proxy.c | |||
| @@ -33,7 +33,7 @@ | |||
| 33 | struct np_thread { | 33 | struct np_thread { |
| 34 | np_client_t client; | 34 | np_client_t client; |
| 35 | np_notify_cb_t cbfunc; | 35 | np_notify_cb_t cbfunc; |
| 36 | void *userdata; | 36 | void *user_data; |
| 37 | }; | 37 | }; |
| 38 | 38 | ||
| 39 | /** | 39 | /** |
| @@ -334,7 +334,7 @@ gpointer np_notifier( gpointer arg ) | |||
| 334 | while (npt->client->parent) { | 334 | while (npt->client->parent) { |
| 335 | np_get_notification(npt->client, ¬ification); | 335 | np_get_notification(npt->client, ¬ification); |
| 336 | if (notification) { | 336 | if (notification) { |
| 337 | npt->cbfunc(notification, npt->userdata); | 337 | npt->cbfunc(notification, npt->user_data); |
| 338 | free(notification); | 338 | free(notification); |
| 339 | notification = NULL; | 339 | notification = NULL; |
| 340 | } | 340 | } |
| @@ -356,8 +356,8 @@ gpointer np_notifier( gpointer arg ) | |||
| 356 | * @param client the NP client | 356 | * @param client the NP client |
| 357 | * @param notify_cb pointer to a callback function or NULL to de-register a | 357 | * @param notify_cb pointer to a callback function or NULL to de-register a |
| 358 | * previously set callback function. | 358 | * previously set callback function. |
| 359 | * @param userdata Pointer that will be passed to the callback function as | 359 | * @param user_data Pointer that will be passed to the callback function as |
| 360 | * userdata. If notify_cb is NULL, this parameter is ignored. | 360 | * user data. If notify_cb is NULL, this parameter is ignored. |
| 361 | * | 361 | * |
| 362 | * @note Only one callback function can be registered at the same time; | 362 | * @note Only one callback function can be registered at the same time; |
| 363 | * any previously set callback function will be removed automatically. | 363 | * any previously set callback function will be removed automatically. |
| @@ -366,7 +366,7 @@ gpointer np_notifier( gpointer arg ) | |||
| 366 | * NP_E_INVALID_ARG when client is NULL, or NP_E_UNKNOWN_ERROR when | 366 | * NP_E_INVALID_ARG when client is NULL, or NP_E_UNKNOWN_ERROR when |
| 367 | * the callback thread could no be created. | 367 | * the callback thread could no be created. |
| 368 | */ | 368 | */ |
| 369 | np_error_t np_set_notify_callback( np_client_t client, np_notify_cb_t notify_cb, void *userdata ) | 369 | np_error_t np_set_notify_callback( np_client_t client, np_notify_cb_t notify_cb, void *user_data ) |
| 370 | { | 370 | { |
| 371 | if (!client) | 371 | if (!client) |
| 372 | return NP_E_INVALID_ARG; | 372 | return NP_E_INVALID_ARG; |
| @@ -388,7 +388,7 @@ np_error_t np_set_notify_callback( np_client_t client, np_notify_cb_t notify_cb, | |||
| 388 | if (npt) { | 388 | if (npt) { |
| 389 | npt->client = client; | 389 | npt->client = client; |
| 390 | npt->cbfunc = notify_cb; | 390 | npt->cbfunc = notify_cb; |
| 391 | npt->userdata = userdata; | 391 | npt->user_data = user_data; |
| 392 | 392 | ||
| 393 | client->notifier = g_thread_create(np_notifier, npt, TRUE, NULL); | 393 | client->notifier = g_thread_create(np_notifier, npt, TRUE, NULL); |
| 394 | if (client->notifier) { | 394 | if (client->notifier) { |
