Skip to content
Snippets Groups Projects
Commit e8edb153 authored by Sébastien Blin's avatar Sébastien Blin Committed by Andreas Traczyk
Browse files

ongoingcall: show chatview when receiving new interaction

Change-Id: I97c5f42ab622bb87666203a251915dbbb5b5d84d
GitLab: #429
parent 43639171
Branches
Tags
No related merge requests found
......@@ -300,6 +300,12 @@ Rectangle {
anchors.fill: parent
function toggleConversation() {
inCallMessageWebViewStack.visible ?
closeInCallConversation() :
openInCallConversation()
}
Connections {
target: CallAdapter
......@@ -330,6 +336,16 @@ Rectangle {
}
}
Connections {
target: MessagesAdapter
function onNewInteraction(interactionType) {
// Ignore call notifications, as we are in the call.
if (interactionType !== Interaction.Type.CALL && !inCallMessageWebViewStack.visible)
openInCallConversation()
}
}
onChatButtonClicked: {
inCallMessageWebViewStack.visible ?
closeInCallConversation() :
......
......@@ -487,6 +487,7 @@ MessagesAdapter::newInteraction(const QString& accountId,
auto& convModel = accountInfo.conversationModel;
convModel->clearUnreadInteractions(convUid);
printNewInteraction(*convModel, interactionId, interaction);
Q_EMIT newInteraction(static_cast<int>(interaction.type));
} catch (...) {
}
}
......
......@@ -95,6 +95,7 @@ Q_SIGNALS:
void contactBanned();
void navigateToWelcomePageRequested();
void invitationAccepted();
void newInteraction(int type);
public Q_SLOTS:
void slotSendMessageContentSaved(const QString& content);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment