Skip to content

Commit

Permalink
Re-enable legacy WebView plug-ins (but not NPAPI)
Browse files Browse the repository at this point in the history
https://bugs.webkit.org/show_bug.cgi?id=226890
<rdar://79075349>

Reviewed by Tim Horton.

In r276720 I put the check in the wrong place.
This should also fix rdar://77179042 again, which I broke, fixed, broke, and am now fixing again.

* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::createPlugin):



Canonical link: https://commits.webkit.org/238683@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@278715 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
achristensen07 committed Jun 10, 2021
1 parent 3b14a3d commit 48b3154
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
14 changes: 14 additions & 0 deletions Source/WebKitLegacy/mac/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
2021-06-10 Alex Christensen <achristensen@webkit.org>

Re-enable legacy WebView plug-ins (but not NPAPI)
https://bugs.webkit.org/show_bug.cgi?id=226890
<rdar://79075349>

Reviewed by Tim Horton.

In r276720 I put the check in the wrong place.
This should also fix rdar://77179042 again, which I broke, fixed, broke, and am now fixing again.

* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::createPlugin):

2021-06-08 Devin Rousso <drousso@apple.com>

[Payment Request] upstream new features
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1935,11 +1935,11 @@ static bool shouldBlockPlugin(WebBasePluginPackage *pluginPackage)
errorCode = WebKitErrorBlockedPlugInVersion;
if (is<WebCore::RenderEmbeddedObject>(element.renderer()))
downcast<WebCore::RenderEmbeddedObject>(*element.renderer()).setPluginUnavailabilityReason(WebCore::RenderEmbeddedObject::InsecurePluginVersion);
} else if ([webView.preferences _boolValueForKey:@"WebKitNPAPIPlugInsEnabledForTestingInWebKitLegacy"]) {
} else {
if ([pluginPackage isKindOfClass:[WebPluginPackage class]])
view = pluginView(m_webFrame.get(), (WebPluginPackage *)pluginPackage, attributeKeys.get(), createNSArray(paramValues).get(), baseURL, kit(&element), loadManually);
#if ENABLE(NETSCAPE_PLUGIN_API)
else if ([pluginPackage isKindOfClass:[WebNetscapePluginPackage class]]) {
else if ([pluginPackage isKindOfClass:[WebNetscapePluginPackage class]] && [webView.preferences _boolValueForKey:@"WebKitNPAPIPlugInsEnabledForTestingInWebKitLegacy"]) {
auto pluginView = adoptNS([[NETSCAPE_PLUGIN_VIEW alloc]
initWithFrame:NSMakeRect(0, 0, size.width(), size.height())
pluginPackage:(WebNetscapePluginPackage *)pluginPackage
Expand Down

0 comments on commit 48b3154

Please sign in to comment.