mirror of
https://git.jami.net/savoirfairelinux/jami-daemon.git
synced 2025-08-12 22:09:25 +08:00
callmanager: remove unused signals
Change-Id: Ia5659f670e4f1164afc1ac1016c9dd7fc187d0f3
This commit is contained in:
@ -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>
|
||||
|
@ -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)),
|
||||
|
@ -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){}
|
||||
|
@ -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))
|
||||
|
@ -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);
|
||||
}
|
@ -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){}
|
||||
|
@ -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 = {
|
||||
|
@ -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>(),
|
||||
|
@ -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);
|
||||
|
@ -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++;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user