diff --git a/linphone-desktop/ui/views/App/Calls/CallsWindow.qml b/linphone-desktop/ui/views/App/Calls/CallsWindow.qml index c5d53c0b4..0d434fd9e 100644 --- a/linphone-desktop/ui/views/App/Calls/CallsWindow.qml +++ b/linphone-desktop/ui/views/App/Calls/CallsWindow.qml @@ -17,7 +17,15 @@ Window { // --------------------------------------------------------------------------- - property var call: calls.selectedCall + // `{}` is a workaround to avoid `TypeError: Cannot read property...`. + property var call: calls.selectedCall || ({ + isOutgoing: true, + sipAddress: '', + recording: false, + updating: true, + videoEnabled: false + }) + readonly property bool chatIsOpened: !rightPaned.isClosed() property string sipAddress: call ? call.sipAddress : '' diff --git a/linphone-desktop/ui/views/App/Calls/Incall.qml b/linphone-desktop/ui/views/App/Calls/Incall.qml index cb392a75e..07b9c07bc 100644 --- a/linphone-desktop/ui/views/App/Calls/Incall.qml +++ b/linphone-desktop/ui/views/App/Calls/Incall.qml @@ -123,22 +123,27 @@ Rectangle { ActionButton { icon: 'screenshot' - visible: call.videoEnabled + visible: incall.call.videoEnabled - onClicked: call.takeSnapshot() + onClicked: incall.call.takeSnapshot() } ActionSwitch { - enabled: call.recording + enabled: incall.call.recording icon: 'record' useStates: false - onClicked: !enabled ? call.startRecording() : call.stopRecording() + onClicked: { + var call = incall.call + return !enabled + ? call.startRecording() + : call.stopRecording() + } } ActionButton { icon: 'fullscreen' - visible: call.videoEnabled + visible: incall.call.videoEnabled onClicked: Logic.showFullscreen() } @@ -179,7 +184,7 @@ Rectangle { Avatar { backgroundColor: CallStyle.container.avatar.backgroundColor - foregroundColor: call.status === CallModel.CallStatusPaused + foregroundColor: incall.call.status === CallModel.CallStatusPaused ? CallStyle.container.pause.color : 'transparent' image: _sipAddressObserver.contact && _sipAddressObserver.contact.vcard.avatar @@ -200,7 +205,7 @@ Rectangle { text: '▐ ▌' textFormat: Text.RichText - visible: call.status === CallModel.CallStatusPaused + visible: incall.call.status === CallModel.CallStatusPaused } } } @@ -210,7 +215,7 @@ Rectangle { anchors.centerIn: parent - active: call.videoEnabled && !_fullscreen + active: incall.call.videoEnabled && !_fullscreen sourceComponent: camera Component { @@ -259,7 +264,7 @@ Rectangle { repeat: true running: micro.enabled - onTriggered: parent.value = call.microVu + onTriggered: parent.value = incall.call.microVu } enabled: micro.enabled @@ -272,7 +277,7 @@ Rectangle { icon: 'micro' iconSize: CallStyle.actionArea.iconSize - onClicked: call.microMuted = enabled + onClicked: incall.call.microMuted = enabled } } @@ -285,7 +290,7 @@ Rectangle { repeat: true running: speaker.enabled - onTriggered: parent.value = call.speakerVu + onTriggered: parent.value = incall.call.speakerVu } enabled: speaker.enabled @@ -303,12 +308,12 @@ Rectangle { } ActionSwitch { - enabled: call.videoEnabled + enabled: incall.call.videoEnabled icon: 'camera' iconSize: CallStyle.actionArea.iconSize - updating: call.updating + updating: incall.call.updating - onClicked: call.videoEnabled = !enabled + onClicked: incall.call.videoEnabled = !enabled TooltipArea { text: qsTr('pendingRequestLabel') @@ -335,7 +340,7 @@ Rectangle { height: CallStyle.actionArea.userVideo.height width: CallStyle.actionArea.userVideo.width - active: incall.width >= CallStyle.actionArea.lowWidth && call.videoEnabled && !_fullscreen + active: incall.width >= CallStyle.actionArea.lowWidth && incall.call.videoEnabled && !_fullscreen sourceComponent: cameraPreview Component { @@ -360,9 +365,9 @@ Rectangle { ActionSwitch { enabled: !call.pausedByUser icon: 'pause' - updating: call.updating + updating: incall.call.updating - onClicked: call.pausedByUser = enabled + onClicked: incall.call.pausedByUser = enabled TooltipArea { text: qsTr('pendingRequestLabel') @@ -373,7 +378,7 @@ Rectangle { ActionButton { icon: 'hangup' - onClicked: call.terminate() + onClicked: incall.call.terminate() } ActionButton { diff --git a/linphone-desktop/ui/views/App/Main/MainWindow.qml b/linphone-desktop/ui/views/App/Main/MainWindow.qml index 66d4526a5..89f9fc021 100644 --- a/linphone-desktop/ui/views/App/Main/MainWindow.qml +++ b/linphone-desktop/ui/views/App/Main/MainWindow.qml @@ -126,7 +126,7 @@ ApplicationWindow { } Column { - width: MainWindowStyle.autoAnswerStatus.width + Layout.preferredWidth: MainWindowStyle.autoAnswerStatus.width Icon { icon: SettingsModel.autoAnswerStatus @@ -176,6 +176,7 @@ ApplicationWindow { ActionButton { icon: 'new_conference' + iconSize: MainWindowStyle.newConferenceSize onClicked: Logic.openConferenceManager() } diff --git a/linphone-desktop/ui/views/App/Styles/Main/MainWindowStyle.qml b/linphone-desktop/ui/views/App/Styles/Main/MainWindowStyle.qml index 3e1e1fc22..15d9cb2bd 100644 --- a/linphone-desktop/ui/views/App/Styles/Main/MainWindowStyle.qml +++ b/linphone-desktop/ui/views/App/Styles/Main/MainWindowStyle.qml @@ -8,6 +8,7 @@ import Linphone.Styles 1.0 QtObject { property int menuBurgerSize: 16 + property int newConferenceSize: 40 property int minimumHeight: 610 property int minimumWidth: 950 property int width: 950 diff --git a/submodules/linphone b/submodules/linphone index 38638e543..974daa4bb 160000 --- a/submodules/linphone +++ b/submodules/linphone @@ -1 +1 @@ -Subproject commit 38638e543d1641ff637f32c4424f61684c861cea +Subproject commit 974daa4bb5b8011cf90b1adfb99cf09e9f349cb9