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

Side by Side Diff: content/test/data/post_message.html

Issue 1202593002: Move browser-to-renderer opener plumbing to frame routing IDs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@opener-create-opener-render-views
Patch Set: Remove suppress_opener Created 5 years, 5 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
« no previous file with comments | « content/renderer/render_view_impl.cc ('k') | content/test/test_render_view_host.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <html> 1 <html>
2 2
3 <head><title>Post message tests</title> 3 <head><title>Post message tests</title>
4 <script> 4 <script>
5 // Send a message to our opener, and it will reply. 5 // Send a message to our opener, and it will reply.
6 function postToOpener(msg, origin) { 6 function postToOpener(msg, origin) {
7 window.opener.postMessage(msg, origin); 7 window.opener.postMessage(msg, origin);
8 return true; 8 return true;
9 } 9 }
10 10
11 // Send a message to our opener's opener.
12 function postToOpenerOfOpener(msg, origin) {
13 window.opener.opener.postMessage(msg, origin);
14 return true;
15 }
16
11 // Send a message to a window named "foo". 17 // Send a message to a window named "foo".
12 function postToFoo(msg) { 18 function postToFoo(msg) {
13 var w = window.open("", "foo"); 19 var w = window.open("", "foo");
14 w.postMessage(msg, "*"); 20 w.postMessage(msg, "*");
15 return true; 21 return true;
16 } 22 }
17 23
18 function openPopup(url) { 24 function openPopup(url) {
19 popup = window.open(url); 25 popup = window.open(url);
20 } 26 }
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 // Change the title to generate a notification. 77 // Change the title to generate a notification.
72 document.title = event.data.message; 78 document.title = event.data.message;
73 } else { 79 } else {
74 document.title = event.data; 80 document.title = event.data;
75 } 81 }
76 } 82 }
77 </script> 83 </script>
78 </head> 84 </head>
79 85
80 </html> 86 </html>
OLDNEW
« no previous file with comments | « content/renderer/render_view_impl.cc ('k') | content/test/test_render_view_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698