Updated to TD 1.8.13

This commit is contained in:
Eric Kotato 2019-10-03 13:41:04 +03:00
commit eb5cf2177b
9 changed files with 38 additions and 14 deletions

View file

@ -9,7 +9,7 @@
<Identity Name="TelegramMessengerLLP.TelegramDesktop"
ProcessorArchitecture="ARCHITECTURE"
Publisher="CN=536BC709-8EE1-4478-AF22-F0F0F26FF64A"
Version="1.8.12.0" />
Version="1.8.13.0" />
<Properties>
<DisplayName>Telegram Desktop</DisplayName>
<PublisherDisplayName>Telegram FZ-LLC</PublisherDisplayName>

View file

@ -168,11 +168,20 @@ void AppendFoundEmoji(
std::vector<Result> &result,
const QString &label,
const std::vector<LangPackEmoji> &list) {
// It is important that the 'result' won't relocate while inserting.
result.reserve(result.size() + list.size());
const auto alreadyBegin = result.data();
const auto alreadyEnd = alreadyBegin + result.size();
auto &&add = ranges::view::all(
list
) | ranges::view::filter([&](const LangPackEmoji &entry) {
const auto i = ranges::find(result, entry.emoji, &Result::emoji);
return (i == end(result));
const auto i = ranges::find(
alreadyBegin,
alreadyEnd,
entry.emoji,
&Result::emoji);
return (i == alreadyEnd);
}) | ranges::view::transform([&](const LangPackEmoji &entry) {
return Result{ entry.emoji, label, entry.text };
});

View file

@ -15,8 +15,8 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
#define TDESKTOP_ALPHA_VERSION (0ULL)
#endif // TDESKTOP_OFFICIAL_TARGET
constexpr auto AppVersion = 1008012;
constexpr auto AppVersionStr = "1.8.12";
constexpr auto AppVersion = 1008013;
constexpr auto AppVersionStr = "1.8.13";
constexpr auto AppBetaVersion = false;
constexpr auto AppAlphaVersion = TDESKTOP_ALPHA_VERSION;
constexpr auto AppKotatoVersion = 1000004;

View file

@ -3165,8 +3165,8 @@ void HistoryWidget::doneShow() {
updateControlsVisibility();
if (!_historyInited) {
updateHistoryGeometry(true);
} else if (hasPendingResizedItems()) {
updateHistoryGeometry();
} else {
handlePendingHistoryUpdate();
}
preloadHistoryIfNeeded();
if (App::wnd()) {
@ -5008,11 +5008,15 @@ int HistoryWidget::countAutomaticScrollTop() {
return qMin(result, _scroll->scrollTopMax());
}
void HistoryWidget::updateHistoryGeometry(bool initial, bool loadedDown, const ScrollChange &change) {
void HistoryWidget::updateHistoryGeometry(
bool initial,
bool loadedDown,
const ScrollChange &change) {
if (!_history || (initial && _historyInited) || (!initial && !_historyInited)) {
return;
}
if (_firstLoadRequest || _a_show.animating()) {
_updateHistoryGeometryRequired = true;
return; // scrollTopMax etc are not working after recountHistoryGeometry()
}

View file

@ -27,12 +27,16 @@ Integration &Integration::Instance() {
return *IntegrationInstance;
}
bool Integration::Exists() {
return (IntegrationInstance != nullptr);
}
void Integration::textActionsUpdated() {
}
void Integration::activationFromTopPanel() {
void Integration::activationFromTopPanel() {
}
std::shared_ptr<ClickHandler> Integration::createLinkHandler(
EntityType type,
const QString &text,

View file

@ -28,6 +28,7 @@ class Integration {
public:
static void Set(not_null<Integration*> instance);
static Integration &Instance();
static bool Exists();
virtual void postponeCall(FnMut<void()> &&callable) = 0;
virtual void registerLeaveSubscription(not_null<QWidget*> widget) = 0;

View file

@ -12,7 +12,9 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
namespace Ui {
void WriteLogEntry(const QString &message) {
Integration::Instance().writeLogEntry(message);
if (Integration::Exists()) {
Integration::Instance().writeLogEntry(message);
}
}
} // namespace Ui

View file

@ -1,6 +1,6 @@
AppVersion 1008012
AppVersion 1008013
AppVersionStrMajor 1.8
AppVersionStrSmall 1.8.12
AppVersionStr 1.8.12
AppVersionStrSmall 1.8.13
AppVersionStr 1.8.13
BetaChannel 0
AlphaVersion 0

View file

@ -1,3 +1,7 @@
1.8.13 (03.10.19)
- Bug fixes and other minor improvements.
1.8.12 (02.10.19)
- Bug fixes and other minor improvements.