diff options
author | mpcomplete@google.com <mpcomplete@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-12 22:18:18 +0000 |
---|---|---|
committer | mpcomplete@google.com <mpcomplete@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-11-12 22:18:18 +0000 |
commit | 937e4c7b4b4744353ea2dc6d01749146664e3e76 (patch) | |
tree | 65cbce58cbad33d3b380f071f1f29840ed2c0f83 /chrome/test/data/npapi | |
parent | 13a8adfee148682b7f9489e34c428b37f465675d (diff) | |
download | chromium_src-937e4c7b4b4744353ea2dc6d01749146664e3e76.zip chromium_src-937e4c7b4b4744353ea2dc6d01749146664e3e76.tar.gz chromium_src-937e4c7b4b4744353ea2dc6d01749146664e3e76.tar.bz2 |
Fix http://code.google.com/p/chromium/issues/detail?id=4270. Test case added.
BUG=4270
Review URL: http://codereview.chromium.org/10620
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@5310 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/test/data/npapi')
-rw-r--r-- | chrome/test/data/npapi/self_delete_plugin_invoke_alert.html | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/chrome/test/data/npapi/self_delete_plugin_invoke_alert.html b/chrome/test/data/npapi/self_delete_plugin_invoke_alert.html new file mode 100644 index 0000000..e056cf5 --- /dev/null +++ b/chrome/test/data/npapi/self_delete_plugin_invoke_alert.html @@ -0,0 +1,43 @@ +<html> +<head> +<title>Self Deleting Plugin Test - Invoke</title> +<script src="npapi.js"></script> +<script> +function DeletePluginWithinScript() { + var plugin_div = document.getElementById("PluginDiv"); + plugin_div.innerHTML = "Object Deleted"; + alert('plugin deleted'); +} +function SuccessCallback() { + onSuccess("self_delete_plugin_invoke_alert", 1); +} +function TimeoutCallback() { + var plg = window.document["plg"]; + var plg2 = window.document["plg2"]; + plg.testCallbackAndGetValue("DeletePluginWithinScript"); + plg2.testCallback("SuccessCallback"); // will fail if the plugin crashed +} +</script> +</head> + +<body> + +<h2>Test to delete a plugin during script execution</h2> + +<p> +This test is for a corner case when a plugin executes a script +that deletes the invoking plugin itself then shows a modal dialog. +See http://code.google.com/p/chromium/issues/detail?id=4270. +</p> + +<DIV ID=PluginDiv> +<embed name="plg" type="application/x-webkit-test-netscape"></embed> +</DIV> +<embed name="plg2" type="application/x-webkit-test-netscape"></embed> +<script> + setTimeout('TimeoutCallback()', 0); +</script> + +</body> +</html> + |