Bug 101305

Summary: Refactoring WebPageProxy::canShowMIMEType() for finding plugins
Product: WebKit Reporter: KwangYong Choi <ky0.choi>
Component: Plug-insAssignee: KwangYong Choi <ky0.choi>
Status: RESOLVED INVALID    
Severity: Normal CC: andersca, ap, beidson, cgarcia, gyuyoung.kim, thorton
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch none

Description KwangYong Choi 2012-11-05 22:30:29 PST
It's not required to find plugins when the plugin is disabled.
Comment 1 KwangYong Choi 2012-11-05 22:32:55 PST
Created attachment 172489 [details]
Patch
Comment 2 Alexey Proskuryakov 2012-11-06 10:11:34 PST
I'm not sure if this is the right direction - we may want to always use Built-in PDF plug-in, even when external ones are disabled. Tim?
Comment 3 Tim Horton 2012-11-06 11:48:57 PST
(In reply to comment #2)
> I'm not sure if this is the right direction - we may want to always use Built-in PDF plug-in, even when external ones are disabled. Tim?

Yeah, we're definitely going to want the ability to use the Built-in PDF Plug-in even when "plug-ins" are disabled. It's not really a plugin, it's just using that infrastructure.
Comment 4 KwangYong Choi 2012-11-08 16:38:42 PST
(In reply to comment #3)
> (In reply to comment #2)
> > I'm not sure if this is the right direction - we may want to always use Built-in PDF plug-in, even when external ones are disabled. Tim?
> 
> Yeah, we're definitely going to want the ability to use the Built-in PDF Plug-in even when "plug-ins" are disabled. It's not really a plugin, it's just using that infrastructure.

Basically, this patch does not change the behavior of main resource loading. The behavior is changed by bug 99449.

For the application/pdf type, safari on Mac always shows PDF document in the browser even though plugins are disabled.
Comment 5 Tim Horton 2012-11-08 16:44:35 PST
(In reply to comment #4)
> (In reply to comment #3)
> > (In reply to comment #2)
> > > I'm not sure if this is the right direction - we may want to always use Built-in PDF plug-in, even when external ones are disabled. Tim?
> > 
> > Yeah, we're definitely going to want the ability to use the Built-in PDF Plug-in even when "plug-ins" are disabled. It's not really a plugin, it's just using that infrastructure.
> 
> Basically, this patch does not change the behavior of main resource loading. The behavior is changed by bug 99449.
> 
> For the application/pdf type, safari on Mac always shows PDF document in the browser even though plugins are disabled.

This may be true by default, however, the ENABLE_PDFKIT_PLUGIN flag makes WebKit use PDFPlugin in the main-frame case.
Comment 6 KwangYong Choi 2013-01-10 17:06:57 PST
I will check it later.
Comment 7 Anders Carlsson 2013-01-14 11:01:34 PST
Another note: We actually want to get rid of WebPageProxy::canShowMIMEType since it can potentially do sync IO on the main thread when loading the plug-in store.