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

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

Issue 11554030: <webview>: Add name attribute (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merged with ToT Created 7 years, 11 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
(Empty)
1 <html>
2 <body>
3 <object id="plugin"
4 type="application/browser-plugin"
5 width="640"
6 height="480"></object>
7 <script>
8 var loadstop = false;
9 var requestCommChannel = false;
10 function SetSrc(src) {
11 var plugin = document.getElementById('plugin');
12 plugin.src = src;
13 }
14 // Open a two-way communication channel with the guest.
15 function OpenCommChannel() {
16 if (!loadstop) {
17 requestCommChannel = true;
18 return;
19 }
20 var plugin = document.getElementById('plugin');
21 plugin.contentWindow.frames.postMessage('test', '*');
22 }
23
24 // Establish a two-way channel with the guest.
25 window.addEventListener('message', function(e) {
26 document.title = event.data;
27 });
28 var plugin = document.getElementById('plugin');
29 plugin.addEventListener('-internal-loadstop', function(e) {
30 loadstop = true;
31 if (requestCommChannel) {
32 plugin.contentWindow.frames.postMessage('test', '*');
33 }
34 });
35 </script>
36 </body>
37 </html>
OLDNEW
« no previous file with comments | « content/renderer/render_view_impl.cc ('k') | content/test/data/browser_plugin_naming_guest.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698