2018-05-12 14:50:54 +02:00
|
|
|
program SimpleLazarusBrowser;
|
|
|
|
|
|
|
|
{$mode objfpc}{$H+}
|
|
|
|
|
|
|
|
uses
|
|
|
|
{$IFDEF UNIX}{$IFDEF UseCThreads}
|
|
|
|
cthreads,
|
|
|
|
{$ENDIF}{$ENDIF}
|
|
|
|
Interfaces, // this includes the LCL widgetset
|
2018-05-24 19:15:41 +02:00
|
|
|
Forms, uSimpleLazarusBrowser,
|
2018-05-12 14:50:54 +02:00
|
|
|
{ you can add units after this }
|
2018-05-24 19:15:41 +02:00
|
|
|
uCEFApplication;
|
2018-05-12 14:50:54 +02:00
|
|
|
|
|
|
|
{$R *.res}
|
|
|
|
|
2018-05-24 19:15:41 +02:00
|
|
|
{$IFDEF MSWINDOWS}
|
|
|
|
// CEF3 needs to set the LARGEADDRESSAWARE flag which allows 32-bit processes to use up to 3GB of RAM.
|
|
|
|
{$SetPEFlags $20}
|
|
|
|
{$ENDIF}
|
|
|
|
|
2018-05-12 14:50:54 +02:00
|
|
|
begin
|
|
|
|
GlobalCEFApp := TCefApplication.Create;
|
|
|
|
|
|
|
|
if GlobalCEFApp.StartMainProcess then
|
|
|
|
begin
|
|
|
|
RequireDerivedFormResource:=True;
|
|
|
|
Application.Initialize;
|
|
|
|
Application.CreateForm(TForm1, Form1);
|
|
|
|
Application.Run;
|
|
|
|
end;
|
|
|
|
|
2018-05-24 19:15:41 +02:00
|
|
|
GlobalCEFApp.Free;
|
|
|
|
GlobalCEFApp := nil;
|
2018-05-12 14:50:54 +02:00
|
|
|
end.
|
|
|
|
|