[gnome-shell] telepathyClient: Use a single update for text and timestamp
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] telepathyClient: Use a single update for text and timestamp
- Date: Wed, 1 Mar 2017 19:47:21 +0000 (UTC)
commit 645aa01efd5b872ddbe1480335ae11dfbe863147
Author: Florian Müllner <fmuellner gnome org>
Date: Wed Mar 1 20:01:28 2017 +0100
telepathyClient: Use a single update for text and timestamp
Commit c6f22826cf added a call to update() to refresh the notification
time for sent and received messages. However as it omits the bannerMarkup
parameter, escaped text like ''' now makes it through verbatim.
Rather than adding the parameter, we can just refresh the timestamp in
the existing update() call to fix the issue - it means the notification
timestamp is only refreshed for received messages, but that reflects
the text shown in the notification, which isn't updated for sent
messages either.
https://bugzilla.gnome.org/show_bug.cgi?id=779435
js/ui/components/telepathyClient.js | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/js/ui/components/telepathyClient.js b/js/ui/components/telepathyClient.js
index f1fe09f..1cd8e61 100644
--- a/js/ui/components/telepathyClient.js
+++ b/js/ui/components/telepathyClient.js
@@ -660,7 +660,9 @@ const ChatNotification = new Lang.Class({
}
if (message.direction == NotificationDirection.RECEIVED)
- this.update(this.source.title, messageBody, { bannerMarkup: true });
+ this.update(this.source.title, messageBody,
+ { datetime: GLib.DateTime.new_from_unix_local (message.timestamp),
+ bannerMarkup: true });
let group = (message.direction == NotificationDirection.RECEIVED ?
'received' : 'sent');
@@ -670,8 +672,6 @@ const ChatNotification = new Lang.Class({
styles: styles,
timestamp: message.timestamp,
noTimestamp: noTimestamp });
- this.update(this.title, this.bannerBodyText,
- { datetime: GLib.DateTime.new_from_unix_local (message.timestamp) });
},
_filterMessages: function() {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]