From 7f513604438f9a10af9492ba68ff1c0798dfce66 Mon Sep 17 00:00:00 2001 From: Stefan Becker Date: Sun, 8 Mar 2015 18:24:08 +0200 Subject: [PATCH] status: remove sipe_status_update() --- src/core/sipe-ocs2007.c | 2 +- src/core/sipe-status.c | 19 +++++-------------- src/core/sipe-status.h | 1 - 3 files changed, 6 insertions(+), 16 deletions(-) diff --git a/src/core/sipe-ocs2007.c b/src/core/sipe-ocs2007.c index 611d80bf..58d19e57 100644 --- a/src/core/sipe-ocs2007.c +++ b/src/core/sipe-ocs2007.c @@ -1630,7 +1630,7 @@ static gboolean process_send_presence_category_publish_response(struct sipe_core if (has_device_publication) { send_publish_category_initial(sipe_private); } else { - sipe_status_update(sipe_private); + sipe_ocs2007_category_publish(sipe_private); } } return TRUE; diff --git a/src/core/sipe-status.c b/src/core/sipe-status.c index a4d4c6aa..0350bfeb 100644 --- a/src/core/sipe-status.c +++ b/src/core/sipe-status.c @@ -156,19 +156,6 @@ void sipe_status_and_note(struct sipe_core_private *sipe_private, } } -void sipe_status_update(struct sipe_core_private *sipe_private) -{ - guint activity = sipe_backend_status(SIPE_CORE_PUBLIC); - - if (activity == SIPE_ACTIVITY_UNSET) return; - - SIPE_DEBUG_INFO("sipe_status_update: status: %s (%s)", - sipe_status_activity_to_token(activity), - sipe_private->status_set_by_user ? "USER" : "MACHINE"); - - sipe_cal_presence_publish(sipe_private, FALSE); -} - void sipe_core_status_set(struct sipe_core_public *sipe_public, gboolean set_by_user, guint activity, @@ -178,6 +165,10 @@ void sipe_core_status_set(struct sipe_core_public *sipe_public, gchar *tmp; const gchar *status_id = sipe_status_activity_to_token(activity); + SIPE_DEBUG_INFO("sipe_core_status_set: status: %s (%s)", + status_id, + set_by_user ? "USER" : "MACHINE"); + sipe_private->status_set_by_user = set_by_user; sipe_status_set_token(sipe_private, status_id); @@ -194,7 +185,7 @@ void sipe_core_status_set(struct sipe_core_public *sipe_public, } g_free(tmp); - sipe_status_update(sipe_private); + sipe_cal_presence_publish(sipe_private, FALSE); } /* diff --git a/src/core/sipe-status.h b/src/core/sipe-status.h index 997dd812..c7c13e36 100644 --- a/src/core/sipe-status.h +++ b/src/core/sipe-status.h @@ -38,7 +38,6 @@ void sipe_status_set_activity(struct sipe_core_private *sipe_private, guint activity); void sipe_status_and_note(struct sipe_core_private *sipe_private, const gchar *status_id); -void sipe_status_update(struct sipe_core_private *sipe_private); /* Local Variables: -- 2.11.4.GIT