mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-30 14:17:45 +00:00
Use "My Story" instead of name in viewer.
This commit is contained in:
@@ -236,7 +236,9 @@ void UserpicBadge::updateGeometry() {
|
||||
}
|
||||
|
||||
[[nodiscard]] TextWithEntities ComposeName(HeaderData data) {
|
||||
auto result = Ui::Text::Bold(data.user->shortName());
|
||||
auto result = Ui::Text::Bold(data.user->isSelf()
|
||||
? tr::lng_stories_my_name(tr::now)
|
||||
: data.user->shortName());
|
||||
if (data.fullCount) {
|
||||
result.append(QString::fromUtf8(" \xE2\x80\xA2 %1/%2"
|
||||
).arg(data.fullIndex + 1
|
||||
|
@@ -15,6 +15,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
||||
#include "data/data_photo_media.h"
|
||||
#include "data/data_session.h"
|
||||
#include "data/data_user.h"
|
||||
#include "lang/lang_keys.h"
|
||||
#include "main/main_session.h"
|
||||
#include "media/stories/media_stories_controller.h"
|
||||
#include "media/stories/media_stories_view.h"
|
||||
@@ -339,7 +340,9 @@ QImage Sibling::nameImage(const SiblingLayout &layout) {
|
||||
.linkFontOver = font,
|
||||
});
|
||||
};
|
||||
const auto text = _peer->shortName();
|
||||
const auto text = _peer->isSelf()
|
||||
? tr::lng_stories_my_name(tr::now)
|
||||
: _peer->shortName();
|
||||
if (_nameText != text) {
|
||||
_name.reset();
|
||||
_nameText = text;
|
||||
|
Reference in New Issue
Block a user