mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 06:35:14 +00:00
fixed adding contacts from shared contacts
This commit is contained in:
@@ -70,6 +70,9 @@ namespace {
|
||||
typedef QMap<HistoryItem*, QMap<HistoryReply*, bool> > RepliesTo;
|
||||
RepliesTo repliesTo;
|
||||
|
||||
typedef QMap<int32, QString> SharedContactPhones;
|
||||
SharedContactPhones sharedContactPhones;
|
||||
|
||||
Histories histories;
|
||||
|
||||
typedef QHash<MsgId, HistoryItem*> MsgsData;
|
||||
@@ -1725,6 +1728,7 @@ namespace App {
|
||||
::audioItems.clear();
|
||||
::documentItems.clear();
|
||||
::webPageItems.clear();
|
||||
::sharedContactPhones.clear();
|
||||
::repliesTo.clear();
|
||||
lastPhotos.clear();
|
||||
lastPhotosMap.clear();
|
||||
@@ -2117,6 +2121,14 @@ namespace App {
|
||||
return ::webPageItems;
|
||||
}
|
||||
|
||||
void regSharedContactPhone(int32 userId, const QString &phone) {
|
||||
::sharedContactPhones[userId] = phone;
|
||||
}
|
||||
|
||||
QString phoneFromSharedContact(int32 userId) {
|
||||
return ::sharedContactPhones.value(userId);
|
||||
}
|
||||
|
||||
void regMuted(PeerData *peer, int32 changeIn) {
|
||||
::mutedPeers.insert(peer, true);
|
||||
if (App::main()) App::main()->updateMutedIn(changeIn);
|
||||
|
Reference in New Issue
Block a user