auto select current conference when model reset (conf scheduler send Ready signal then conferenceInfoReceived makes conf info list update)

fix crash
This commit is contained in:
Gaelle Braud 2025-12-12 15:27:18 +01:00
parent 2320cc7444
commit c31def74fe
5 changed files with 15 additions and 12 deletions

View file

@ -63,8 +63,8 @@ void ParticipantDeviceProxy::setCurrentCall(CallGui *call) {
mCurrentCall = call;
if (mCurrentCall) callCore = mCurrentCall->getCore();
if (callCore) {
connect(callCore, &CallCore::conferenceChanged, mParticipants.get(), [this]() {
auto conference = mCurrentCall->getCore()->getConferenceCore();
connect(callCore, &CallCore::conferenceChanged, mParticipants.get(), [this, callCore]() {
auto conference = callCore->getConferenceCore();
lDebug() << log().arg("Set conference") << this << " => " << conference;
mParticipants->setConferenceModel(conference ? conference->getModel() : nullptr);
});

View file

@ -4625,19 +4625,19 @@ Ablauf: %1</translation>
<context>
<name>MeetingListView</name>
<message>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="274"/>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="277"/>
<source>meeting_info_cancelled</source>
<extracomment>&quot;Réunion annulée&quot;</extracomment>
<translation>Besprechung abgesagt</translation>
</message>
<message>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="298"/>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="301"/>
<source>meetings_list_no_meeting_for_today</source>
<extracomment>&quot;Aucune réunion aujourd&apos;hui&quot;</extracomment>
<translation>Heute keine Besprechungen</translation>
</message>
<message>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="332"/>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="335"/>
<source>meeting_info_delete</source>
<extracomment>&quot;Supprimer la réunion&quot;</extracomment>
<translation>Besprechung löschen</translation>

View file

@ -4523,19 +4523,19 @@ Expiration : %1</translation>
<context>
<name>MeetingListView</name>
<message>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="274"/>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="277"/>
<source>meeting_info_cancelled</source>
<extracomment>&quot;Réunion annulée&quot;</extracomment>
<translation>Meeting canceled</translation>
</message>
<message>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="298"/>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="301"/>
<source>meetings_list_no_meeting_for_today</source>
<extracomment>&quot;Aucune réunion aujourd&apos;hui&quot;</extracomment>
<translation>No meeting for today</translation>
</message>
<message>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="332"/>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="335"/>
<source>meeting_info_delete</source>
<extracomment>&quot;Supprimer la réunion&quot;</extracomment>
<translation>Delete meeting</translation>

View file

@ -4523,19 +4523,19 @@ Expiration : %1</translation>
<context>
<name>MeetingListView</name>
<message>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="274"/>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="277"/>
<source>meeting_info_cancelled</source>
<extracomment>&quot;Réunion annulée&quot;</extracomment>
<translation>Réunion annulée</translation>
</message>
<message>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="298"/>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="301"/>
<source>meetings_list_no_meeting_for_today</source>
<extracomment>&quot;Aucune réunion aujourd&apos;hui&quot;</extracomment>
<translation>Aucune réunion aujourd&apos;hui</translation>
</message>
<message>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="332"/>
<location filename="../../view/Control/Display/Meeting/MeetingListView.qml" line="335"/>
<source>meeting_info_delete</source>
<extracomment>&quot;Supprimer la réunion&quot;</extracomment>
<translation>Supprimer la réunion</translation>

View file

@ -16,6 +16,7 @@ ListView {
property bool hoverEnabled: true
property var delegateButtons
property ConferenceInfoGui selectedConference
property ConferenceInfoGui confToBeSelected: null
property bool _moveToIndex: false
property bool loading: false
property real busyIndicatorSize: Utils.getSizeWithScreenRatio(60)
@ -102,11 +103,13 @@ ListView {
initialDisplayItems: Math.max(20, Math.round(2 * mainItem.height / Utils.getSizeWithScreenRatio(63)))
displayItemsStep: initialDisplayItems/2
onModelAboutToBeReset: {
mainItem.confToBeSelected = mainItem.selectedConference
mainItem.loading = true
}
onModelReset: {
mainItem.loading = false
selectData(getCurrentDateConfInfo())
if (mainItem.confToBeSelected) selectData(mainItem.confToBeSelected)
else selectData(getCurrentDateConfInfo())
}
function selectData(confInfoGui){
mainItem.currentIndex = loadUntil(confInfoGui)