Commit 9c12fc11 authored by mitz@apple.com's avatar mitz@apple.com
Browse files

Fix a mistake in the previous change

Reviewed by Mark Rowe.

* WebView/WebView.mm:
(+[WebView _viewClass:andRepresentationClass:forMIMEType:allowingPlugins:]):
Make sure to include the image types’ view and representation classes
even when plug-ins are not allowed.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@51620 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 7b505abe
2009-12-02 Dan Bernstein <mitz@apple.com>
Reviewed by Mark Rowe.
Fix a mistake in the previous change
* WebView/WebView.mm:
(+[WebView _viewClass:andRepresentationClass:forMIMEType:allowingPlugins:]):
Make sure to include the image types’ view and representation classes
even when plug-ins are not allowed.
2009-12-02 Dan Bernstein <mitz@apple.com>
 
Reviewed by Anders Carlsson.
......
......@@ -827,12 +827,15 @@ static bool runningTigerMail()
MIMEType = [MIMEType lowercaseString];
Class viewClass = [[WebFrameView _viewTypesAllowImageTypeOmission:YES] _webkit_objectForMIMEType:MIMEType];
Class repClass = [[WebDataSource _repTypesAllowImageTypeOmission:YES] _webkit_objectForMIMEType:MIMEType];
if (allowPlugins && (!viewClass || !repClass || [[WebPDFView supportedMIMETypes] containsObject:MIMEType])) {
if (!viewClass || !repClass || [[WebPDFView supportedMIMETypes] containsObject:MIMEType]) {
// Our optimization to avoid loading the plug-in DB and image types for the HTML case failed.
// Load the plug-in DB allowing plug-ins to install types.
[WebPluginDatabase sharedDatabase];
if (allowPlugins) {
// Load the plug-in DB allowing plug-ins to install types.
[WebPluginDatabase sharedDatabase];
}
// Load the image types and get the view class and rep class. This should be the fullest picture of all handled types.
viewClass = [[WebFrameView _viewTypesAllowImageTypeOmission:NO] _webkit_objectForMIMEType:MIMEType];
repClass = [[WebDataSource _repTypesAllowImageTypeOmission:NO] _webkit_objectForMIMEType:MIMEType];
......
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