Fix addresses list from phone. Fix crash with MSQOGL and destroiying QML object that is still link with other objects.

This commit is contained in:
Julien Wadel 2025-07-29 17:19:34 +02:00
parent 9cb5758233
commit 40df729a88
3 changed files with 11 additions and 4 deletions

View file

@ -445,8 +445,9 @@ QList<QVariant> FriendCore::getAllAddresses() const {
auto phoneNumbers = mPhoneNumberList;
while (addressIt != mAddressList.end()) {
auto username = Utils::getUsername(addressIt->toMap()["address"].toString());
std::remove_if(phoneNumbers.begin(), phoneNumbers.end(),
[username](const QVariant &data) { return data.toMap()["address"].toString() == username; });
phoneNumbers.erase(std::remove_if(phoneNumbers.begin(), phoneNumbers.end(),
[username](const QVariant &data) { return data.toMap()["address"].toString() == username; })
, phoneNumbers.end());
++addressIt;
}
addresses << phoneNumbers;

View file

@ -99,10 +99,16 @@ Item {
x: mainItem.width / 2 - width / 2
y: contentItem.height / 2
property var currentCall: callsModel.currentCall ? callsModel.currentCall : null
property var conference: currentCall ? currentCall.core.conference : null
property string remoteName: currentCall ? currentCall.core.remoteName : ""
property string subject: conference ? conference.core.subject : ''
contentItem: MediumButton {
style: ButtonStyle.toast
text: currentCallNotif.currentCall ? currentCallNotif.currentCall.core.conference ? ("Réunion en cours : ") + currentCallNotif.currentCall.core.conference.core.subject : (("Appel en cours : ") + currentCallNotif.remoteName) : "appel en cours"
text: currentCallNotif.currentCall
? currentCallNotif.conference
? ("Réunion en cours : ") + currentCallNotif.subject
: (("Appel en cours : ") + currentCallNotif.remoteName)
: "appel en cours"
onClicked: {
var callsWindow = UtilsCpp.getCallsWindow(
currentCallNotif.currentCall)

@ -1 +1 @@
Subproject commit 2f9c2d231386233c1d93a6120a109e5fdd5eb50a
Subproject commit 8d4192c62c6b119cd8b8120b3407bfe8d7cce96c