| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <script src="get-host-info.sub.js"></script> | 2 <script src="/common/get-host-info.sub.js"></script> |
| 3 <script src="test-helpers.sub.js"></script> | 3 <script src="test-helpers.sub.js"></script> |
| 4 <script> | 4 <script> |
| 5 var host_info = get_host_info(); | 5 var host_info = get_host_info(); |
| 6 var SCOPE = 'blank.html?clients-get'; | 6 var SCOPE = 'blank.html?clients-get'; |
| 7 var SCRIPT = 'clients-get-worker.js'; | 7 var SCRIPT = 'clients-get-worker.js'; |
| 8 | 8 |
| 9 var registration; | 9 var registration; |
| 10 var worker; | 10 var worker; |
| 11 var wait_for_worker_promise = navigator.serviceWorker.getRegistration(SCOPE) | 11 var wait_for_worker_promise = navigator.serviceWorker.getRegistration(SCOPE) |
| 12 .then(function(reg) { | 12 .then(function(reg) { |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 send_result(e.data); | 55 send_result(e.data); |
| 56 }); | 56 }); |
| 57 }; | 57 }; |
| 58 iframe.contentWindow.navigator.serviceWorker.controller.postMessage( | 58 iframe.contentWindow.navigator.serviceWorker.controller.postMessage( |
| 59 {port:channel.port2, clientId: otherOriginClientId, | 59 {port:channel.port2, clientId: otherOriginClientId, |
| 60 message: 'get_other_client_id'}, [channel.port2]); | 60 message: 'get_other_client_id'}, [channel.port2]); |
| 61 }) | 61 }) |
| 62 } | 62 } |
| 63 } | 63 } |
| 64 </script> | 64 </script> |
| OLD | NEW |