The component is called
CEF4Delphi. There is also a component called
fpCEF3 (
https://wiki.lazarus.freepascal.org/fpCEF3 ), but it is no longer maintained.
The files you mention are only needed for the application to run. Lazarus does not require them after installing the
CEF4Delphi component.
Simple instructions for working with CEF4Delphi (apply changes in the main application file - *.lpr):
1. Before launching the application, you must create
CEFApplication:
GlobalCEFApp := TCefApplication.Create;
2. You can define where the CEF binary files needed for operation are located—if you do not specify the paths, the default location is
Application.Location, i.e., the directory with the exe file. Properties to set:
GlobalCEFApp.FrameworkDirPath := 'C:\ProgramData\CEFDateien';
GlobalCEFApp.ResourcesDirPath := GlobalCEFApp.FrameworkDirPath;
GlobalCEFApp.LocalesDirPath := GlobalCEFApp.FrameworkDirPath + '\locales';
2a. You need to copy the required files to the specified location:, the contents of the
Release and
Resources folders. - you will extract them from the archive
Windows 32-bit or
Windows 64-bit- depends on the number of bits in your application.
3. Start the CEF process:
GlobalCEFApp.StartMainProcess
4. at the end, you release CEFApp:
Important: you must include the unit
uCEFApplication in the
uses section.
An example file of the new project after the changes will look as follows:
program Project1;
{$mode objfpc}{$H+}
uses
{$IFDEF UNIX}
cthreads,
{$ENDIF}
{$IFDEF HASAMIGA}
athreads,
{$ENDIF}
Interfaces, // this includes the LCL widgetset
Forms, Unit1
, uCEFApplication
{ you can add units after this };
{$R *.res}
begin
GlobalCEFApp := TCefApplication.Create;
GlobalCEFApp.FrameworkDirPath := 'C:\ProgramData\CEFDateien';
GlobalCEFApp.ResourcesDirPath := GlobalCEFApp.FrameworkDirPath;
GlobalCEFApp.LocalesDirPath := GlobalCEFApp.FrameworkDirPath + '\locales';
if GlobalCEFApp.StartMainProcess then
begin
RequireDerivedFormResource:=True;
Application.Scaled:=True;
{$PUSH}{$WARN 5044 OFF}
Application.MainFormOnTaskbar:=True;
{$POP}
Application.Initialize;
Application.CreateForm(TForm1, Form1);
Application.Run;
end;
DestroyGlobalCEFApp; //free CEF application
end.
Edit: fixed url's to cef binaries