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

Side by Side Diff: chrome/common/extensions/api/notifications.idl

Issue 20136004: Allow partial update for notification update API (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add more tests per feedback Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // Use the <code>chrome.notifications</code> API to create rich notifications 5 // Use the <code>chrome.notifications</code> API to create rich notifications
6 // using templates and show these notifications to users in the system tray. 6 // using templates and show these notifications to users in the system tray.
7 namespace notifications { 7 namespace notifications {
8 [noinline_doc] enum TemplateType { 8 [noinline_doc] enum TemplateType {
9 // icon, title, message, expandedMessage, up to two buttons 9 // icon, title, message, expandedMessage, up to two buttons
10 basic, 10 basic,
(...skipping 23 matching lines...) Expand all
34 }; 34 };
35 35
36 dictionary NotificationButton { 36 dictionary NotificationButton {
37 DOMString title; 37 DOMString title;
38 DOMString? iconUrl; 38 DOMString? iconUrl;
39 [nodoc] NotificationBitmap? iconBitmap; 39 [nodoc] NotificationBitmap? iconBitmap;
40 }; 40 };
41 41
42 dictionary NotificationOptions { 42 dictionary NotificationOptions {
43 // Which type of notification to display. 43 // Which type of notification to display.
44 TemplateType type; 44 TemplateType? type;
45 45
46 // Sender's avatar, app icon, or a thumbnail for image notifications. 46 // Sender's avatar, app icon, or a thumbnail for image notifications.
47 DOMString iconUrl; 47 DOMString? iconUrl;
48 [nodoc] NotificationBitmap? iconBitmap; 48 [nodoc] NotificationBitmap? iconBitmap;
49 49
50 // Title of the notification (e.g. sender name for email). 50 // Title of the notification (e.g. sender name for email).
51 DOMString title; 51 DOMString? title;
52 52
53 // Main notification content. 53 // Main notification content.
54 DOMString message; 54 DOMString? message;
55 55
56 // Priority ranges from -2 to 2. -2 is lowest priority. 2 is highest. Zero 56 // Priority ranges from -2 to 2. -2 is lowest priority. 2 is highest. Zero
57 // is default. 57 // is default.
58 long? priority; 58 long? priority;
59 59
60 // A timestamp associated with the notification, in milliseconds past the 60 // A timestamp associated with the notification, in milliseconds past the
61 // epoch (e.g. <code>Date.now() + n</code>). 61 // epoch (e.g. <code>Date.now() + n</code>).
62 double? eventTime; 62 double? eventTime;
63 63
64 // Text and icons of notification action buttons. 64 // Text and icons of notification action buttons.
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 static void onClosed(DOMString notificationId, boolean byUser); 119 static void onClosed(DOMString notificationId, boolean byUser);
120 120
121 // The user clicked in a non-button area of the notification. 121 // The user clicked in a non-button area of the notification.
122 static void onClicked(DOMString notificationId); 122 static void onClicked(DOMString notificationId);
123 123
124 // The user pressed a button in the notification. 124 // The user pressed a button in the notification.
125 static void onButtonClicked(DOMString notificationId, long buttonIndex); 125 static void onButtonClicked(DOMString notificationId, long buttonIndex);
126 }; 126 };
127 127
128 }; 128 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698