callmanager: remove unused signals

Change-Id: Ia5659f670e4f1164afc1ac1016c9dd7fc187d0f3
This commit is contained in:
Adrien Béraud
2019-11-11 14:52:23 -05:00
parent d87f2d32c1
commit 616e2df75b
10 changed files with 0 additions and 59 deletions

View File

@ -490,30 +490,6 @@
<arg type="b" name="isMixed" direction="in"/>
</method>
<signal name="newCallCreated" tp:name-for-bindings="newCallCreated">
<tp:docstring>
<p>Notify that a call has been created.</p>
<p>The callID generated by the daemon must be stored by the clients in order to address other actions for
this call. This signal is emitted when call haves been created by the daemon itself.</p>
<tp:rationale>The client must subscribe to this signal to handle calls created by other clients</tp:rationale>
</tp:docstring>
<arg type="s" name="accountID">
<tp:docstring>
The account ID of the call. Clients must notify the right account when receiving this signal.
</tp:docstring>
</arg>
<arg type="s" name="callID">
<tp:docstring>
A new call ID.
</tp:docstring>
</arg>
<arg type="s" name="to">
<tp:docstring>
The SIP URI this call is trying to reach.
</tp:docstring>
</arg>
</signal>
<signal name="incomingCall" tp:name-for-bindings="incomingCall">
<tp:docstring>
<p>Notify an incoming call.</p>

View File

@ -156,7 +156,6 @@ DBusClient::initLibrary(int flags)
exportable_callback<CallSignal::ConferenceChanged>(bind(&DBusCallManager::conferenceChanged, callM, _1, _2)),
exportable_callback<CallSignal::UpdatePlaybackScale>(bind(&DBusCallManager::updatePlaybackScale, callM, _1, _2, _3)),
exportable_callback<CallSignal::ConferenceRemoved>(bind(&DBusCallManager::conferenceRemoved, callM, _1)),
exportable_callback<CallSignal::NewCallCreated>(bind(&DBusCallManager::newCallCreated, callM, _1, _2, _3)),
exportable_callback<CallSignal::RecordingStateChanged>(bind(&DBusCallManager::recordingStateChanged, callM, _1, _2)),
exportable_callback<CallSignal::SecureSdesOn>(bind(&DBusCallManager::secureSdesOn, callM, _1)),
exportable_callback<CallSignal::SecureSdesOff>(bind(&DBusCallManager::secureSdesOff, callM, _1)),

View File

@ -39,7 +39,6 @@ public:
virtual void conferenceCreated(const std::string& conf_id){}
virtual void conferenceChanged(const std::string& conf_id, const std::string& state){}
virtual void conferenceRemoved(const std::string& conf_id){}
virtual void newCallCreated(const std::string& call_id, const std::string&, const std::string&){}
virtual void updatePlaybackScale(const std::string& filepath, int position, int scale){}
virtual void conferenceRemove(const std::string& conf_id){}
virtual void newCall(const std::string& account_id, const std::string& call_id, const std::string& to){}
@ -125,7 +124,6 @@ public:
virtual void conferenceCreated(const std::string& conf_id){}
virtual void conferenceChanged(const std::string& conf_id, const std::string& state){}
virtual void conferenceRemoved(const std::string& conf_id){}
virtual void newCallCreated(const std::string& call_id, const std::string&, const std::string&){}
virtual void updatePlaybackScale(const std::string& filepath, int position, int scale){}
virtual void conferenceRemove(const std::string& conf_id){}
virtual void newCall(const std::string& account_id, const std::string& call_id, const std::string& to){}

View File

