summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFlorian Müllner <fmuellner@gnome.org>2015-06-02 15:46:37 +0200
committerFlorian Müllner <fmuellner@gnome.org>2015-08-05 17:33:19 +0200
commitbe3d62487cdfc212f054e544814033a59a891e02 (patch)
treeef98fb70369b50db334324c25e8c5d39b2dffa6d
parent58905bd01aa380aad574c25815ad9d10d50af425 (diff)
calendar: Minor cleanup
Add a constant for the icon size used in message list entries rather than hardcoding it twice. https://bugzilla.gnome.org/show_bug.cgi?id=749958
-rw-r--r--js/ui/calendar.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/js/ui/calendar.js b/js/ui/calendar.js
index b571e4c6..64b68718 100644
--- a/js/ui/calendar.js
+++ b/js/ui/calendar.js
@@ -24,6 +24,8 @@ const MSECS_IN_DAY = 24 * 60 * 60 * 1000;
const SHOW_WEEKDATE_KEY = 'show-weekdate';
const ELLIPSIS_CHAR = '\u2026';
+const MESSAGE_ICON_SIZE = 48;
+
const MESSAGE_ANIMATION_TIME = 0.1;
const DEFAULT_EXPAND_LINES = 6;
@@ -1240,9 +1242,10 @@ const NotificationMessage = new Lang.Class({
_getIcon: function() {
if (this.notification.gicon)
- return new St.Icon({ gicon: this.notification.gicon, icon_size: 48 });
+ return new St.Icon({ gicon: this.notification.gicon,
+ icon_size: MESSAGE_ICON_SIZE });
else
- return this.notification.source.createIcon(48);
+ return this.notification.source.createIcon(MESSAGE_ICON_SIZE);
},
_onUpdated: function(n, clear) {