Commit 121bdf32 authored by Nicolas Jager's avatar Nicolas Jager

call : tell to the daemon to hang up when the call is over

Change-Id: I31ca827d5632b9cc11798282e69b90754b4db685
Tuleap: #1015
parent 5750df0d
...@@ -45,6 +45,7 @@ CallsViewModel::CallsViewModel() ...@@ -45,6 +45,7 @@ CallsViewModel::CallsViewModel()
delete call; delete call;
call->stateChange("", code); call->stateChange("", code);
callStatusUpdated(call); // used ? callStatusUpdated(call); // used ?
RingD::instance->hangUpCall(call);
return; return;
} }
call->stateChange(state, code); call->stateChange(state, code);
......
...@@ -160,6 +160,12 @@ RingClientUWP::RingD::cancelOutGoingCall(Call^ call) ...@@ -160,6 +160,12 @@ RingClientUWP::RingD::cancelOutGoingCall(Call^ call)
tasksList_.push(ref new RingD::Task(Request::CancelOutGoingCall, call)); tasksList_.push(ref new RingD::Task(Request::CancelOutGoingCall, call));
} }
void
RingClientUWP::RingD::hangUpCall(Call^ call)
{
tasksList_.push(ref new RingD::Task(Request::HangUpCall, call));
}
void void
RingClientUWP::RingD::startDaemon() RingClientUWP::RingD::startDaemon()
{ {
...@@ -355,6 +361,7 @@ RingD::dequeueTasks() ...@@ -355,6 +361,7 @@ RingD::dequeueTasks()
} }
break; break;
case Request::CancelOutGoingCall: case Request::CancelOutGoingCall:
case Request::HangUpCall:
{ {
auto callId = task->_call->callId; auto callId = task->_call->callId;
auto callId2 = Utils::toString(callId); auto callId2 = Utils::toString(callId);
......
...@@ -63,6 +63,7 @@ internal: ...@@ -63,6 +63,7 @@ internal:
void acceptIncommingCall(Call^ call); void acceptIncommingCall(Call^ call);
void placeCall(Contact^ contact); void placeCall(Contact^ contact);
void cancelOutGoingCall(Call^ call); void cancelOutGoingCall(Call^ call);
void hangUpCall(Call^ call);
/* TODO : move members */ /* TODO : move members */
bool hasConfig; bool hasConfig;
...@@ -82,7 +83,8 @@ private: ...@@ -82,7 +83,8 @@ private:
AddSIPAccount, AddSIPAccount,
RefuseIncommingCall, RefuseIncommingCall,
AcceptIncommingCall, AcceptIncommingCall,
CancelOutGoingCall CancelOutGoingCall,
HangUpCall
}; };
ref class Task ref class Task
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment