Disclosure Statement: This site contains affiliate links, which means that I may receive a commission if you make a purchase using these links. As an eBay Partner, I earn from qualifying purchases.
If you find these projects useful please consider becoming a sponsor with Patreon, GitHub or Liberapay.

How To Use NPSWF32.dll and enable npapi in Current 3.3 CEF

Post Reply
crystalxp
Posts: 39
Joined: Tue Jul 04, 2017 8:23 am

How To Use NPSWF32.dll and enable npapi in Current 3.3 CEF

Post by crystalxp »

Use
GlobalCEFApp.AddCustomCommandLine('--enable-npapi','') ;
Can't Effect , What's Wrong With ?
and How to set plugins Dir

Thanks !
User avatar
salvadordf
Posts: 4564
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: How To Use NPSWF32.dll and enable npapi in Current 3.3 CEF

Post by salvadordf »

Hi,

CEF4Delphi has the Flash plugin enabled by default but you have to install the PPAPI plugin as described here :
https://www.briskbard.com/index.php?lang=en&faqitem=208

NPAPI plugins are no longer supported in CEF3.
crystalxp
Posts: 39
Joined: Tue Jul 04, 2017 8:23 am

Re: How To Use NPSWF32.dll and enable npapi in Current 3.3 CEF

Post by crystalxp »

Thanks, Very useful!
Another question ,How to embbeding the ppapi flash(pepflashplayer.dll) in own dir rather than load it from global dir like C:\Windows\SysWOW64\Macromed\Flash
User avatar
salvadordf
Posts: 4564
Joined: Thu Feb 02, 2017 12:24 pm
Location: Spain
Contact:

Re: How To Use NPSWF32.dll and enable npapi in Current 3.3 CEF

Post by salvadordf »

Hi,

I've never tried it but I guess you would have to add

GlobalCEFApp.AddCustomCommandLine('--ppapi-flash-path', YOUR_FULL_FLASH_PLUGIN_PATH);
GlobalCEFApp.AddCustomCommandLine('--ppapi-flash-version', YOUR_FLASH_PLUGIN_VERSION);

before the GlobalCEFApp.StartMainProcess call.

There are several PPAPI command line switches here :
https://peter.sh/experiments/chromium-c ... -switches/

Maybe you would have to set GlobalCEFApp.FlashEnabled to False but as I told you, I've never tried this.
crystalxp
Posts: 39
Joined: Tue Jul 04, 2017 8:23 am

Re: How To Use NPSWF32.dll and enable npapi in Current 3.3 CEF

Post by crystalxp »

thanks , I will try it. :D
crystalxp
Posts: 39
Joined: Tue Jul 04, 2017 8:23 am

Re: How To Use NPSWF32.dll and enable npapi in Current 3.3 CEF

Post by crystalxp »

thanks again..
It's works fine:

GlobalCEFApp.FlashEnabled := False;
GlobalCEFApp.AddCustomCommandLine('--ppapi-flash-path',
ExtractFilePath(Application.ExeName) +
'\plugins\pepflashplayer32.dll');
GlobalCEFApp.AddCustomCommandLine('--ppapi-flash-version', '26.0.0.133');

so the user can view flash without to install ppapi flash
Post Reply