i've created an Application based on VCL, which has many Windows-Dialogs and implements a WebPage over CEF4Delphi when you click on one Menu entry.
At the beginning my DPR contains the following code to Raise up CEF
Code: Select all
GlobalCEFApp := TCefApplicationCore.Create;
GlobalCEFApp.FrameworkDirPath := 'CEF4Runtime';
GlobalCEFApp.ResourcesDirPath := 'CEF4Runtime';
GlobalCEFApp.LocalesDirPath := 'CEF4Runtime';
GlobalCEFApp.FlashEnabled := False;
GlobalCEFApp.EnablePrintPreview := True;
GlobalCEFApp.EnableGPU := True;
GlobalCEFApp.SitePerProcess := False;
GlobalCEFApp.EnableMediaStream := False;
GlobalCEFApp.EnableSpeechInput := False;
GlobalCEFApp.EnableHighDPISupport := False;
GlobalCEFApp.DisableSpellChecking := True;
GlobalCEFApp.AddCustomCommandLine('--force-device-scale-factor', '0.8');
GlobalCEFApp.BrowserSubprocessPath := 'CEF4Runtime\MyBrowser.exe';
try
if not GlobalCEFApp.StartMainProcess then
begin
Exit;
end;
finally
GlobalCEFApp.Destroy;
GlobalCEFApp := nil;
end;
My MyBroser.exe is actually a empty exe with NO SourceCode.
I also tried to put the sourcecode above to an seerate unit, as shown in the SubProcess-Demo and put it also to the MyBrowser.exe.
But the behaviour is the same.
Can anyone tell me what's wrong ?