2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-09-05 00:55:12 +00:00

Use 48 bit [User/Chat/Channel]Id, 56 bit PeerId.

This commit is contained in:
John Preston
2021-04-02 01:04:10 +04:00
parent 61d0cc38b0
commit 1342077dcb
83 changed files with 904 additions and 475 deletions

View File

@@ -729,7 +729,7 @@ bool InnerWidget::isSearchResultActive(
const auto peer = item->history()->peer;
return (item->fullId() == entry.fullId)
|| (peer->migrateTo()
&& (peer->migrateTo()->bareId() == entry.fullId.channel)
&& (peerToChannel(peer->migrateTo()->id) == entry.fullId.channel)
&& (item->id == -entry.fullId.msg))
|| (uniqueSearchResults() && peer == entry.key.peer());
}
@@ -2080,7 +2080,8 @@ bool InnerWidget::searchReceived(
_lastSearchPeer = peer;
}
} else {
LOG(("API Error: a search results with not loaded peer %1").arg(peerId));
LOG(("API Error: a search results with not loaded peer %1"
).arg(peerId.value));
}
if (isMigratedSearch) {
_lastSearchMigratedId = msgId;
@@ -2142,7 +2143,7 @@ void InnerWidget::peerSearchReceived(
} else {
LOG(("API Error: "
"user %1 was not loaded in InnerWidget::peopleReceived()"
).arg(peer->id));
).arg(peer->id.value));
}
}
for (const auto &mtpPeer : result) {
@@ -2157,7 +2158,7 @@ void InnerWidget::peerSearchReceived(
} else {
LOG(("API Error: "
"user %1 was not loaded in InnerWidget::peopleReceived()"
).arg(peer->id));
).arg(peer->id.value));
}
}
refresh();