Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1335)

Unified Diff: third_party/WebKit/public/platform/modules/notifications/WebNotificationConstants.h

Issue 2261283002: Add Notification images (Blink + desktop implementation) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/public/platform/modules/notifications/WebNotificationConstants.h
diff --git a/third_party/WebKit/public/platform/modules/notifications/WebNotificationConstants.h b/third_party/WebKit/public/platform/modules/notifications/WebNotificationConstants.h
index 01714058424cd064fb79259e37e3137ea2cb16ee..645624bfcfb585d79bc2f9b08457b710619bea35 100644
--- a/third_party/WebKit/public/platform/modules/notifications/WebNotificationConstants.h
+++ b/third_party/WebKit/public/platform/modules/notifications/WebNotificationConstants.h
@@ -16,6 +16,11 @@ static const size_t kWebNotificationMaxActions = 2;
// TODO(mvanouwerkerk): Update the notification resource loader to get the
// appropriate image sizes from the embedder.
+// The maximum reasonable image size, scaled from dip units to pixels using the
+// largest supported scaling factor. TODO(johnme): Check sizes are correct.
Peter Beverloo 2016/08/22 20:11:07 Please do this prior to landing the CL.
johnme 2016/08/23 14:59:49 Ack, though gonna be tricky since it's platform-de
Peter Beverloo 2016/08/24 15:21:11 Right now it'd come down to max([android dips] * 4
+static const int kWebNotificationMaxImageWidthPx = 1800; // 450 dip * 4
+static const int kWebNotificationMaxImageHeightPx = 900; // 225 dip * 4
Peter Beverloo 2016/08/22 20:11:07 nit: consider s/const/constexpr/ in this file.
johnme 2016/08/23 14:59:49 Done.
+
// The maximum reasonable notification icon size, scaled from dip units to
// pixels using the largest supported scaling factor.
static const int kWebNotificationMaxIconSizePx = 320; // 80 dip * 4

Powered by Google App Engine
This is Rietveld 408576698