Forbid to go in fullscreen if conference is not ready.

Fix crash on call termination (SDK fix)
This commit is contained in:
Julien Wadel 2023-10-19 14:57:59 +02:00
parent 7404ccf64a
commit 0a4405e9c8
4 changed files with 13 additions and 4 deletions

View file

@ -160,8 +160,9 @@ void CoreHandlers::onCallStatsUpdated (
const shared_ptr<linphone::Call> &call,
const shared_ptr<const linphone::CallStats> &stats
) {
if(call->dataExists("call-model"))
if(call && call->dataExists("call-model")) {
call->getData<CallModel>("call-model").updateStats(stats);
}
}
void CoreHandlers::onCallCreated(const shared_ptr<linphone::Core> &,

View file

@ -290,7 +290,7 @@ Rectangle {
isCustom: true
backgroundRadius: width/2
colorSet: IncallStyle.buttons.fullscreen
visible: mainItem.callModel.videoEnabled
visible: mainItem.callModel.videoEnabled && mainItem.isReady
onClicked: {
console.info("[QML] User request fullscreen")
Logic.showFullscreen(window, mainItem, 'IncallFullscreen.qml', title.mapToGlobal(0,0))

View file

@ -25,11 +25,19 @@ Window {
// ---------------------------------------------------------------------------
property alias callModel: conference.callModel
property ConferenceModel conferenceModel: callModel && callModel.conferenceModel
property var caller
property bool hideButtons: !hideButtonsTimer.realRunning
property bool cameraIsReady : false
property bool previewIsReady : false
property bool isReady : window.callModel && window.callModel.status != CallModel.CallStatusIdle
&& (!window.callModel.isConference
|| (window.conferenceModel && window.conferenceModel.isReady)
) && conferenceLayout.item && conferenceLayout.status == Loader.Ready
onIsReadyChanged: if(!isRead) {
console.info('[QML] Call becomes not ready : exit fullscreen')
window.exit()
}
// ---------------------------------------------------------------------------
function exit (cb) {

@ -1 +1 @@
Subproject commit c4fbe81daaa62875021ab44a85b48966619e0943
Subproject commit a3943b61b841fd7226dd495cd28ff0ecbbafc2a2