mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
fix: schedule stickers & set min for paid reactions
This commit is contained in:
parent
40e1f307a7
commit
84e7ff2637
2 changed files with 8 additions and 1 deletions
|
@ -67,6 +67,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
||||||
#include <QtSvg/QSvgRenderer>
|
#include <QtSvg/QSvgRenderer>
|
||||||
|
|
||||||
// AyuGram includes
|
// AyuGram includes
|
||||||
|
#include "ayu/ayu_settings.h"
|
||||||
#include "ayu/utils/telegram_helpers.h"
|
#include "ayu/utils/telegram_helpers.h"
|
||||||
#include "styles/style_ayu_styles.h"
|
#include "styles/style_ayu_styles.h"
|
||||||
#include "window/window_session_controller.h"
|
#include "window/window_session_controller.h"
|
||||||
|
@ -1415,6 +1416,12 @@ void StickerSetBox::Inner::chosen(
|
||||||
const auto animation = options.scheduled
|
const auto animation = options.scheduled
|
||||||
? Ui::MessageSendingAnimationFrom()
|
? Ui::MessageSendingAnimationFrom()
|
||||||
: messageSentAnimationInfo(index, sticker);
|
: messageSentAnimationInfo(index, sticker);
|
||||||
|
|
||||||
|
if (AyuSettings::isUseScheduledMessages() && !options.scheduled) {
|
||||||
|
auto current = base::unixtime::now();
|
||||||
|
options.scheduled = current + 12;
|
||||||
|
}
|
||||||
|
|
||||||
_show->processChosenSticker({
|
_show->processChosenSticker({
|
||||||
.document = sticker,
|
.document = sticker,
|
||||||
.options = options,
|
.options = options,
|
||||||
|
|
|
@ -38,7 +38,7 @@ namespace Payments {
|
||||||
namespace {
|
namespace {
|
||||||
|
|
||||||
constexpr auto kMaxPerReactionFallback = 2'500;
|
constexpr auto kMaxPerReactionFallback = 2'500;
|
||||||
constexpr auto kDefaultPerReaction = 50;
|
constexpr auto kDefaultPerReaction = 1;
|
||||||
|
|
||||||
void TryAddingPaidReaction(
|
void TryAddingPaidReaction(
|
||||||
not_null<Main::Session*> session,
|
not_null<Main::Session*> session,
|
||||||
|
|
Loading…
Add table
Reference in a new issue