| OLD | NEW |
| 1 <script type="text/javascript"> | 1 <script type="text/javascript"> |
| 2 function SetSrc(src) { | 2 function SetSrc(src) { |
| 3 var plugin = document.getElementById('plugin'); | 3 var plugin = document.getElementById('plugin'); |
| 4 plugin.src = src; | 4 plugin.src = src; |
| 5 } | 5 } |
| 6 function SetSize(w, h) { | 6 function SetSize(w, h) { |
| 7 var plugin = document.getElementById('plugin'); | 7 var plugin = document.getElementById('plugin'); |
| 8 plugin.width = w; | 8 plugin.width = w; |
| 9 plugin.height = h; | 9 plugin.height = h; |
| 10 } | 10 } |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 window.document.title = name; | 46 window.document.title = name; |
| 47 } else { | 47 } else { |
| 48 window.document.title = 'main guest'; | 48 window.document.title = 'main guest'; |
| 49 } | 49 } |
| 50 } | 50 } |
| 51 } | 51 } |
| 52 | 52 |
| 53 var plugin = document.getElementById('plugin'); | 53 var plugin = document.getElementById('plugin'); |
| 54 window.addEventListener('message', receiveMessage, false); | 54 window.addEventListener('message', receiveMessage, false); |
| 55 plugin.addEventListener('-internal-instanceid-allocated', function(e) { | 55 plugin.addEventListener('-internal-instanceid-allocated', function(e) { |
| 56 plugin['-internal-attach']({}); | 56 var detail = e.detail ? JSON.parse(e.detail) : {}; |
| 57 plugin['-internal-attach'](detail.windowId, {}); |
| 57 }); | 58 }); |
| 58 </script> | 59 </script> |
| OLD | NEW |