mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-16 06:07:06 +02:00
Fixed build with Xcode.
This commit is contained in:
parent
8eb24f620d
commit
5e29f382cd
4 changed files with 5 additions and 5 deletions
|
@ -801,7 +801,7 @@ void InnerWidget::paintEvent(QPaintEvent *e) {
|
|||
p.fillRect(dialogsClip, currentBg());
|
||||
}
|
||||
} else if (_state == WidgetState::Filtered) {
|
||||
auto top = 0;
|
||||
[[maybe_unused]] auto top = 0;
|
||||
if (!_hashtagResults.empty()) {
|
||||
auto from = floorclamp(r.y(), st::mentionHeight, 0, _hashtagResults.size());
|
||||
auto to = ceilclamp(r.y() + r.height(), st::mentionHeight, 0, _hashtagResults.size());
|
||||
|
|
|
@ -8,6 +8,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
|||
#pragma once
|
||||
|
||||
#include "base/qt/qt_compare.h"
|
||||
#include "data/data_message_reaction_id.h"
|
||||
|
||||
class History;
|
||||
class PeerData;
|
||||
|
|
|
@ -56,9 +56,9 @@ FixedHashtagSearchQuery FixHashtagSearchQuery(
|
|||
const QString &query,
|
||||
int cursorPosition) {
|
||||
const auto trimmed = query.trimmed();
|
||||
const auto hash = trimmed.isEmpty()
|
||||
const auto hash = int(trimmed.isEmpty()
|
||||
? query.size()
|
||||
: query.indexOf(trimmed);
|
||||
: query.indexOf(trimmed));
|
||||
const auto start = std::min(cursorPosition, hash);
|
||||
auto result = query.mid(0, start);
|
||||
for (const auto &ch : query.mid(start)) {
|
||||
|
@ -198,4 +198,4 @@ void ChatSearchTabs::paintEvent(QPaintEvent *e) {
|
|||
QPainter(this).fillRect(e->rect(), st::dialogsBg);
|
||||
}
|
||||
|
||||
} // namespace Dialogs
|
||||
} // namespace Dialogs
|
||||
|
|
|
@ -733,7 +733,6 @@ void MainWidget::hideSingleUseKeyboard(FullMsgId replyToId) {
|
|||
void MainWidget::searchMessages(const QString &query, Dialogs::Key inChat) {
|
||||
auto tags = Data::SearchTagsFromQuery(query);
|
||||
if (controller()->isPrimary()) {
|
||||
using Tab = Dialogs::ChatSearchTab;
|
||||
auto state = Dialogs::SearchState{
|
||||
.inChat = ((tags.empty() || inChat.sublist())
|
||||
? inChat
|
||||
|
|
Loading…
Add table
Reference in a new issue