Commit 4b1be4a6 authored by Edric Milaret's avatar Edric Milaret Committed by gerrit2

fix: check if the state changed emitted is on the actual call

Also only make the call dissapear if it's over

Change-Id: I411ee890ec570f3c51791d678670d64f0c841d56
parent da51e385
......@@ -360,13 +360,11 @@ void
CallWidget::callStateChanged(Call* call, Call::State previousState)
{
Q_UNUSED(previousState)
if (call == nullptr)
if (call == nullptr
|| call != actualCall_)
return;
if (call->state() == Call::State::OVER
|| call->state() == Call::State::ERROR
|| call->state() == Call::State::FAILURE
|| call->state() == Call::State::ABORTED) {
if (call->state() == Call::State::OVER) {
setActualCall(nullptr);
ui->instantMessagingWidget->setMediaText(nullptr);
ui->stackedWidget->setCurrentWidget(ui->welcomePage);
......
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