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

Side by Side Diff: chrome/test/data/extensions/uitest/event_sink/test.html

Issue 179027: Make a bunch of backlogged breaking changes to the extensions (Closed)
Patch Set: Put chrome.self back Created 11 years, 3 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
« no previous file with comments | « chrome/test/data/extensions/samples/subscribe_page_action/background.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 HOLA!!! If you dont see the message DONE, then there is an error in the script. 1 HOLA!!! If you dont see the message DONE, then there is an error in the script.
2 <br> 2 <br>
3 3
4 <script type="text/javascript"> 4 <script type="text/javascript">
5 // This extension registers for all tab and window events, and whenever one 5 // This extension registers for all tab and window events, and whenever one
6 // is received, it calls postMessage to send it back to the test automation 6 // is received, it calls postMessage to send it back to the test automation
7 // driver. 7 // driver.
8 8
9 // Wait for the automation server to create a port so that we can communicate 9 // Wait for the automation server to create a port so that we can communicate
10 // back to it. 10 // back to it.
11 var portToAutomation; 11 var portToAutomation;
12 chrome.self.onConnect.addListener(function(port) { 12 chrome.extension.onConnect.addListener(function(port) {
13 portToAutomation = port; 13 portToAutomation = port;
14 portToAutomation.postMessage('ACK'); 14 portToAutomation.postMessage('ACK');
15 }); 15 });
16 16
17 // Window events. 17 // Window events.
18 chrome.windows.onCreated.addListener(function(createInfo) { 18 chrome.windows.onCreated.addListener(function(createInfo) {
19 portToAutomation.postMessage(chrome.windows.onCreated.eventName_); 19 portToAutomation.postMessage(chrome.windows.onCreated.eventName_);
20 }); 20 });
21 chrome.windows.onRemoved.addListener(function(windowId) { 21 chrome.windows.onRemoved.addListener(function(windowId) {
22 portToAutomation.postMessage(chrome.windows.onRemoved.eventName_); 22 portToAutomation.postMessage(chrome.windows.onRemoved.eventName_);
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 portToAutomation.postMessage( 66 portToAutomation.postMessage(
67 chrome.bookmarks.onChildrenReordered.eventName_); 67 chrome.bookmarks.onChildrenReordered.eventName_);
68 }); 68 });
69 69
70 // Call chrome window api. The result of this api is not important, as this 70 // Call chrome window api. The result of this api is not important, as this
71 // is used only to let the automation test driver know that this page is 71 // is used only to let the automation test driver know that this page is
72 // loaded and ready to receive events. 72 // loaded and ready to receive events.
73 chrome.windows.getCurrent(function() {}); 73 chrome.windows.getCurrent(function() {});
74 document.write('DONE'); 74 document.write('DONE');
75 </script> 75 </script>
OLDNEW
« no previous file with comments | « chrome/test/data/extensions/samples/subscribe_page_action/background.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698