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

Unified Diff: chrome/test/data/extensions/get_app_details_for_frame.html

Issue 10174001: Add an API for hosted apps to check their install and running states. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 8 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/get_app_details_for_frame.html
diff --git a/chrome/test/data/extensions/get_app_details_for_frame.html b/chrome/test/data/extensions/get_app_details_for_frame.html
index 81b4f2a56ed3a883938af42cccba4977ebd850cd..e878d85a8f95c4a2b3935b06d06a7f0e8ead202a 100644
--- a/chrome/test/data/extensions/get_app_details_for_frame.html
+++ b/chrome/test/data/extensions/get_app_details_for_frame.html
@@ -21,7 +21,14 @@ function getFrameURL(host) {
return result;
}
-var iframe = document.createElement("iframe");
-iframe.src = getFrameURL("app.com");
-document.documentElement.appendChild(iframe);
+function newFrame(host) {
+ if (frames.length > 0)
+ document.documentElement.removeChild(document.querySelector('iframe'));
+ var iframe = document.createElement("iframe");
+ iframe.src = getFrameURL(host);
+ document.documentElement.appendChild(iframe);
+}
+
+newFrame('app.com');
+
</script>

Powered by Google App Engine
This is Rietveld 408576698