2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 14:38:15 +00:00

Using same notification options for all notification managers.

This commit is contained in:
John Preston
2016-10-08 11:38:53 +03:00
parent 6798b86655
commit 377d333f1c
11 changed files with 64 additions and 41 deletions

View File

@@ -53,6 +53,13 @@ public:
void notificationActivated(PeerId peerId, MsgId msgId);
void notificationReplied(PeerId peerId, MsgId msgId, const QString &reply);
struct DisplayOptions {
bool hideNameAndPhoto;
bool hideMessageText;
bool hideReplyButton;
};
static DisplayOptions getNotificationOptions(HistoryItem *item);
virtual ~Manager() = default;
protected:
@@ -81,7 +88,7 @@ protected:
}
void doShowNotification(HistoryItem *item, int forwardedCount) override;
virtual void doShowNativeNotification(PeerData *peer, MsgId msgId, const QString &title, const QString &subtitle, bool showUserpic, const QString &msg, bool showReplyButton) = 0;
virtual void doShowNativeNotification(PeerData *peer, MsgId msgId, const QString &title, const QString &subtitle, const QString &msg, bool hideNameAndPhoto, bool hideReplyButton) = 0;
};