Rubber-stamped by Brady Eidson.
[webbrowser.git] / LayoutTests / fast / notifications / notifications-event-stop-propagation.html-disabled
blob2f32815802fee1b36047ba9d7f688358c19048d8
1 <!DOCTYPE html>
2 <html>
3 <head>
4     <script type="text/javascript">
5         function log(message)
6         {
7             document.getElementById("result").innerHTML += message + "<br>";
8         }
9         
10         function runTests()
11         {
12             if (window.layoutTestController) {
13                 layoutTestController.grantDesktopNotificationPermission("file://");
14                 layoutTestController.dumpAsText();
15             }
17             if (!window.webkitNotifications) {
18                 log("FAIL: No webkitNotifications interface!");
19             }
20             
21             var N = window.webkitNotifications.createNotification("http://localhost/my_icon.png", "New E-mail", "Meet me tonight at 8!");
22             N.addEventListener("display", function(e) { log("PASS: addEventListener(display) non-capture callback invoked"); });
23             N.ondisplay =                 function(e) { log("PASS: ondisplay attribute event callback invoked."); }
24             N.addEventListener("display", function(e) { log("PASS: addEventListener(display) capture callback invoked"); e.stopPropagation(); }, true );
25             N.show();
26             N.cancel();
27         }
28     </script>
29 </head>
30 <body>
31 <p>Sending notifications with permission...</p>
32 <div id="result"></div>    
33     
34 <script type="text/javascript">
35 runTests();
36 </script>
37 </body>
38 </html>