summaryrefslogtreecommitdiffstats
path: root/chrome_frame/test/data
diff options
context:
space:
mode:
authorananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-06-07 21:40:29 +0000
committerananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-06-07 21:40:29 +0000
commite16dd167e26e02de97b9f3fdc88f2e50814cee6b (patch)
treeb6bb2e60f47119849886e6e31cc63d55fe0b6f27 /chrome_frame/test/data
parentcfa8f06de2c4aae71ce39b67056d6bb85c00de74 (diff)
downloadchromium_src-e16dd167e26e02de97b9f3fdc88f2e50814cee6b.zip
chromium_src-e16dd167e26e02de97b9f3fdc88f2e50814cee6b.tar.gz
chromium_src-e16dd167e26e02de97b9f3fdc88f2e50814cee6b.tar.bz2
Add Support for window.close in ChromeFrame. Currently the CloseContents notification on the TabContentsDelegate which
the ExternalTabContainer implements is ignored if the window close is not initiated from the host. Fix is to send over an automation message AutomationMsg_CloseExternalTab to the external host where we close the window. Currently this functionality is only provided by the active document. Fixes bug http://code.google.com/p/chromium/issues/detail?id=45930 Bug=45930 Test=Covered by chrome frame unit test FullTabModeIE_WindowCloseInChrome Review URL: http://codereview.chromium.org/2691004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@49093 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame/test/data')
-rw-r--r--chrome_frame/test/data/chrome_frame_window_open.html18
1 files changed, 15 insertions, 3 deletions
diff --git a/chrome_frame/test/data/chrome_frame_window_open.html b/chrome_frame/test/data/chrome_frame_window_open.html
index e7194cf..cf96a9e 100644
--- a/chrome_frame/test/data/chrome_frame_window_open.html
+++ b/chrome_frame/test/data/chrome_frame_window_open.html
@@ -15,14 +15,26 @@ function onLoad() {
}
}
+var new_window;
+
function OpenPopup() {
- window.open("chrome_frame_window_open_popup.html", "mywindow",
- "left=10, top=10, height=100, width=100");
+ new_window = window.open("chrome_frame_window_open_popup.html", "mywindow",
+ "left=10, top=10, height=100, width=100");
}
+
+function OnKeyPress() {
+ var char_code = String.fromCharCode(event.keyCode);
+ if (char_code == 'O') {
+ OpenPopup();
+ } else if (char_code == 'C') {
+ new_window.close();
+ }
+}
+
</script>
</head>
-<body onload="onLoad();" onkeypress="OpenPopup();">
+<body onload="onLoad();" onkeypress="OnKeyPress();">
<div id="statusPanel" style="border: 1px solid red; width: 100%">
ChromeFrame full tab mode window open test running....
</div>