From 45fc7ced282420eff334075693d6fa2f9cef3ee6 Mon Sep 17 00:00:00 2001 From: Jessica McKellar Date: Thu, 18 Jul 2013 15:55:43 -0400 Subject: [PATCH] Show the total unread count in notifications, even if narrowed. Previously we'd display the unread count for the current narrow. (imported from commit 4939fc5cf0efcf9662b2b359f2247f915a334ac8) --- zephyr/static/js/ui.js | 2 +- zephyr/static/js/zephyr.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/zephyr/static/js/ui.js b/zephyr/static/js/ui.js index fb9802c57b..84d415b27a 100644 --- a/zephyr/static/js/ui.js +++ b/zephyr/static/js/ui.js @@ -338,7 +338,7 @@ function resizehandler(e) { // screen resolution changes, so we might want to wait for a more // intentional action to say that the user has "read" a message. var res = unread.get_counts(); - notifications_bar.update(res.unread_in_current_view); + notifications_bar.update(res.home_unread_messages); } $(function () { diff --git a/zephyr/static/js/zephyr.js b/zephyr/static/js/zephyr.js index 2c5d972488..704609ef29 100644 --- a/zephyr/static/js/zephyr.js +++ b/zephyr/static/js/zephyr.js @@ -265,9 +265,9 @@ function update_unread_counts() { // This updates some DOM elements directly, so try to // avoid excessive calls to this. stream_list.update_dom_with_unread_counts(res); - notifications.update_title_count(res.unread_in_current_view); + notifications.update_title_count(res.home_unread_messages); notifications.update_pm_count(res.private_message_count); - notifications_bar.update(res.unread_in_current_view); + notifications_bar.update(res.home_unread_messages); } function mark_all_as_read(cont) {