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

Unified Diff: chrome/test/data/extensions/api_test/messaging/connect/frame.js

Issue 1413543005: Use FrameTreeNode ID as frameId in extension APIs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: s/:/ / Created 4 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: chrome/test/data/extensions/api_test/messaging/connect/frame.js
diff --git a/chrome/test/data/extensions/api_test/messaging/connect/frame.js b/chrome/test/data/extensions/api_test/messaging/connect/frame.js
index b7a3c4fb1747dc0f0bda3aa77a10234377f84723..a6f9df1c31e4a9432ed68d92de9aed616e49dec9 100644
--- a/chrome/test/data/extensions/api_test/messaging/connect/frame.js
+++ b/chrome/test/data/extensions/api_test/messaging/connect/frame.js
@@ -9,9 +9,16 @@ chrome.runtime.onConnect.addListener(function(port) {
// This number is used in test.js to identify messages from this frame.
var test_id = location.search.slice(-1);
port.postMessage('from_' + test_id);
+ } else if (msg.testConnectChildFrameAndNavigate) {
+ location.search = '?testConnectChildFrameAndNavigateDone';
}
});
});
// continuation of testSendMessageFromFrame()
-chrome.runtime.sendMessage({frameUrl: location.href});
+if (location.search.lastIndexOf('?testSendMessageFromFrame', 0) === 0) {
+ chrome.runtime.sendMessage({frameUrl: location.href});
+} else if (location.search === '?testConnectChildFrameAndNavigateSetup') {
+ // continuation of connectChildFrameAndNavigate() 1/2
+ chrome.runtime.sendMessage('testConnectChildFrameAndNavigateSetupDone');
+}

Powered by Google App Engine
This is Rietveld 408576698