OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 // The test extension for externally_connectable just echos all messages it | |
6 // gets. The test runners are in the sites/ directory. | |
7 | |
8 chrome.runtime.onMessageExternal.addListener(function(message, sender, reply) { | |
9 reply(message); | |
10 }); | |
11 | |
12 chrome.runtime.onConnectExternal.addListener(function(port) { | |
Jeffrey Yasskin
2013/06/08 00:28:09
Both of these tests should include some mention of
not at google - send to devlin
2013/06/08 02:02:33
Ah. Very good point. WDYT now.
| |
13 port.onMessage.addListener(function(message) { | |
14 port.postMessage(message); | |
15 }); | |
16 }); | |
OLD | NEW |