mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-03-11 08:48:14 +00:00
Fix build in Xcode.
This commit is contained in:
parent
4c8187f623
commit
97356032ac
@ -536,7 +536,8 @@ void InnerWidget::paintEvent(QPaintEvent *e) {
|
||||
const auto reorderingPinned = (_aboveIndex >= 0)
|
||||
&& !_pinnedRows.empty();
|
||||
const auto reorderingIndex = promoted + _aboveIndex;
|
||||
const auto reorderingRow = (reorderingIndex < list.size())
|
||||
const auto reorderingRow = (reorderingIndex >= 0
|
||||
&& reorderingIndex < list.size())
|
||||
? (list.cbegin() + reorderingIndex)->get()
|
||||
: nullptr;
|
||||
if (reorderingRow) {
|
||||
|
@ -198,6 +198,9 @@ private:
|
||||
};
|
||||
|
||||
struct FilterResult {
|
||||
FilterResult(not_null<Row*> row) : row(row) {
|
||||
}
|
||||
|
||||
not_null<Row*> row;
|
||||
int top = 0;
|
||||
|
||||
|
@ -164,7 +164,7 @@ Row *List::rowAtY(int y) const {
|
||||
return (top <= y && bottom > y) ? row.get() : nullptr;
|
||||
}
|
||||
|
||||
List::const_iterator List::findByY(int y) const {
|
||||
List::iterator List::findByY(int y) const {
|
||||
return ranges::lower_bound(_rows, y, ranges::less(), [](const Row *row) {
|
||||
return row->top() + row->height();
|
||||
});
|
||||
|
@ -64,8 +64,7 @@ public:
|
||||
return cfind(value);
|
||||
}
|
||||
[[nodiscard]] iterator find(Row *value) { return cfind(value); }
|
||||
[[nodiscard]] const_iterator findByY(int y) const;
|
||||
[[nodiscard]] iterator findByY(int y) { return findByY(y); }
|
||||
[[nodiscard]] iterator findByY(int y) const;
|
||||
|
||||
private:
|
||||
void adjustByName(not_null<Row*> row);
|
||||
|
Loading…
Reference in New Issue
Block a user