From 204b3fbcbfd1825dc71ff575fb6a5582d69e1071 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrien=20B=C3=A9raud?= <adrien.beraud@savoirfairelinux.com> Date: Wed, 6 Oct 2021 16:27:44 -0400 Subject: [PATCH] api: remove getDisplayNames Change-Id: If641609b25cf6dad1a2c91fe534c2fa3a7119ad1 --- bin/dbus/cx.ring.Ring.CallManager.xml | 17 ----------------- bin/dbus/dbuscallmanager.cpp | 7 ------- bin/dbus/dbuscallmanager.h | 1 - bin/jni/callmanager.i | 1 - bin/nodejs/callmanager.i | 1 - src/client/callmanager.cpp | 6 ------ src/conference.cpp | 14 -------------- src/conference.h | 5 ----- src/jami/callmanager_interface.h | 1 - src/manager.cpp | 9 --------- src/manager.h | 6 ------ 11 files changed, 68 deletions(-) diff --git a/bin/dbus/cx.ring.Ring.CallManager.xml b/bin/dbus/cx.ring.Ring.CallManager.xml index 96570c6790..b4d611fb85 100644 --- a/bin/dbus/cx.ring.Ring.CallManager.xml +++ b/bin/dbus/cx.ring.Ring.CallManager.xml @@ -807,23 +807,6 @@ </arg> </signal> - <method name="getDisplayNames" tp:name-for-bindings="getDisplayNames"> - <tp:added version="1.3.0"/> - <tp:docstring> - Get the display name of every participant in a given conference, or their number as a fallback. - </tp:docstring> - <arg type="s" name="confID" direction="in"> - <tp:docstring> - The conference ID. - </tp:docstring> - </arg> - <arg type="as" name="list" direction="out"> - <tp:docstring> - The list of the display names. - </tp:docstring> - </arg> - </method> - <method name="getParticipantList" tp:name-for-bindings="getParticipantList"> <tp:added version="0.9.7"/> <tp:docstring> diff --git a/bin/dbus/dbuscallmanager.cpp b/bin/dbus/dbuscallmanager.cpp index d711c8c389..30fe21d08c 100644 --- a/bin/dbus/dbuscallmanager.cpp +++ b/bin/dbus/dbuscallmanager.cpp @@ -252,13 +252,6 @@ DBusCallManager::getParticipantList(const std::string& confID) return DRing::getParticipantList(confID); } -auto -DBusCallManager::getDisplayNames(const std::string& confID) - -> decltype(DRing::getDisplayNames(confID)) -{ - return DRing::getDisplayNames(confID); -} - auto DBusCallManager::getConferenceId(const std::string& callID) -> decltype(DRing::getConferenceId(callID)) diff --git a/bin/dbus/dbuscallmanager.h b/bin/dbus/dbuscallmanager.h index 87a667eed6..333dbf40a4 100644 --- a/bin/dbus/dbuscallmanager.h +++ b/bin/dbus/dbuscallmanager.h @@ -97,7 +97,6 @@ public: bool unholdConference(const std::string& confID); std::vector<std::string> getConferenceList(); std::vector<std::string> getParticipantList(const std::string& confID); - std::vector<std::string> getDisplayNames(const std::string& confID); std::string getConferenceId(const std::string& callID); std::map<std::string, std::string> getConferenceDetails(const std::string& callID); bool startRecordedFilePlayback(const std::string& filepath); diff --git a/bin/jni/callmanager.i b/bin/jni/callmanager.i index 29358dce2e..0940865e27 100644 --- a/bin/jni/callmanager.i +++ b/bin/jni/callmanager.i @@ -99,7 +99,6 @@ bool holdConference(const std::string& confID); bool unholdConference(const std::string& confID); std::vector<std::string> getConferenceList(); std::vector<std::string> getParticipantList(const std::string& confID); -std::vector<std::string> getDisplayNames(const std::string& confID); std::string getConferenceId(const std::string& callID); std::map<std::string, std::string> getConferenceDetails(const std::string& callID); std::vector<std::map<std::string, std::string>> getConferenceInfos(const std::string& confId); diff --git a/bin/nodejs/callmanager.i b/bin/nodejs/callmanager.i index cc66372107..b7a1b1ee7e 100644 --- a/bin/nodejs/callmanager.i +++ b/bin/nodejs/callmanager.i @@ -90,7 +90,6 @@ bool holdConference(const std::string& confID); bool unholdConference(const std::string& confID); std::vector<std::string> getConferenceList(); std::vector<std::string> getParticipantList(const std::string& confID); -std::vector<std::string> getDisplayNames(const std::string& confID); std::string getConferenceId(const std::string& callID); std::map<std::string, std::string> getConferenceDetails(const std::string& callID); std::vector<std::map<std::string, std::string>> getConferenceInfos(const std::string& confId); diff --git a/src/client/callmanager.cpp b/src/client/callmanager.cpp index 841327b131..cf84f8e98b 100644 --- a/src/client/callmanager.cpp +++ b/src/client/callmanager.cpp @@ -262,12 +262,6 @@ getParticipantList(const std::string& confID) return jami::Manager::instance().getParticipantList(confID); } -std::vector<std::string> -getDisplayNames(const std::string& confID) -{ - return jami::Manager::instance().getDisplayNames(confID); -} - std::string getConferenceId(const std::string& callID) { diff --git a/src/conference.cpp b/src/conference.cpp index 4f809f5a5e..2c5c35eebb 100644 --- a/src/conference.cpp +++ b/src/conference.cpp @@ -717,20 +717,6 @@ Conference::getParticipantList() const return participants_; } -std::vector<std::string> -Conference::getDisplayNames() const -{ - std::vector<std::string> result; - result.reserve(participants_.size()); - - for (const auto& p : participants_) { - auto details = Manager::instance().getCallDetails(p); - const auto tmp = details["DISPLAY_NAME"]; - result.emplace_back(tmp.empty() ? details["PEER_NUMBER"] : tmp); - } - return result; -} - bool Conference::toggleRecording() { diff --git a/src/conference.h b/src/conference.h index ce631b4df0..0a2b185240 100644 --- a/src/conference.h +++ b/src/conference.h @@ -288,11 +288,6 @@ public: */ const ParticipantSet& getParticipantList() const; - /** - * Get the display names or peer numbers for this conference - */ - std::vector<std::string> getDisplayNames() const; - /** * Start/stop recording toggle */ diff --git a/src/jami/callmanager_interface.h b/src/jami/callmanager_interface.h index 202e591488..24f306de8a 100644 --- a/src/jami/callmanager_interface.h +++ b/src/jami/callmanager_interface.h @@ -87,7 +87,6 @@ DRING_PUBLIC bool holdConference(const std::string& confID); DRING_PUBLIC bool unholdConference(const std::string& confID); DRING_PUBLIC std::vector<std::string> getConferenceList(); DRING_PUBLIC std::vector<std::string> getParticipantList(const std::string& confID); -DRING_PUBLIC std::vector<std::string> getDisplayNames(const std::string& confID); DRING_PUBLIC std::string getConferenceId(const std::string& callID); DRING_PUBLIC std::map<std::string, std::string> getConferenceDetails(const std::string& callID); DRING_PUBLIC std::vector<std::map<std::string, std::string>> getConferenceInfos( diff --git a/src/manager.cpp b/src/manager.cpp index 5f3a8237c2..edd0427778 100644 --- a/src/manager.cpp +++ b/src/manager.cpp @@ -3195,15 +3195,6 @@ Manager::getConferenceList() const return map_utils::extractKeys(pimpl_->conferenceMap_); } -std::vector<std::string> -Manager::getDisplayNames(const std::string& confID) const -{ - if (auto conf = getConferenceFromID(confID)) - return conf->getDisplayNames(); - JAMI_WARN("Did not find conference %s", confID.c_str()); - return {}; -} - std::vector<std::string> Manager::getParticipantList(const std::string& confID) const { diff --git a/src/manager.h b/src/manager.h index b7b9b14e50..5accbd5461 100644 --- a/src/manager.h +++ b/src/manager.h @@ -552,12 +552,6 @@ public: */ std::vector<std::string> getParticipantList(const std::string& confID) const; - /** - * Get a list of the display names for everyone in a conference - * @return std::vector<std::string> A list of display names - */ - std::vector<std::string> getDisplayNames(const std::string& confID) const; - std::string getConferenceId(const std::string& callID); /** -- GitLab