Chromium Code Reviews| Index: chrome/android/java/src/org/chromium/chrome/browser/notifications/NotificationUIManager.java |
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/notifications/NotificationUIManager.java b/chrome/android/java/src/org/chromium/chrome/browser/notifications/NotificationUIManager.java |
| index fa3a8315e4eb5454d1c699de92855984ed831603..b65ddcbb93327021f7bf0aefeec15d835735c821 100644 |
| --- a/chrome/android/java/src/org/chromium/chrome/browser/notifications/NotificationUIManager.java |
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/notifications/NotificationUIManager.java |
| @@ -436,6 +436,9 @@ static int makeDefaults(int vibrationPatternLength, boolean silent) { |
| * text by the Android notification system. |
| * @param icon Icon to be displayed in the notification. Valid Bitmap icons will be scaled to |
| * the platforms, whereas a default icon will be generated for invalid Bitmaps. |
| + * @param smallIcon Icon to represent the notification in places where there is not enough space |
| + * to display the whole notification. It may also be displayed inside the |
|
Peter Beverloo
2016/03/03 17:55:38
Let's explicitly call out the status bar?
Michael van Ouwerkerk
2016/03/09 18:28:25
Right, we're in Android code here.
|
| + * notification. |
| * @param vibrationPattern Vibration pattern following the Web Vibration syntax. |
| * @param timestamp The timestamp of the event for which the notification is being shown. |
| * @param renotify Whether the sound, vibration, and lights should be replayed if the |
| @@ -447,7 +450,7 @@ static int makeDefaults(int vibrationPatternLength, boolean silent) { |
| */ |
| @CalledByNative |
| private void displayNotification(long persistentNotificationId, String origin, String profileId, |
| - boolean incognito, String tag, String title, String body, Bitmap icon, |
| + boolean incognito, String tag, String title, String body, Bitmap icon, Bitmap smallIcon, |
| int[] vibrationPattern, long timestamp, boolean renotify, boolean silent, |
| String[] actionTitles, Bitmap[] actionIcons) { |
| if (actionTitles.length != actionIcons.length) { |
| @@ -486,6 +489,7 @@ private void displayNotification(long persistentNotificationId, String origin, S |
| .setBody(body) |
| .setLargeIcon(ensureNormalizedIcon(icon, origin)) |
| .setSmallIcon(R.drawable.ic_chrome) |
| + .setSmallIcon(smallIcon) |
| .setContentIntent(clickIntent) |
| .setDeleteIntent(closeIntent) |
| .setTicker(createTickerText(title, body)) |