Commit 12ff6f52 authored by darin@apple.com's avatar darin@apple.com

WebKit/mac:

2009-06-20  Darin Adler  <darin@apple.com>

        Reviewed by Sam Weinig.

        <rdar://problem/6964221> Need more processing of pluginspage.

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

WebKit/win:

2009-06-20  Darin Adler  <darin@apple.com>

        Reviewed by Sam Weinig.

        <rdar://problem/6964221> Need more processing of pluginspage.

        * WebCoreSupport/WebFrameLoaderClient.cpp:
        (WebFrameLoaderClient::createPlugin): Check protocolInHTTPFamily.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@44905 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 8344d832
2009-06-20 Darin Adler <darin@apple.com>
Reviewed by Sam Weinig.
<rdar://problem/6964221> Need more processing of pluginspage.
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::createPlugin): Check protocolInHTTPFamily.
2009-06-18 Adam Barth <abarth@webkit.org>
Reviewed by Sam Weinig.
......
......@@ -1490,11 +1490,11 @@ Widget* WebFrameLoaderClient::createPlugin(const IntSize& size, HTMLPlugInElemen
errorCode = WebKitErrorCannotLoadPlugIn;
if (errorCode) {
KURL pluginPageURL = document->completeURL(parseURL(parameterValue(paramNames, paramValues, "pluginspage")));
if (!pluginPageURL.protocolInHTTPFamily())
pluginPageURL = KURL();
NSError *error = [[NSError alloc] _initWithPluginErrorCode:errorCode
contentURL:URL
pluginPageURL:document->completeURL(parseURL(parameterValue(paramNames, paramValues, "pluginspage")))
pluginName:[pluginPackage name]
MIMEType:MIMEType];
contentURL:URL pluginPageURL:pluginPageURL pluginName:[pluginPackage name] MIMEType:MIMEType];
WebNullPluginView *nullView = [[[WebNullPluginView alloc] initWithFrame:NSMakeRect(0, 0, size.width(), size.height())
error:error DOMElement:kit(element)] autorelease];
view = nullView;
......
2009-06-20 Darin Adler <darin@apple.com>
Reviewed by Sam Weinig.
<rdar://problem/6964221> Need more processing of pluginspage.
* WebCoreSupport/WebFrameLoaderClient.cpp:
(WebFrameLoaderClient::createPlugin): Check protocolInHTTPFamily.
2009-06-19 Kenneth Rohde Christiansen <kenneth.christiansen@openbossa.org>
Reviewed by Steve Falkenburg.
......
......@@ -666,12 +666,15 @@ Widget* WebFrameLoaderClient::createPlugin(const IntSize& pluginSize, HTMLPlugIn
RetainPtr<CFMutableDictionaryRef> userInfo(AdoptCF, CFDictionaryCreateMutable(0, 0, &kCFTypeDictionaryKeyCallBacks, &kCFTypeDictionaryValueCallBacks));
unsigned count = (unsigned)paramNames.size();
for (unsigned i = 0; i < count; i++) {
size_t size = paramNames.size();
for (size_t i = 0; i < size; i++) {
if (paramNames[i] == "pluginspage") {
static CFStringRef key = MarshallingHelpers::LPCOLESTRToCFStringRef(WebKitErrorPlugInPageURLStringKey);
RetainPtr<CFStringRef> str(AdoptCF, paramValues[i].createCFString());
CFDictionarySetValue(userInfo.get(), key, str.get());
KURL pluginPageURL = document->completeURL(parseURL(paramValues[i]));
if (pluginPageURL.protocolInHTTPFamily()) {
static CFStringRef key = MarshallingHelpers::LPCOLESTRToCFStringRef(WebKitErrorPlugInPageURLStringKey);
RetainPtr<CFStringRef> str(AdoptCF, pluginPageURL.string().createCFString());
CFDictionarySetValue(userInfo.get(), key, str.get());
}
break;
}
}
......@@ -683,13 +686,13 @@ Widget* WebFrameLoaderClient::createPlugin(const IntSize& pluginSize, HTMLPlugIn
CFDictionarySetValue(userInfo.get(), key, str.get());
}
String pluginName;
if (pluginView->plugin())
pluginName = pluginView->plugin()->name();
if (!pluginName.isNull()) {
static CFStringRef key = MarshallingHelpers::LPCOLESTRToCFStringRef(WebKitErrorPlugInNameKey);
RetainPtr<CFStringRef> str(AdoptCF, pluginName.createCFString());
CFDictionarySetValue(userInfo.get(), key, str.get());
if (pluginView->plugin()) {
String pluginName = pluginView->plugin()->name();
if (!pluginName.isNull()) {
static CFStringRef key = MarshallingHelpers::LPCOLESTRToCFStringRef(WebKitErrorPlugInNameKey);
RetainPtr<CFStringRef> str(AdoptCF, pluginName.createCFString());
CFDictionarySetValue(userInfo.get(), key, str.get());
}
}
COMPtr<CFDictionaryPropertyBag> userInfoBag(AdoptCOM, CFDictionaryPropertyBag::createInstance());
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment