1
0
Fork 0
mirror of https://git.jami.net/savoirfairelinux/jami-client-qt.git synced 2025-09-10 03:53:23 +02:00

conversationmenu: fix incorrect end call state

Change-Id: I6420f6233bbf9a92f7821735c02fcc29e478d111
GitLab: #942
This commit is contained in:
Sébastien Blin 2023-03-03 14:21:58 -05:00
parent 98569e2c70
commit 0679c0e04c
4 changed files with 6 additions and 10 deletions

View file

@ -231,7 +231,6 @@ Item {
property string isCallingYou: qsTr("is calling you") property string isCallingYou: qsTr("is calling you")
property string mute: qsTr("Mute") property string mute: qsTr("Mute")
property string unmute: qsTr("Unmute") property string unmute: qsTr("Unmute")
property string hangup: qsTr("End call")
property string pauseCall: qsTr("Pause call") property string pauseCall: qsTr("Pause call")
property string resumeCall: qsTr("Resume call") property string resumeCall: qsTr("Resume call")
property string muteCamera: qsTr("Mute camera") property string muteCamera: qsTr("Mute camera")

View file

@ -276,7 +276,7 @@ Control {
onTriggered: CallAdapter.hangUpThisCall() onTriggered: CallAdapter.hangUpThisCall()
icon.source: JamiResources.ic_call_end_white_24dp_svg icon.source: JamiResources.ic_call_end_white_24dp_svg
icon.color: "white" icon.color: "white"
text: JamiStrings.hangup text: JamiStrings.endCall
property bool hasBg: true property bool hasBg: true
}, },
Action { Action {

View file

@ -127,6 +127,8 @@ JamiListView {
(model.dataForRow(index, ConversationList.ContactType) !== (model.dataForRow(index, ConversationList.ContactType) !==
Profile.Type.TEMPORARY) && Profile.Type.TEMPORARY) &&
CurrentAccount.type !== Profile.Type.SIP CurrentAccount.type !== Profile.Type.SIP
hasCall = UtilsAdapter.getCallId(responsibleAccountId,
responsibleConvUid) !== ""
// For UserProfile dialog. // For UserProfile dialog.
if (isCoreDialog) { if (isCoreDialog) {

View file

@ -36,13 +36,8 @@ ContextMenuAutoLoader {
property var isCoreDialog: undefined property var isCoreDialog: undefined
property var mode: undefined property var mode: undefined
property int contactType: Profile.Type.INVALID property int contactType: Profile.Type.INVALID
property bool hasCall: { property bool hasCall: false
if (responsibleAccountId && responsibleConvUid) property bool readOnly: false
return UtilsAdapter.getCallId(responsibleAccountId,
responsibleConvUid) !== ""
return false
}
property bool readOnly
// For UserProfile dialog. // For UserProfile dialog.
property string aliasText property string aliasText
@ -117,7 +112,7 @@ ContextMenuAutoLoader {
id: hangup id: hangup
canTrigger: hasCall canTrigger: hasCall
itemName: JamiStrings.hangup itemName: JamiStrings.endCall
iconSource: JamiResources.ic_call_end_white_24dp_svg iconSource: JamiResources.ic_call_end_white_24dp_svg
addMenuSeparatorAfter: contactType !== Profile.Type.SIP addMenuSeparatorAfter: contactType !== Profile.Type.SIP
&& (contactType === Profile.Type.PENDING && (contactType === Profile.Type.PENDING