mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Fix build with Xcode.
This commit is contained in:
parent
88751896af
commit
c94da177d7
11 changed files with 14 additions and 14 deletions
|
@ -149,7 +149,7 @@ WorkingIntervals ReplaceDayIntervals(
|
||||||
end(result.list),
|
end(result.list),
|
||||||
begin(replacement.list),
|
begin(replacement.list),
|
||||||
end(replacement.list));
|
end(replacement.list));
|
||||||
for (auto &interval : ranges::subrange(first, end(result.list))) {
|
for (auto &interval : ranges::make_subrange(first, end(result.list))) {
|
||||||
interval = interval.shifted(dayIndex * kDay);
|
interval = interval.shifted(dayIndex * kDay);
|
||||||
}
|
}
|
||||||
return result.normalized();
|
return result.normalized();
|
||||||
|
|
|
@ -55,7 +55,7 @@ private:
|
||||||
|
|
||||||
[[nodiscard]] TimeId StartTimeMin() {
|
[[nodiscard]] TimeId StartTimeMin() {
|
||||||
// Telegram was launched in August 2013 :)
|
// Telegram was launched in August 2013 :)
|
||||||
return base::unixtime::serialize(QDateTime(QDate(2013, 8, 1)));
|
return base::unixtime::serialize(QDateTime(QDate(2013, 8, 1), QTime(0, 0)));
|
||||||
}
|
}
|
||||||
|
|
||||||
[[nodiscard]] TimeId EndTimeMin() {
|
[[nodiscard]] TimeId EndTimeMin() {
|
||||||
|
@ -260,7 +260,7 @@ void AwayMessage::setupContent(
|
||||||
_enabled.value() | rpl::filter(_1) | rpl::start_with_next([=] {
|
_enabled.value() | rpl::filter(_1) | rpl::start_with_next([=] {
|
||||||
if (!_canHave.current()) {
|
if (!_canHave.current()) {
|
||||||
controller->showToast({
|
controller->showToast({
|
||||||
.text = tr::lng_away_limit_reached(tr::now),
|
.text = { tr::lng_away_limit_reached(tr::now) },
|
||||||
.adaptive = true,
|
.adaptive = true,
|
||||||
});
|
});
|
||||||
_deactivateOnAttempt.fire({});
|
_deactivateOnAttempt.fire({});
|
||||||
|
|
|
@ -47,7 +47,7 @@ public:
|
||||||
|
|
||||||
[[nodiscard]] rpl::producer<QString> title() override;
|
[[nodiscard]] rpl::producer<QString> title() override;
|
||||||
|
|
||||||
const Ui::RoundRect *bottomSkipRounding() const {
|
const Ui::RoundRect *bottomSkipRounding() const override {
|
||||||
return &_bottomSkipRounding;
|
return &_bottomSkipRounding;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -59,7 +59,7 @@ private:
|
||||||
|
|
||||||
rpl::variable<Data::BusinessRecipients> _recipients;
|
rpl::variable<Data::BusinessRecipients> _recipients;
|
||||||
rpl::variable<QString> _usernameValue;
|
rpl::variable<QString> _usernameValue;
|
||||||
rpl::variable<BotState> _botValue = nullptr;
|
rpl::variable<BotState> _botValue;
|
||||||
rpl::variable<bool> _repliesAllowed = true;
|
rpl::variable<bool> _repliesAllowed = true;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
|
@ -44,7 +44,7 @@ public:
|
||||||
|
|
||||||
[[nodiscard]] rpl::producer<QString> title() override;
|
[[nodiscard]] rpl::producer<QString> title() override;
|
||||||
|
|
||||||
const Ui::RoundRect *bottomSkipRounding() const {
|
const Ui::RoundRect *bottomSkipRounding() const override {
|
||||||
return &_bottomSkipRounding;
|
return &_bottomSkipRounding;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -157,7 +157,7 @@ void Greeting::setupContent(
|
||||||
_enabled.value() | rpl::filter(_1) | rpl::start_with_next([=] {
|
_enabled.value() | rpl::filter(_1) | rpl::start_with_next([=] {
|
||||||
if (!_canHave.current()) {
|
if (!_canHave.current()) {
|
||||||
controller->showToast({
|
controller->showToast({
|
||||||
.text = tr::lng_greeting_limit_reached(tr::now),
|
.text = { tr::lng_greeting_limit_reached(tr::now) },
|
||||||
.adaptive = true,
|
.adaptive = true,
|
||||||
});
|
});
|
||||||
_deactivateOnAttempt.fire({});
|
_deactivateOnAttempt.fire({});
|
||||||
|
|
|
@ -32,7 +32,7 @@ public:
|
||||||
|
|
||||||
[[nodiscard]] rpl::producer<QString> title() override;
|
[[nodiscard]] rpl::producer<QString> title() override;
|
||||||
|
|
||||||
const Ui::RoundRect *bottomSkipRounding() const {
|
const Ui::RoundRect *bottomSkipRounding() const override {
|
||||||
return mapSupported() ? nullptr : &_bottomSkipRounding;
|
return mapSupported() ? nullptr : &_bottomSkipRounding;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -462,7 +462,7 @@ void AddWeekButton(
|
||||||
[=] { toggleButton->update(); });
|
[=] { toggleButton->update(); });
|
||||||
|
|
||||||
auto status = data->value(
|
auto status = data->value(
|
||||||
) | rpl::map([=](const Data::WorkingHours &data) {
|
) | rpl::map([=](const Data::WorkingHours &data) -> rpl::producer<QString> {
|
||||||
using namespace Data;
|
using namespace Data;
|
||||||
|
|
||||||
const auto intervals = ExtractDayIntervals(data.intervals, index);
|
const auto intervals = ExtractDayIntervals(data.intervals, index);
|
||||||
|
|
|
@ -60,7 +60,7 @@ public:
|
||||||
|
|
||||||
[[nodiscard]] rpl::producer<QString> title() override;
|
[[nodiscard]] rpl::producer<QString> title() override;
|
||||||
|
|
||||||
[[nodiscard]] void fillTopBarMenu(
|
void fillTopBarMenu(
|
||||||
const Ui::Menu::MenuCallback &addAction) override;
|
const Ui::Menu::MenuCallback &addAction) override;
|
||||||
|
|
||||||
void setupContent();
|
void setupContent();
|
||||||
|
|
|
@ -44,7 +44,7 @@ public:
|
||||||
|
|
||||||
[[nodiscard]] rpl::producer<QString> title() override;
|
[[nodiscard]] rpl::producer<QString> title() override;
|
||||||
|
|
||||||
[[nodiscard]] void fillTopBarMenu(
|
void fillTopBarMenu(
|
||||||
const Ui::Menu::MenuCallback &addAction) override;
|
const Ui::Menu::MenuCallback &addAction) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
|
@ -102,7 +102,7 @@ public:
|
||||||
}
|
}
|
||||||
virtual void selectionAction(Info::SelectionAction action) {
|
virtual void selectionAction(Info::SelectionAction action) {
|
||||||
}
|
}
|
||||||
[[nodiscard]] virtual void fillTopBarMenu(
|
virtual void fillTopBarMenu(
|
||||||
const Ui::Menu::MenuCallback &addAction) {
|
const Ui::Menu::MenuCallback &addAction) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -79,7 +79,7 @@ public:
|
||||||
[[nodiscard]] rpl::producer<Type> sectionShowOther() final override {
|
[[nodiscard]] rpl::producer<Type> sectionShowOther() final override {
|
||||||
return _showOtherRequests.events();
|
return _showOtherRequests.events();
|
||||||
}
|
}
|
||||||
[[nodiscard]] void showOther(Type type) {
|
void showOther(Type type) {
|
||||||
_showOtherRequests.fire_copy(type);
|
_showOtherRequests.fire_copy(type);
|
||||||
}
|
}
|
||||||
[[nodiscard]] Fn<void(Type)> showOtherMethod() {
|
[[nodiscard]] Fn<void(Type)> showOtherMethod() {
|
||||||
|
|
|
@ -38,7 +38,7 @@ public:
|
||||||
|
|
||||||
[[nodiscard]] rpl::producer<QString> title() override;
|
[[nodiscard]] rpl::producer<QString> title() override;
|
||||||
|
|
||||||
[[nodiscard]] void fillTopBarMenu(
|
void fillTopBarMenu(
|
||||||
const Ui::Menu::MenuCallback &addAction) override;
|
const Ui::Menu::MenuCallback &addAction) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
Loading…
Add table
Reference in a new issue