OLD | NEW |
1 <table class="intro"> | |
2 <tr> | |
3 <th scope="col"></th> | |
4 <th scope="col"></th> | |
5 </tr> | |
6 <tr> | |
7 <td><strong>Description:</strong></td> | |
8 <td>Use the <code>chrome.notifications</code> module | |
9 to create rich notifications using templates and | |
10 show these notifications to users in the system tray | |
11 (see <a href="#usage">Usage</a>).</td> | |
12 </tr> | |
13 <tr> | |
14 <td><strong>Availability:</strong></td> | |
15 <td>Google Chrome Dev Channel Only</td> | |
16 </tr> | |
17 <tr> | |
18 <td><strong>Permissions:</strong></td> | |
19 <td><code>"notifications"</code></td> | |
20 </tr> | |
21 <tr> | |
22 <td><strong>Learn more:</strong></td> | |
23 <td><a href="https://developers.google.com/live/shows/83992232-1001/">Chrome
Apps Office Hours: Rich Notifications</a></td> | |
24 </tr> | |
25 </table> | |
26 | |
27 <p class="warning"> | 1 <p class="warning"> |
28 <b>Warning: </b> | 2 <b>Warning: </b> |
29 Currently this API only works on ChromeOS and Windows. | 3 Currently this API only works on ChromeOS and Windows. |
30 </p> | 4 </p> |
31 | 5 |
32 <h2 id="usage">Usage</h2> | 6 <h2 id="usage">Usage</h2> |
33 | 7 |
34 <p> | 8 <p> |
35 To use this API, | 9 To use this API, |
36 call the $ref:notifications.create method, | 10 call the $ref:notifications.create method, |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
104 that respond to user actions. | 78 that respond to user actions. |
105 For example, | 79 For example, |
106 you can write an event handler to respond to an | 80 you can write an event handler to respond to an |
107 $ref:notifications.onButtonClicked event. | 81 $ref:notifications.onButtonClicked event. |
108 </p> | 82 </p> |
109 | 83 |
110 <p>Consider including event listeners and handlers within the | 84 <p>Consider including event listeners and handlers within the |
111 <a href="app_lifecycle.html#create_event_page">event page</a>, | 85 <a href="app_lifecycle.html#create_event_page">event page</a>, |
112 so that notifications can pop-up even when the app or extension isn't running. | 86 so that notifications can pop-up even when the app or extension isn't running. |
113 </p> | 87 </p> |
OLD | NEW |