From 9fdb905a6e22227ab05f8514613c833442c97512 Mon Sep 17 00:00:00 2001 From: Sebastian Kaspari Date: Wed, 23 Mar 2016 15:56:24 +0100 Subject: [PATCH] Bug 1241810 - Review follow-up: Rename CheckAction.notify() to CheckAction.showNotification(). r=me MozReview-Commit-ID: EIRYnna6yf9 --HG-- extra : rebase_source : 5fa1e41087c5dfdb090adfdeca829d22665d590c --- .../org/mozilla/gecko/feeds/action/CheckAction.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/mobile/android/base/java/org/mozilla/gecko/feeds/action/CheckAction.java b/mobile/android/base/java/org/mozilla/gecko/feeds/action/CheckAction.java index dd8622bb1223..0d022004c55d 100644 --- a/mobile/android/base/java/org/mozilla/gecko/feeds/action/CheckAction.java +++ b/mobile/android/base/java/org/mozilla/gecko/feeds/action/CheckAction.java @@ -84,7 +84,7 @@ public class CheckAction extends BaseAction { cursor.close(); } - notify(updatedFeeds); + showNotification(updatedFeeds); } private FeedFetcher.FeedResponse checkFeedForUpdates(FeedSubscription subscription) { @@ -107,22 +107,22 @@ public class CheckAction extends BaseAction { return null; } - private void notify(List updatedFeeds) { + private void showNotification(List updatedFeeds) { final int feedCount = updatedFeeds.size(); if (feedCount == 0) { return; } if (feedCount == 1) { - notifySingle(updatedFeeds.get(0)); + showNotificationForSingleUpdate(updatedFeeds.get(0)); } else { - notifyMultiple(updatedFeeds); + showNotificationForMultipleUpdates(updatedFeeds); } Telemetry.sendUIEvent(TelemetryContract.Event.SHOW, TelemetryContract.Method.NOTIFICATION, "content_update"); } - private void notifySingle(Feed feed) { + private void showNotificationForSingleUpdate(Feed feed) { final String date = DateFormat.getMediumDateFormat(context).format(new Date(feed.getLastItem().getTimestamp())); NotificationCompat.BigTextStyle style = new NotificationCompat.BigTextStyle() @@ -151,7 +151,7 @@ public class CheckAction extends BaseAction { NotificationManagerCompat.from(context).notify(R.id.websiteContentNotification, notification); } - private void notifyMultiple(List feeds) { + private void showNotificationForMultipleUpdates(List feeds) { final ArrayList urls = new ArrayList<>(); final NotificationCompat.InboxStyle inboxStyle = new NotificationCompat.InboxStyle();