[ekiga] Simplify presence code
- From: Eugen Dedu <ededu src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [ekiga] Simplify presence code
- Date: Mon, 16 Nov 2015 14:50:15 +0000 (UTC)
commit 71fd79639e0e4e29a675c366e55b63ef03bf4f7a
Author: Eugen Dedu <eugen dedu univ-fcomte fr>
Date: Mon Nov 16 15:49:03 2015 +0100
Simplify presence code
lib/engine/components/opal/opal-account.cpp | 13 ++++---------
lib/engine/components/opal/opal-account.h | 2 --
2 files changed, 4 insertions(+), 11 deletions(-)
---
diff --git a/lib/engine/components/opal/opal-account.cpp b/lib/engine/components/opal/opal-account.cpp
index 4fe9190..f823e2e 100644
--- a/lib/engine/components/opal/opal-account.cpp
+++ b/lib/engine/components/opal/opal-account.cpp
@@ -961,17 +961,12 @@ Opal::Account::on_consult (const std::string url)
void
Opal::Account::publish (const Ekiga::PersonalDetails& details)
{
- std::string presence = details.get_presence ();
-
- personal_state = OpalPresenceInfo::Available;
- presence_status = details.get_status ();
-
if (opal_presentity) {
- OpalPresenceInfo opi = OpalPresenceInfo (personal_state);
- opi.m_activities = PString (presence);
- opi.m_note = presence_status;
+ OpalPresenceInfo opi = OpalPresenceInfo (OpalPresenceInfo::Available);
+ opi.m_activities = PString (details.get_presence ());
+ opi.m_note = details.get_status ();
opal_presentity->SetLocalPresence (opi);
- PTRACE (4, "Ekiga\tSent its own presence (publish) for " << get_aor() << ": " << presence << ", note "
<< presence_status);
+ PTRACE (4, "Ekiga\tSent its own presence (publish) for " << get_aor() << ": " << details.get_presence ()
<< ", note " << details.get_status ());
}
}
diff --git a/lib/engine/components/opal/opal-account.h b/lib/engine/components/opal/opal-account.h
index cd437e9..ea11717 100644
--- a/lib/engine/components/opal/opal-account.h
+++ b/lib/engine/components/opal/opal-account.h
@@ -270,8 +270,6 @@ private:
boost::function0<std::list<std::string> > existing_groups;
xmlNodePtr node;
xmlNodePtr roster_node;
- OpalPresenceInfo::State personal_state;
- std::string presence_status;
void presence_status_in_main (std::string uri,
std::string presence,
std::string status) const;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]