Commit 00502fca authored by Ming Rui Zhang's avatar Ming Rui Zhang

callwidget: fix the issue that smartlist context menu does not show corresponding view

for issue #529

Change-Id: I5ad4c105961719b0eba0b28c8ed35765298b92e6
parent dc11de92
......@@ -383,22 +383,26 @@ CallWidget::setupSmartListContextMenu(const QPoint& pos)
menu.addAction(videoCallAction);
connect(videoCallAction, &QAction::triggered,
[this, convUid, conversation, convModel]() {
convModel->placeCall(convUid);
if (!ui->messageView->isVisible())
showChatView(LRCInstance::getCurrAccId(), conversation);
ui->callingPhoto->setPixmap(QPixmap::fromImage(imageForConv(convUid)));
if (convUid != LRCInstance::getCurrentConvUid()) {
selectConversation(conversation);
}
convModel->placeCall(convUid);
});
// audio call
auto audioCallAction = new QAction(tr("Start audio call"), this);
menu.addAction(audioCallAction);
connect(audioCallAction, &QAction::triggered,
[this, convUid, conversation, convModel]() {
convModel->placeAudioOnlyCall(convUid);
if (!ui->messageView->isVisible())
showChatView(LRCInstance::getCurrAccId(), conversation);
ui->callingPhoto->setPixmap(QPixmap::fromImage(imageForConv(convUid)));
if (convUid != LRCInstance::getCurrentConvUid()) {
selectConversation(conversation);
}
convModel->placeAudioOnlyCall(convUid);
});
// clear conversation
auto clearConversationAction = new QAction(tr("Clear conversation"), this);
......
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