| OLD | NEW |
| (Empty) |
| 1 <html> | |
| 2 <head> | |
| 3 <script type="text/javascript"> | |
| 4 function SetSrc(src) { | |
| 5 plugin = document.getElementById('plugin'); | |
| 6 plugin.src = src; | |
| 7 } | |
| 8 </script> | |
| 9 </head> | |
| 10 | |
| 11 <body> | |
| 12 <button id="before" tabindex="0">Before</button> | |
| 13 <object id="plugin" | |
| 14 tabindex="0" | |
| 15 type="application/browser-plugin" | |
| 16 width="640" | |
| 17 height="480" | |
| 18 border="0px"></object> | |
| 19 <button id="after" tabindex="0">After</button> | |
| 20 <script type="text/javascript"> | |
| 21 var plugin = document.getElementById('plugin'); | |
| 22 plugin.addEventListener('-internal-instanceid-allocated', function(e) { | |
| 23 var detail = e.detail ? JSON.parse(e.detail) : {}; | |
| 24 plugin['-internal-attach'](detail.windowId, {}); | |
| 25 }); | |
| 26 </script> | |
| 27 </body> | |
| 28 </html> | |
| OLD | NEW |