summaryrefslogtreecommitdiffstats
path: root/webkit/data/plugins
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-10 05:29:32 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-10 05:29:32 +0000
commitb1c25a2fdeade0e807af70df8136d5efa62033d2 (patch)
tree9ed31642f0e2eb899f6db76b3b33c60f1f0bacb8 /webkit/data/plugins
parente322627c51db7ad243c49d096af20590828a00f9 (diff)
downloadchromium_src-b1c25a2fdeade0e807af70df8136d5efa62033d2.zip
chromium_src-b1c25a2fdeade0e807af70df8136d5efa62033d2.tar.gz
chromium_src-b1c25a2fdeade0e807af70df8136d5efa62033d2.tar.bz2
Fix plugin window sticking around when parent became invisible. Added test for all different scenarios.
Note I grabbed the plugin hwnd and manually checked it instead of looking for callbacks from the plugin's SetWindow since the latter isn't called if the visibility changes. BUG=1842096 TEST=regression test included, test http://chromedashboard per bug Review URL: http://codereview.chromium.org/115169 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15732 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/data/plugins')
-rw-r--r--webkit/data/plugins/hidden_plugin.html2
-rw-r--r--webkit/data/plugins/hidden_plugin_iframe.html14
-rw-r--r--webkit/data/plugins/plugin_visibility.html12
-rw-r--r--webkit/data/plugins/plugin_visibility_iframe.html1
4 files changed, 13 insertions, 16 deletions
diff --git a/webkit/data/plugins/hidden_plugin.html b/webkit/data/plugins/hidden_plugin.html
deleted file mode 100644
index db6b575..0000000
--- a/webkit/data/plugins/hidden_plugin.html
+++ /dev/null
@@ -1,2 +0,0 @@
-<div id='result'>FAIL</div>
-<iframe src='hidden_plugin_iframe.html'></iframe> \ No newline at end of file
diff --git a/webkit/data/plugins/hidden_plugin_iframe.html b/webkit/data/plugins/hidden_plugin_iframe.html
deleted file mode 100644
index ad0a994..0000000
--- a/webkit/data/plugins/hidden_plugin_iframe.html
+++ /dev/null
@@ -1,14 +0,0 @@
-<script>
-var gotVisible = false;
-function windowHidden() {
- if (!gotVisible)
- parent.document.getElementById('result').innerHTML = 'DONE';
-}
-
-function windowVisible() {
- gotVisible = true;
- parent.document.getElementById('result').innerHTML = 'FAIL';
-}
-
-</script>
-<embed style="visibility:hidden" id='1' type='application/vnd.npapi-test' src='foo' name='hidden_plugin'> \ No newline at end of file
diff --git a/webkit/data/plugins/plugin_visibility.html b/webkit/data/plugins/plugin_visibility.html
new file mode 100644
index 0000000..bda8a9d
--- /dev/null
+++ b/webkit/data/plugins/plugin_visibility.html
@@ -0,0 +1,12 @@
+<script>
+function showFrame(show) {
+ frame = document.getElementById("the_iframe");
+ frame.style.visibility = show ? "" : "hidden";
+}
+
+function showPlugin(show) {
+ iframe = document.getElementById("the_iframe").contentDocument;
+ iframe.getElementById("1").style.visibility = show ? "" : "hidden";
+}
+</script>
+<iframe id='the_iframe' src='plugin_visibility_iframe.html'></iframe> \ No newline at end of file
diff --git a/webkit/data/plugins/plugin_visibility_iframe.html b/webkit/data/plugins/plugin_visibility_iframe.html
new file mode 100644
index 0000000..447a8fe
--- /dev/null
+++ b/webkit/data/plugins/plugin_visibility_iframe.html
@@ -0,0 +1 @@
+<embed style="visibility:hidden" id='1' type='application/vnd.npapi-test' src='foo' name='hidden_plugin'> \ No newline at end of file