mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2026-07-25 06:54:43 +00:00
40 lines
1.0 KiB
C++
40 lines
1.0 KiB
C++
/*
|
|
This file is part of Telegram Desktop,
|
|
the official desktop application for the Telegram messaging service.
|
|
|
|
For license and copyright information please follow this link:
|
|
https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
|
*/
|
|
#pragma once
|
|
|
|
#include "api/api_common.h"
|
|
#include "base/object_ptr.h"
|
|
#include "ui/text/text_entity.h"
|
|
|
|
namespace Main {
|
|
class Session;
|
|
} // namespace Main
|
|
|
|
namespace Ui {
|
|
class ChatStyle;
|
|
class GenericBox;
|
|
class RpWidget;
|
|
class Show;
|
|
} // namespace Ui
|
|
|
|
namespace HistoryView::Controls {
|
|
|
|
struct ComposeAiBoxArgs {
|
|
not_null<Main::Session*> session;
|
|
TextWithEntities text;
|
|
std::shared_ptr<Ui::ChatStyle> chatStyle;
|
|
Fn<void(TextWithEntities)> apply;
|
|
Fn<void(TextWithEntities, Api::SendOptions, Fn<void()>)> send;
|
|
Fn<void(not_null<Ui::RpWidget*>, Fn<void(Api::SendOptions)>)> setupMenu;
|
|
};
|
|
|
|
void ComposeAiBox(not_null<Ui::GenericBox*> box, ComposeAiBoxArgs &&args);
|
|
void ShowComposeAiBox(std::shared_ptr<Ui::Show> show, ComposeAiBoxArgs &&args);
|
|
|
|
} // namespace HistoryView::Controls
|