api_attached_stickers.h 950 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /*
  2. This file is part of Telegram Desktop,
  3. the official desktop application for the Telegram messaging service.
  4. For license and copyright information please follow this link:
  5. https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
  6. */
  7. #pragma once
  8. #include "mtproto/sender.h"
  9. class ApiWrap;
  10. class DocumentData;
  11. class PhotoData;
  12. namespace Window {
  13. class SessionController;
  14. } // namespace Window
  15. namespace Api {
  16. class AttachedStickers final {
  17. public:
  18. explicit AttachedStickers(not_null<ApiWrap*> api);
  19. void requestAttachedStickerSets(
  20. not_null<Window::SessionController*> controller,
  21. not_null<PhotoData*> photo);
  22. void requestAttachedStickerSets(
  23. not_null<Window::SessionController*> controller,
  24. not_null<DocumentData*> document);
  25. private:
  26. void request(
  27. not_null<Window::SessionController*> controller,
  28. MTPmessages_GetAttachedStickers &&mtpRequest);
  29. MTP::Sender _api;
  30. mtpRequestId _requestId = 0;
  31. };
  32. } // namespace Api