mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-04-17 20:08:28 +00:00
Defer ChatProxy::invalidate() to avoid accessibility crash on macOS (QTBUG-95764)
This commit is contained in:
parent
2123c573fa
commit
74b91b6e40
1 changed files with 4 additions and 1 deletions
|
|
@ -23,6 +23,8 @@
|
||||||
#include "ChatList.hpp"
|
#include "ChatList.hpp"
|
||||||
#include "core/App.hpp"
|
#include "core/App.hpp"
|
||||||
|
|
||||||
|
#include <QTimer>
|
||||||
|
|
||||||
DEFINE_ABSTRACT_OBJECT(ChatProxy)
|
DEFINE_ABSTRACT_OBJECT(ChatProxy)
|
||||||
|
|
||||||
ChatProxy::ChatProxy(QObject *parent) {
|
ChatProxy::ChatProxy(QObject *parent) {
|
||||||
|
|
@ -50,7 +52,8 @@ void ChatProxy::setSourceModel(QAbstractItemModel *model) {
|
||||||
emit chatAdded(new ChatGui(chatCore));
|
emit chatAdded(new ChatGui(chatCore));
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
connect(newChatList, &ChatList::dataChanged, this, [this] { invalidate(); });
|
connect(newChatList, &ChatList::dataChanged, this,
|
||||||
|
[this] { QTimer::singleShot(0, this, [this] { invalidate(); }); });
|
||||||
newChatList->lUpdate();
|
newChatList->lUpdate();
|
||||||
}
|
}
|
||||||
QSortFilterProxyModel::setSourceModel(newChatList);
|
QSortFilterProxyModel::setSourceModel(newChatList);
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue