feat: improve message shot

Add Show Spoiler
Fix photo not showing date in shot
Fix show date in media group
Hide inapplicable options

Co-authored-by: AlexeyZavar <sltkval1@gmail.com>
This commit is contained in:
People-11
2026-03-27 02:35:01 +10:30
committed by GitHub
parent a3d03a3c63
commit b185900b4f
20 changed files with 189 additions and 35 deletions
+4 -1
View File
@@ -167,6 +167,7 @@ public:
[[nodiscard]] bool showDate() const { return _showDate.current(); }
[[nodiscard]] bool showReactions() const { return _showReactions.current(); }
[[nodiscard]] bool showColorfulReplies() const { return _showColorfulReplies.current(); }
[[nodiscard]] bool revealSpoilers() const { return _revealSpoilers.current(); }
[[nodiscard]] int embeddedThemeType() const { return _embeddedThemeType.current(); }
[[nodiscard]] uint32 embeddedThemeAccentColor() const { return _embeddedThemeAccentColor.current(); }
[[nodiscard]] uint64 cloudThemeId() const { return _cloudThemeId.current(); }
@@ -179,6 +180,7 @@ public:
void setShowDate(bool val);
void setShowReactions(bool val);
void setShowColorfulReplies(bool val);
void setRevealSpoilers(bool val);
void setEmbeddedTheme(int type, uint32 accentColor = 0);
void setCloudTheme(uint64 accountId, uint64 id, uint64 accessHash, uint64 documentId, const QString &title);
@@ -195,7 +197,8 @@ private:
rpl::variable<bool> _showBackground = true;
rpl::variable<bool> _showDate = false;
rpl::variable<bool> _showReactions = false;
rpl::variable<bool> _showColorfulReplies = false;
rpl::variable<bool> _showColorfulReplies = true;
rpl::variable<bool> _revealSpoilers = true;
rpl::variable<int> _embeddedThemeType = -1;
rpl::variable<uint32> _embeddedThemeAccentColor = 0;