[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.1.90-6072-g9a69373
yael.aharon at nokia.com
yael.aharon at nokia.com
Wed Apr 7 23:52:38 UTC 2010
The following commit has been merged in the webkit-1.2 branch:
commit d9ea6b7ea127732ade581e2053c9942cbda537d2
Author: yael.aharon at nokia.com <yael.aharon at nokia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Fri Nov 20 21:40:38 2009 +0000
NPN_ReloadPlugins does not reload the page even if reloadPages is true.
https://bugs.webkit.org/show_bug.cgi?id=30460
Reviewed by Kenneth Rohde Christiansen.
WebCore:
Replace call to PluginDatabase::installedPlugins()->refresh() with Page::refreshPlugins().
It already refreshes plugins and reloads pages when necessary.
Tests: plugins/reloadplugins-and-pages.html
plugins/reloadplugins-no-pages.html
* plugins/PluginInfoStore.cpp:
(WebCore::refreshPlugins):
WebKitTools:
Added code for calling NPN_ReloadPlugins with reloadPages true and false.
* DumpRenderTree/TestNetscapePlugIn.subproj/PluginObject.cpp:
(pluginInvoke):
LayoutTests:
Added tests for calling NPN_ReloadPlugins with reloadPages being true and false.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@51257 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 69c91f5..cea03b4 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,19 @@
+2009-11-20 Yael Aharon <yael.aharon at nokia.com>
+
+ Reviewed by Kenneth Rohde Christiansen.
+
+ NPN_ReloadPlugins does not reload the page even if reloadPages is true.
+ https://bugs.webkit.org/show_bug.cgi?id=30460
+
+ Added tests for calling NPN_ReloadPlugins with reloadPages being true and false.
+
+ * platform/mac/Skipped:
+ * platform/win/Skipped:
+ * plugins/reloadplugins-and-pages-expected.txt: Added.
+ * plugins/reloadplugins-and-pages.html: Added.
+ * plugins/reloadplugins-no-pages-expected.txt: Added.
+ * plugins/reloadplugins-no-pages.html: Added.
+
2009-11-20 Alexey Proskuryakov <ap at apple.com>
Reviewed by Darin Adler.
diff --git a/LayoutTests/platform/mac/Skipped b/LayoutTests/platform/mac/Skipped
index 73a4436..b4d911b 100644
--- a/LayoutTests/platform/mac/Skipped
+++ b/LayoutTests/platform/mac/Skipped
@@ -101,3 +101,8 @@ accessibility/document-attributes.html
# Need to add functionality to DumpRenderTree to handle error pages
fast/history/back-forward-reset-after-error-handling.html
+
+# Need to implement this in plugins code in WebKit
+plugins/reloadPlugins-and-pages.html
+plugins/reloadPlugins-no-pages.html
+
diff --git a/LayoutTests/platform/win/Skipped b/LayoutTests/platform/win/Skipped
index a6abba9..a623390 100644
--- a/LayoutTests/platform/win/Skipped
+++ b/LayoutTests/platform/win/Skipped
@@ -706,3 +706,7 @@ websocket
# validationMessage: https://bugs.webkit.org/show_bug.cgi?id=27959
fast/forms/validationMessage.html
+
+# Need to implement this in plugins code in WebKit
+plugins/reloadPlugins-and-pages.html
+plugins/reloadPlugins-no-pages.html
diff --git a/LayoutTests/plugins/reloadplugins-and-pages-expected.txt b/LayoutTests/plugins/reloadplugins-and-pages-expected.txt
new file mode 100644
index 0000000..60f2c9d
--- /dev/null
+++ b/LayoutTests/plugins/reloadplugins-and-pages-expected.txt
@@ -0,0 +1,6 @@
+ALERT: Page was loaded
+ALERT: Page was loaded
+
+Test for NPN_RelaodPlugin in which reloadOpenPages is true. You should see two alerts, indicating that the page was loaded twice.
+
+SUCCESS
diff --git a/LayoutTests/plugins/reloadplugins-and-pages.html b/LayoutTests/plugins/reloadplugins-and-pages.html
new file mode 100644
index 0000000..dbca798
--- /dev/null
+++ b/LayoutTests/plugins/reloadplugins-and-pages.html
@@ -0,0 +1,35 @@
+<html>
+<body>
+<embed id="plg" type="application/x-webkit-test-netscape"></embed>
+<p>Test for NPN_RelaodPlugin in which reloadOpenPages is true. You should see two alerts, indicating that the page was loaded twice.</p>
+<div id='res'>FAILURE</div>
+<script>
+ alert("Page was loaded");
+ callReload = true;
+ if (window.sessionStorage) {
+ if (window.sessionStorage.reloadPluginsAndPagesCalled) {
+ callReload = false;
+ } else {
+ window.sessionStorage.reloadPluginsAndPagesCalled = 1;
+ }
+ }
+
+ if (window.layoutTestController)
+ layoutTestController.dumpAsText();
+
+ if (callReload) {
+ try {
+ if (window.layoutTestController)
+ layoutTestController.waitUntilDone();
+ document.getElementById('plg').reloadPluginsAndPages();
+ } catch (ex) {
+ alert("Exception: " + ex.description + ". Test plugin was not found");
+ }
+ } else {
+ document.getElementById('res').innerHTML="SUCCESS";
+ if (window.layoutTestController)
+ layoutTestController.notifyDone();
+ }
+</script>
+</body>
+</html>
diff --git a/LayoutTests/plugins/reloadplugins-no-pages-expected.txt b/LayoutTests/plugins/reloadplugins-no-pages-expected.txt
new file mode 100644
index 0000000..243c904
--- /dev/null
+++ b/LayoutTests/plugins/reloadplugins-no-pages-expected.txt
@@ -0,0 +1,5 @@
+ALERT: Page was loaded
+
+Test for NPN_RelaodPlugin in which reloadOpenPages is false. You should see one alert, indicating that the page was loaded once.
+
+SUCCESS
diff --git a/LayoutTests/plugins/reloadplugins-no-pages.html b/LayoutTests/plugins/reloadplugins-no-pages.html
new file mode 100644
index 0000000..7ae5204
--- /dev/null
+++ b/LayoutTests/plugins/reloadplugins-no-pages.html
@@ -0,0 +1,19 @@
+<html>
+<body>
+<embed name="plg" type="application/x-webkit-test-netscape"></embed>
+<p>Test for NPN_RelaodPlugin in which reloadOpenPages is false. You should see one alert, indicating that the page was loaded once.</p>
+<div id='res'>FAILURE</div>
+<script>
+ alert("Page was loaded");
+ if (window.layoutTestController)
+ layoutTestController.dumpAsText();
+
+ try {
+ plg.reloadPluginsNoPages();
+ document.getElementById('res').innerHTML='SUCCESS';
+ } catch (ex) {
+ alert("Exception: " + ex.description + ". Test plugin was not found");
+ }
+</script>
+</body>
+</html>
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 8064b55..f9d88ea 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,19 @@
+2009-11-20 Yael Aharon <yael.aharon at nokia.com>
+
+ Reviewed by Kenneth Rohde Christiansen.
+
+ NPN_ReloadPlugins does not reload the page even if reloadPages is true.
+ https://bugs.webkit.org/show_bug.cgi?id=30460
+
+ Replace call to PluginDatabase::installedPlugins()->refresh() with Page::refreshPlugins().
+ It already refreshes plugins and reloads pages when necessary.
+
+ Tests: plugins/reloadplugins-and-pages.html
+ plugins/reloadplugins-no-pages.html
+
+ * plugins/PluginInfoStore.cpp:
+ (WebCore::refreshPlugins):
+
2009-11-20 Oliver Hunt <oliver at apple.com>
Reviewed by Dave Hyatt.
diff --git a/WebCore/plugins/PluginInfoStore.cpp b/WebCore/plugins/PluginInfoStore.cpp
index 732a1e1..88dc7ee 100644
--- a/WebCore/plugins/PluginInfoStore.cpp
+++ b/WebCore/plugins/PluginInfoStore.cpp
@@ -27,6 +27,7 @@
#include "PluginInfoStore.h"
#include "KURL.h"
+#include "Page.h"
#include "PluginData.h"
#include "PluginDatabase.h"
#include "PluginPackage.h"
@@ -93,11 +94,7 @@ bool PluginInfoStore::supportsMIMEType(const WebCore::String& mimeType)
void refreshPlugins(bool reloadOpenPages)
{
- PluginDatabase::installedPlugins()->refresh();
-
- if (reloadOpenPages) {
- // FIXME: reload open pages
- }
+ Page::refreshPlugins(reloadOpenPages);
}
}
diff --git a/WebKitTools/ChangeLog b/WebKitTools/ChangeLog
index 384a8d9..bd569da 100644
--- a/WebKitTools/ChangeLog
+++ b/WebKitTools/ChangeLog
@@ -1,3 +1,15 @@
+2009-11-20 Yael Aharon <yael.aharon at nokia.com>
+
+ Reviewed by Kenneth Rohde Christiansen.
+
+ NPN_ReloadPlugins does not reload the page even if reloadPages is true.
+ https://bugs.webkit.org/show_bug.cgi?id=30460
+
+ Added code for calling NPN_ReloadPlugins with reloadPages true and false.
+
+ * DumpRenderTree/TestNetscapePlugIn.subproj/PluginObject.cpp:
+ (pluginInvoke):
+
2009-11-20 Adam Barth <abarth at webkit.org>
Reviewed by Eric Seidel.
diff --git a/WebKitTools/DumpRenderTree/TestNetscapePlugIn.subproj/PluginObject.cpp b/WebKitTools/DumpRenderTree/TestNetscapePlugIn.subproj/PluginObject.cpp
index 610c4fb..fa8aed1 100644
--- a/WebKitTools/DumpRenderTree/TestNetscapePlugIn.subproj/PluginObject.cpp
+++ b/WebKitTools/DumpRenderTree/TestNetscapePlugIn.subproj/PluginObject.cpp
@@ -170,6 +170,8 @@ enum {
ID_TEST_THROW_EXCEPTION_METHOD,
ID_TEST_FAIL_METHOD,
ID_DESTROY_NULL_STREAM,
+ ID_TEST_RELOAD_PLUGINS_NO_PAGES,
+ ID_TEST_RELOAD_PLUGINS_AND_PAGES,
NUM_METHOD_IDENTIFIERS
};
@@ -195,7 +197,9 @@ static const NPUTF8 *pluginMethodIdentifierNames[NUM_METHOD_IDENTIFIERS] = {
"testConstruct",
"testThrowException",
"testFail",
- "destroyNullStream"
+ "destroyNullStream",
+ "reloadPluginsNoPages",
+ "reloadPluginsAndPages"
};
static NPUTF8* createCStringFromNPVariant(const NPVariant* variant)
@@ -779,6 +783,13 @@ static bool pluginInvoke(NPObject* header, NPIdentifier name, const NPVariant* a
browser->invoke(plugin->npp, windowScriptObject, name, args, argCount, result);
} else if (name == pluginMethodIdentifiers[ID_DESTROY_NULL_STREAM])
return destroyNullStream(plugin, args, argCount, result);
+ else if (name == pluginMethodIdentifiers[ID_TEST_RELOAD_PLUGINS_NO_PAGES]) {
+ browser->reloadplugins(false);
+ return true;
+ } else if (name == pluginMethodIdentifiers[ID_TEST_RELOAD_PLUGINS_AND_PAGES]) {
+ browser->reloadplugins(true);
+ return true;
+ }
return false;
}
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list