2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 06:35:14 +00:00

Use vector instead of custom linked list.

This commit is contained in:
John Preston
2019-04-16 15:37:50 +04:00
parent 58d86af399
commit 2862070348
9 changed files with 129 additions and 268 deletions

View File

@@ -1070,7 +1070,7 @@ void AddSpecialBoxSearchController::addChatsContacts() {
auto result = (const Dialogs::List*)nullptr;
for (const auto &word : wordList) {
const auto found = list->filtered(word[0]);
if (found->isEmpty()) {
if (found->empty()) {
return nullptr;
}
if (!result || result->size() > found->size()) {

View File

@@ -952,7 +952,7 @@ void ShareBox::Inner::updateFilter(QString filter) {
if (!_chatsIndexed->isEmpty()) {
for (fi = fb; fi != fe; ++fi) {
auto found = _chatsIndexed->filtered(fi->at(0));
if (found->isEmpty()) {
if (found->empty()) {
toFilter = nullptr;
break;
}