Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
645ae69220 | ||
|
|
782c5c28a8 | ||
|
|
fba683be8e | ||
|
|
552d96df71 | ||
|
|
1043467eec |
@@ -10,7 +10,7 @@
|
||||
<Identity Name="TelegramMessengerLLP.TelegramDesktop"
|
||||
ProcessorArchitecture="ARCHITECTURE"
|
||||
Publisher="CN=536BC709-8EE1-4478-AF22-F0F0F26FF64A"
|
||||
Version="4.1.2.0" />
|
||||
Version="4.2.0.0" />
|
||||
<Properties>
|
||||
<DisplayName>Telegram Desktop</DisplayName>
|
||||
<PublisherDisplayName>Telegram Messenger LLP</PublisherDisplayName>
|
||||
|
||||
@@ -44,8 +44,8 @@ IDI_ICON1 ICON "..\\art\\icon256.ico"
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 4,1,2,0
|
||||
PRODUCTVERSION 4,1,2,0
|
||||
FILEVERSION 4,2,0,0
|
||||
PRODUCTVERSION 4,2,0,0
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
@@ -62,10 +62,10 @@ BEGIN
|
||||
BEGIN
|
||||
VALUE "CompanyName", "Telegram FZ-LLC"
|
||||
VALUE "FileDescription", "Telegram Desktop"
|
||||
VALUE "FileVersion", "4.1.2.0"
|
||||
VALUE "FileVersion", "4.2.0.0"
|
||||
VALUE "LegalCopyright", "Copyright (C) 2014-2022"
|
||||
VALUE "ProductName", "Telegram Desktop"
|
||||
VALUE "ProductVersion", "4.1.2.0"
|
||||
VALUE "ProductVersion", "4.2.0.0"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
|
||||
@@ -35,8 +35,8 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 4,1,2,0
|
||||
PRODUCTVERSION 4,1,2,0
|
||||
FILEVERSION 4,2,0,0
|
||||
PRODUCTVERSION 4,2,0,0
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
@@ -53,10 +53,10 @@ BEGIN
|
||||
BEGIN
|
||||
VALUE "CompanyName", "Telegram FZ-LLC"
|
||||
VALUE "FileDescription", "Telegram Desktop Updater"
|
||||
VALUE "FileVersion", "4.1.2.0"
|
||||
VALUE "FileVersion", "4.2.0.0"
|
||||
VALUE "LegalCopyright", "Copyright (C) 2014-2022"
|
||||
VALUE "ProductName", "Telegram Desktop"
|
||||
VALUE "ProductVersion", "4.1.2.0"
|
||||
VALUE "ProductVersion", "4.2.0.0"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
|
||||
@@ -94,7 +94,7 @@ AdminLog::OwnedItem GenerateItem(
|
||||
void AddMessage(
|
||||
not_null<Ui::VerticalLayout*> container,
|
||||
not_null<Window::SessionController*> controller,
|
||||
rpl::producer<QString> &&emojiValue,
|
||||
rpl::producer<Data::ReactionId> &&idValue,
|
||||
int width) {
|
||||
|
||||
const auto widget = container->add(
|
||||
@@ -216,38 +216,52 @@ void AddMessage(
|
||||
view->draw(p, context);
|
||||
}, widget->lifetime());
|
||||
|
||||
auto selectedEmoji = rpl::duplicate(emojiValue);
|
||||
auto selectedId = rpl::duplicate(idValue);
|
||||
std::move(
|
||||
selectedEmoji
|
||||
selectedId
|
||||
) | rpl::start_with_next([
|
||||
=,
|
||||
emojiValue = std::move(emojiValue),
|
||||
idValue = std::move(idValue),
|
||||
iconSize = st::settingsReactionMessageSize
|
||||
](const QString &emoji) {
|
||||
const auto id = Data::ReactionId{ emoji };
|
||||
](const Data::ReactionId &id) {
|
||||
const auto index = state->icons.flag ? 1 : 0;
|
||||
state->icons.flag = !state->icons.flag;
|
||||
state->icons.lifetimes[index] = rpl::lifetime();
|
||||
const auto &reactions = controller->session().data().reactions();
|
||||
auto iconPositionValue = widget->geometryValue(
|
||||
) | rpl::map([=](const QRect &r) {
|
||||
return widget->pos()
|
||||
+ rightRect().topLeft()
|
||||
+ QPoint(
|
||||
(rightSize.width() - iconSize) / 2,
|
||||
(rightSize.height() - iconSize) / 2);
|
||||
});
|
||||
auto destroys = rpl::duplicate(
|
||||
idValue
|
||||
) | rpl::skip(1) | rpl::to_empty;
|
||||
if (const auto customId = id.custom()) {
|
||||
AddReactionCustomIcon(
|
||||
container,
|
||||
std::move(iconPositionValue),
|
||||
iconSize,
|
||||
controller,
|
||||
customId,
|
||||
std::move(destroys),
|
||||
&state->icons.lifetimes[index]);
|
||||
return;
|
||||
}
|
||||
for (const auto &r : reactions.list(Data::Reactions::Type::Active)) {
|
||||
if (r.id != id) {
|
||||
continue;
|
||||
}
|
||||
const auto index = state->icons.flag ? 1 : 0;
|
||||
state->icons.lifetimes[index] = rpl::lifetime();
|
||||
AddReactionAnimatedIcon(
|
||||
container,
|
||||
widget->geometryValue(
|
||||
) | rpl::map([=](const QRect &r) {
|
||||
return widget->pos()
|
||||
+ rightRect().topLeft()
|
||||
+ QPoint(
|
||||
(rightSize.width() - iconSize) / 2,
|
||||
(rightSize.height() - iconSize) / 2);
|
||||
}),
|
||||
std::move(iconPositionValue),
|
||||
iconSize,
|
||||
r,
|
||||
rpl::never<>(),
|
||||
rpl::duplicate(emojiValue) | rpl::skip(1) | rpl::to_empty,
|
||||
std::move(destroys),
|
||||
&state->icons.lifetimes[index]);
|
||||
state->icons.flag = !state->icons.flag;
|
||||
return;
|
||||
}
|
||||
}, widget->lifetime());
|
||||
@@ -455,20 +469,18 @@ void ReactionsSettingsBox(
|
||||
not_null<Window::SessionController*> controller) {
|
||||
|
||||
struct State {
|
||||
rpl::variable<QString> selectedEmoji;
|
||||
rpl::variable<Data::ReactionId> selectedId;
|
||||
};
|
||||
|
||||
const auto &reactions = controller->session().data().reactions();
|
||||
const auto state = box->lifetime().make_state<State>();
|
||||
state->selectedEmoji = v::is<QString>(reactions.favoriteId().data)
|
||||
? v::get<QString>(reactions.favoriteId().data)
|
||||
: QString();
|
||||
state->selectedId = reactions.favoriteId();
|
||||
|
||||
const auto pinnedToTop = box->setPinnedToTopContent(
|
||||
object_ptr<Ui::VerticalLayout>(box));
|
||||
|
||||
auto emojiValue = state->selectedEmoji.value();
|
||||
AddMessage(pinnedToTop, controller, std::move(emojiValue), box->width());
|
||||
auto idValue = state->selectedId.value();
|
||||
AddMessage(pinnedToTop, controller, std::move(idValue), box->width());
|
||||
|
||||
Settings::AddSubsectionTitle(
|
||||
pinnedToTop,
|
||||
@@ -492,7 +504,13 @@ void ReactionsSettingsBox(
|
||||
|
||||
auto firstCheckedButton = (Ui::RpWidget*)(nullptr);
|
||||
const auto premiumPossible = controller->session().premiumPossible();
|
||||
for (const auto &r : reactions.list(Data::Reactions::Type::Active)) {
|
||||
auto list = reactions.list(Data::Reactions::Type::Active);
|
||||
if (const auto favorite = reactions.favorite()) {
|
||||
if (favorite->id.custom()) {
|
||||
list.insert(begin(list), *favorite);
|
||||
}
|
||||
}
|
||||
for (const auto &r : list) {
|
||||
const auto button = Settings::AddButton(
|
||||
container,
|
||||
rpl::single<QString>(base::duplicate(r.title)),
|
||||
@@ -504,23 +522,35 @@ void ReactionsSettingsBox(
|
||||
}
|
||||
|
||||
const auto iconSize = st::settingsReactionSize;
|
||||
AddReactionAnimatedIcon(
|
||||
button,
|
||||
button->sizeValue(
|
||||
) | rpl::map([=, left = button->st().iconLeft](const QSize &s) {
|
||||
return QPoint(
|
||||
left + st::settingsReactionRightSkip,
|
||||
(s.height() - iconSize) / 2);
|
||||
}),
|
||||
iconSize,
|
||||
r,
|
||||
button->events(
|
||||
) | rpl::filter([=](not_null<QEvent*> event) {
|
||||
return event->type() == QEvent::Enter;
|
||||
}) | rpl::to_empty,
|
||||
rpl::never<>(),
|
||||
&button->lifetime());
|
||||
|
||||
const auto left = button->st().iconLeft;
|
||||
auto iconPositionValue = button->sizeValue(
|
||||
) | rpl::map([=](const QSize &s) {
|
||||
return QPoint(
|
||||
left + st::settingsReactionRightSkip,
|
||||
(s.height() - iconSize) / 2);
|
||||
});
|
||||
if (const auto customId = r.id.custom()) {
|
||||
AddReactionCustomIcon(
|
||||
button,
|
||||
std::move(iconPositionValue),
|
||||
iconSize,
|
||||
controller,
|
||||
customId,
|
||||
rpl::never<>(),
|
||||
&button->lifetime());
|
||||
} else {
|
||||
AddReactionAnimatedIcon(
|
||||
button,
|
||||
std::move(iconPositionValue),
|
||||
iconSize,
|
||||
r,
|
||||
button->events(
|
||||
) | rpl::filter([=](not_null<QEvent*> event) {
|
||||
return event->type() == QEvent::Enter;
|
||||
}) | rpl::to_empty,
|
||||
rpl::never<>(),
|
||||
&button->lifetime());
|
||||
}
|
||||
button->setClickedCallback([=, id = r.id] {
|
||||
if (premium && !controller->session().premium()) {
|
||||
ShowPremiumPreviewBox(
|
||||
@@ -529,11 +559,9 @@ void ReactionsSettingsBox(
|
||||
return;
|
||||
}
|
||||
checkButton(button);
|
||||
state->selectedEmoji = v::is<QString>(id.data)
|
||||
? v::get<QString>(id.data)
|
||||
: QString();
|
||||
state->selectedId = id;
|
||||
});
|
||||
if (r.id == Data::ReactionId{ state->selectedEmoji.current() }) {
|
||||
if (r.id == state->selectedId.current()) {
|
||||
firstCheckedButton = button;
|
||||
}
|
||||
}
|
||||
@@ -551,9 +579,9 @@ void ReactionsSettingsBox(
|
||||
box->setWidth(st::boxWideWidth);
|
||||
box->addButton(tr::lng_settings_save(), [=] {
|
||||
const auto &data = controller->session().data();
|
||||
const auto selected = state->selectedEmoji.current();
|
||||
if (data.reactions().favoriteId() != Data::ReactionId{ selected }) {
|
||||
data.reactions().setFavorite(Data::ReactionId{ selected });
|
||||
const auto selectedId = state->selectedId.current();
|
||||
if (data.reactions().favoriteId() != selectedId) {
|
||||
data.reactions().setFavorite(selectedId);
|
||||
}
|
||||
box->closeBox();
|
||||
});
|
||||
|
||||
@@ -22,7 +22,7 @@ constexpr auto AppId = "{53F49750-6209-4FBF-9CA8-7A333C87D1ED}"_cs;
|
||||
constexpr auto AppNameOld = "Telegram Win (Unofficial)"_cs;
|
||||
constexpr auto AppName = "Telegram Desktop"_cs;
|
||||
constexpr auto AppFile = "Telegram"_cs;
|
||||
constexpr auto AppVersion = 4001002;
|
||||
constexpr auto AppVersionStr = "4.1.2";
|
||||
constexpr auto AppBetaVersion = true;
|
||||
constexpr auto AppVersion = 4002000;
|
||||
constexpr auto AppVersionStr = "4.2";
|
||||
constexpr auto AppBetaVersion = false;
|
||||
constexpr auto AppAlphaVersion = TDESKTOP_ALPHA_VERSION;
|
||||
|
||||
@@ -1447,6 +1447,7 @@ void Message::unloadHeavyPart() {
|
||||
_comments = nullptr;
|
||||
if (_fromNameStatus) {
|
||||
_fromNameStatus->custom = nullptr;
|
||||
_fromNameStatus->id = 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{%- set GIT = "https://github.com" -%}
|
||||
{%- set GIT_FREEDESKTOP = GIT ~ "/gitlab-freedesktop-mirrors" -%}
|
||||
{%- set QT = "6_4_0" -%}
|
||||
{%- set QT_TAG = "v6.4.0-beta4" -%}
|
||||
{%- set QT_TAG = "v6.4.0-rc1" -%}
|
||||
{%- set QT_PREFIX = "/usr/local/desktop-app/Qt-6.4.0" -%}
|
||||
{%- set OPENSSL_VER = "1_1_1" -%}
|
||||
{%- set OPENSSL_PREFIX = "/usr/local/desktop-app/openssl-1.1.1" -%}
|
||||
@@ -48,7 +48,7 @@ RUN mkdir /opt/cmake \
|
||||
FROM builder AS patches
|
||||
RUN git clone {{ GIT }}/desktop-app/patches.git \
|
||||
&& cd patches \
|
||||
&& git checkout 88c251102f \
|
||||
&& git checkout 355c563138 \
|
||||
&& rm -rf .git
|
||||
|
||||
FROM builder AS extra-cmake-modules
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
AppVersion 4001002
|
||||
AppVersionStrMajor 4.1
|
||||
AppVersionStrSmall 4.1.2
|
||||
AppVersionStr 4.1.2
|
||||
BetaChannel 1
|
||||
AppVersion 4002000
|
||||
AppVersionStrMajor 4.2
|
||||
AppVersionStrSmall 4.2
|
||||
AppVersionStr 4.2.0
|
||||
BetaChannel 0
|
||||
AlphaVersion 0
|
||||
AppVersionOriginal 4.1.2.beta
|
||||
AppVersionOriginal 4.2
|
||||
|
||||
Submodule Telegram/lib_ui updated: 38875a85be...f82162f05a
@@ -1,3 +1,17 @@
|
||||
4.2 (17.09.22)
|
||||
|
||||
- A new expandable reaction menu was added in private chats and groups.
|
||||
- All users get access to dozens of new reactions, including reactions previously reserved for Premium users.
|
||||
- The reactions you use most frequently will always be displayed at the top.
|
||||
- Premium users can react to messages with thousands of custom emoji and add up to 3 reactions to each message.
|
||||
- Group admins can control whether custom reactions are allowed in their groups.
|
||||
- Premium users can add an animated emoji status next to their name to display their current activity.
|
||||
- To set a status, tap your Premium badge in the main menu or Settings.
|
||||
- Popular suggestions for working, sleeping, traveling and more will be shown at the top.
|
||||
- To set a status for a specific duration like 1 hour or 2 days, right click the emoji.
|
||||
- A new format was supported for username links, in addition to "t.me/username." You can now open Telegram accounts, groups or channels using links like "username.t.me" or "https://username.t.me."
|
||||
- Improved support for long media captions.
|
||||
|
||||
4.1.2 beta (14.09.22)
|
||||
|
||||
- New reaction selector above the right click menu.
|
||||
|
||||
@@ -398,7 +398,7 @@ parts:
|
||||
override-pull: |
|
||||
QT=6_4_0
|
||||
|
||||
git clone -b v6.4.0-beta4 --depth=1 git://code.qt.io/qt/qt5.git .
|
||||
git clone -b v6.4.0-rc1 --depth=1 git://code.qt.io/qt/qt5.git .
|
||||
perl init-repository --module-subset=qtbase,qtwayland,qtimageformats,qtsvg,qt5compat
|
||||
|
||||
cd qtbase
|
||||
@@ -446,7 +446,7 @@ parts:
|
||||
qttools:
|
||||
source: git://code.qt.io/qt/qttools.git
|
||||
source-depth: 1
|
||||
source-tag: v6.4.0-beta4
|
||||
source-tag: v6.4.0-rc1
|
||||
plugin: cmake
|
||||
build-packages:
|
||||
- clang
|
||||
|
||||
Reference in New Issue
Block a user