| Index: chrome/browser/extensions/api/notifications/notifications_api.cc
|
| diff --git a/chrome/browser/extensions/api/notifications/notifications_api.cc b/chrome/browser/extensions/api/notifications/notifications_api.cc
|
| index de01be5926024233eeb7c8d71aa14e4004706265..8bd5aee431d1acd4242d6d9af0cd317c1535ace8 100644
|
| --- a/chrome/browser/extensions/api/notifications/notifications_api.cc
|
| +++ b/chrome/browser/extensions/api/notifications/notifications_api.cc
|
| @@ -285,6 +285,16 @@ bool NotificationsApiFunction::CreateNotification(
|
|
|
| // Then, handle any optional data that's been provided.
|
| message_center::RichNotificationData optional_fields;
|
| + if (options->app_icon_mask_url.get()) {
|
| + if (!NotificationBitmapToGfxImage(image_scale,
|
| + bitmap_sizes.app_icon_mask_size,
|
| + options->app_icon_mask_bitmap.get(),
|
| + &optional_fields.small_image)) {
|
| + SetError(kUnableToDecodeIconError);
|
| + return false;
|
| + }
|
| + }
|
| +
|
| if (options->priority.get())
|
| optional_fields.priority = *options->priority;
|
|
|
| @@ -402,6 +412,14 @@ bool NotificationsApiFunction::UpdateNotification(
|
| notification->set_icon(icon);
|
| }
|
|
|
| + gfx::Image app_icon_mask;
|
| + if (NotificationBitmapToGfxImage(image_scale,
|
| + bitmap_sizes.app_icon_mask_size,
|
| + options->app_icon_mask_bitmap.get(),
|
| + &app_icon_mask)) {
|
| + notification->set_small_image(app_icon_mask);
|
| + }
|
| +
|
| if (options->priority)
|
| notification->set_priority(*options->priority);
|
|
|
|
|