From 167a73ef1bc411a713424352d66c27d2c9181c33 Mon Sep 17 00:00:00 2001 From: John Preston Date: Mon, 9 Nov 2020 12:36:15 +0300 Subject: [PATCH] Add sent/read checks for some service messages. --- Telegram/SourceFiles/history/history_service.cpp | 5 +++++ Telegram/SourceFiles/history/history_service.h | 4 +--- Telegram/lib_base | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/Telegram/SourceFiles/history/history_service.cpp b/Telegram/SourceFiles/history/history_service.cpp index 25a7339223..bda13ceac4 100644 --- a/Telegram/SourceFiles/history/history_service.cpp +++ b/Telegram/SourceFiles/history/history_service.cpp @@ -617,6 +617,11 @@ bool HistoryService::updateDependencyItem() { return HistoryItem::updateDependencyItem(); } +bool HistoryService::needCheck() const { + return (GetDependentData() != nullptr) + || Has(); +} + QString HistoryService::inDialogsText(DrawInDialog way) const { return textcmdLink(1, TextUtilities::Clean(notificationText())); } diff --git a/Telegram/SourceFiles/history/history_service.h b/Telegram/SourceFiles/history/history_service.h index 200f6c8f6c..99e93be8d5 100644 --- a/Telegram/SourceFiles/history/history_service.h +++ b/Telegram/SourceFiles/history/history_service.h @@ -95,9 +95,7 @@ public: Storage::SharedMediaTypesMask sharedMediaTypes() const override; - bool needCheck() const override { - return false; - } + bool needCheck() const override; bool serviceMsg() const override { return true; } diff --git a/Telegram/lib_base b/Telegram/lib_base index 2d674eff93..4f22126e7e 160000 --- a/Telegram/lib_base +++ b/Telegram/lib_base @@ -1 +1 @@ -Subproject commit 2d674eff931c2540147e4f1ac29965e90ab4af22 +Subproject commit 4f22126e7e855b517857408abf2467cba163a6f2