@ -235,7 +235,6 @@ void init(ConfigurationCallback* confM, Callback* callM, PresenceCallback* presM
exportable_callback<CallSignal::ConferenceChanged>(bind(&Callback::conferenceChanged, callM, _1, _2)),
exportable_callback<CallSignal::UpdatePlaybackScale>(bind(&Callback::updatePlaybackScale, callM, _1, _2, _3)),
exportable_callback<CallSignal::ConferenceRemoved>(bind(&Callback::conferenceRemoved, callM, _1)),
exportable_callback<CallSignal::NewCallCreated>(bind(&Callback::newCallCreated, callM, _1, _2, _3)),
exportable_callback<CallSignal::RecordingStateChanged>(bind(&Callback::recordingStateChanged, callM, _1, _2)),
exportable_callback<CallSignal::RtcpReportReceived>(bind(&Callback::onRtcpReportReceived, callM, _1, _2)),
exportable_callback<CallSignal::PeerHold>(bind(&Callback::peerHold, callM, _1, _2))

View File

@ -24,7 +24,6 @@ Persistent<Function> registeredNameFoundCb;
Persistent<Function> callStateChangedCb;
Persistent<Function> incomingMessageCb;
Persistent<Function> incomingCallCb;
Persistent<Function> newCallCreatedCb;
std::queue<std::function<void() >> pendingSignals;
std::mutex pendingSignalsLock;
@ -62,8 +61,6 @@ Persistent<Function>* getPresistentCb(const std::string &signal) {
return &incomingMessageCb;
else if (signal == "IncomingCall")
return &incomingCallCb;
else if (signal == "NewCallCreated")
return &newCallCreatedCb;
else return nullptr;
}
@ -329,16 +326,3 @@ void incomingCall(const std::string& account_id, const std::string& call_id, con
uv_async_send(&signalAsync);
}
void newCallCreated(const std::string& account_id, const std::string& call_id, const std::string& to_uri) {
std::lock_guard<std::mutex> lock(pendingSignalsLock);
pendingSignals.emplace([account_id, call_id, to_uri]() {
Local<Function> func = Local<Function>::New(Isolate::GetCurrent(), newCallCreatedCb);
if (!func.IsEmpty()) {
Local<Value> callback_args[] = {V8_STRING_NEW(account_id), V8_STRING_NEW(call_id), V8_STRING_NEW(to_uri)};
func->Call(SWIGV8_CURRENT_CONTEXT()->Global(), 3, callback_args);
}
});
uv_async_send(&signalAsync);
}

View File

@ -39,7 +39,6 @@ public:
virtual void conferenceCreated(const std::string& conf_id){}
virtual void conferenceChanged(const std::string& conf_id, const std::string& state){}
virtual void conferenceRemoved(const std::string& conf_id){}
virtual void newCallCreated(const std::string& call_id, const std::string&, const std::string&){}
virtual void updatePlaybackScale(const std::string& filepath, int position, int scale){}
virtual void conferenceRemove(const std::string& conf_id){}
virtual void newCall(const std::string& account_id, const std::string& call_id, const std::string& to){}
@ -125,7 +124,6 @@ public:
virtual void conferenceCreated(const std::string& conf_id){}
virtual void conferenceChanged(const std::string& conf_id, const std::string& state){}
virtual void conferenceRemoved(const std::string& conf_id){}
virtual void newCallCreated(const std::string& call_id, const std::string&, const std::string&){}
virtual void updatePlaybackScale(const std::string& filepath, int position, int scale){}
virtual void conferenceRemove(const std::string& conf_id){}
virtual void newCall(const std::string& account_id, const std::string& call_id, const std::string& to){}

View File

@ -136,7 +136,6 @@ void init(const v8::Handle<v8::Value> &funcMap){
exportable_callback<CallSignal::IncomingMessage>(bind(&incomingMessage, _1, _2, _3)),
exportable_callback<CallSignal::VoiceMailNotify>(bind(&voiceMailNotify, _1, _2, _3, _4)),
exportable_callback<CallSignal::IncomingCall>(bind(&incomingCall, _1, _2, _3)),
exportable_callback<CallSignal::NewCallCreated>(bind(&newCallCreated, _1, _2, _3))
};
const std::map<std::string, SharedCallback> configEvHandlers = {

View File

@ -39,8 +39,6 @@ getSignalHandlers()
exported_callback<DRing::CallSignal::ConferenceChanged>(),
exported_callback<DRing::CallSignal::UpdatePlaybackScale>(),
exported_callback<DRing::CallSignal::ConferenceRemoved>(),
exported_callback<DRing::CallSignal::NewCallCreated>(),
exported_callback<DRing::CallSignal::SipCallStateChanged>(),
exported_callback<DRing::CallSignal::RecordingStateChanged>(),
exported_callback<DRing::CallSignal::SecureSdesOn>(),
exported_callback<DRing::CallSignal::SecureSdesOff>(),

View File

@ -153,14 +153,6 @@ struct DRING_PUBLIC CallSignal {
constexpr static const char* name = "ConferenceRemoved";
using cb_type = void(const std::string&);
};
struct DRING_PUBLIC NewCallCreated {
constexpr static const char* name = "NewCallCreated";
using cb_type = void(const std::string&, const std::string&, const std::string&);
};
struct DRING_PUBLIC SipCallStateChanged {
constexpr static const char* name = "SipCallStateChanged";
using cb_type = void(const std::string&, const std::string&, int);
};
struct DRING_PUBLIC RecordingStateChanged {
constexpr static const char* name = "RecordingStateChanged";
using cb_type = void(const std::string&, int);

View File

@ -1435,8 +1435,6 @@ Manager::createConfFromParticipantList(const std::vector< std::string > &partici
// Manager methods may behave differently if the call id participates in a conference
conf->add(call_id);
emitSignal<DRing::CallSignal::NewCallCreated>(account, call_id, tostr);
successCounter++;
}