You've already forked CEF4Delphi
mirror of
https://github.com/salvadordf/CEF4Delphi.git
synced 2025-08-14 21:42:50 +02:00
Update to CEF 92.0.21
Added GlobalCEFApp.DisablePopupBlocking Added GlobalCEFApp.DisableBackForwardCache Fixed issue #372 TCefApplicationCore code reorganization
This commit is contained in:
16
README.md
16
README.md
@@ -3,16 +3,16 @@ CEF4Delphi is an open source project created by Salvador Díaz Fau to embed Chro
|
|||||||
|
|
||||||
CEF4Delphi is based on DCEF3 and fpCEF3. The original license of those projects still applies to CEF4Delphi. Read the license terms in the first lines of any *.pas file.
|
CEF4Delphi is based on DCEF3 and fpCEF3. The original license of those projects still applies to CEF4Delphi. Read the license terms in the first lines of any *.pas file.
|
||||||
|
|
||||||
CEF4Delphi uses CEF 92.0.20 which includes Chromium 92.0.4515.107.
|
CEF4Delphi uses CEF 92.0.21 which includes Chromium 92.0.4515.107.
|
||||||
|
|
||||||
The CEF binaries used by CEF4Delphi are available for download at Spotify :
|
The CEF binaries used by CEF4Delphi are available for download at Spotify :
|
||||||
* [Windows 32 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.20%2Bg7cfecf1%2Bchromium-92.0.4515.107_windows32.tar.bz2)
|
* [Windows 32 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.21%2Bga9ec100%2Bchromium-92.0.4515.107_windows32.tar.bz2)
|
||||||
* [Windows 64 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.20%2Bg7cfecf1%2Bchromium-92.0.4515.107_windows64.tar.bz2)
|
* [Windows 64 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.21%2Bga9ec100%2Bchromium-92.0.4515.107_windows64.tar.bz2)
|
||||||
* [Linux x86 32 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.20%2Bg7cfecf1%2Bchromium-92.0.4515.107_linux32.tar.bz2)
|
* [Linux x86 32 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.21%2Bga9ec100%2Bchromium-92.0.4515.107_linux32.tar.bz2)
|
||||||
* [Linux x86 64 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.20%2Bg7cfecf1%2Bchromium-92.0.4515.107_linux64.tar.bz2)
|
* [Linux x86 64 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.21%2Bga9ec100%2Bchromium-92.0.4515.107_linux64.tar.bz2)
|
||||||
* [Linux ARM 32 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.20%2Bg7cfecf1%2Bchromium-92.0.4515.107_linuxarm.tar.bz2)
|
* [Linux ARM 32 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.21%2Bga9ec100%2Bchromium-92.0.4515.107_linuxarm.tar.bz2)
|
||||||
* [Linux ARM 64 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.20%2Bg7cfecf1%2Bchromium-92.0.4515.107_linuxarm64.tar.bz2)
|
* [Linux ARM 64 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.21%2Bga9ec100%2Bchromium-92.0.4515.107_linuxarm64.tar.bz2)
|
||||||
* [MacOS x86 64 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.20%2Bg7cfecf1%2Bchromium-92.0.4515.107_macosx64.tar.bz2)
|
* [MacOS x86 64 bits](https://cef-builds.spotifycdn.com/cef_binary_92.0.21%2Bga9ec100%2Bchromium-92.0.4515.107_macosx64.tar.bz2)
|
||||||
|
|
||||||
CEF4Delphi was developed and tested on Delphi 10.4.2 and it has been tested in Delphi 7, Delphi XE, Delphi 10, Delphi 10.2, Delphi 10.3 and Lazarus 2.0.12/FPC 3.2.0. CEF4Delphi includes VCL, FireMonkey (FMX) and Lazarus components.
|
CEF4Delphi was developed and tested on Delphi 10.4.2 and it has been tested in Delphi 7, Delphi XE, Delphi 10, Delphi 10.2, Delphi 10.3 and Lazarus 2.0.12/FPC 3.2.0. CEF4Delphi includes VCL, FireMonkey (FMX) and Lazarus components.
|
||||||
|
|
||||||
|
@@ -459,7 +459,6 @@ end;
|
|||||||
procedure CreateGlobalCEFApp;
|
procedure CreateGlobalCEFApp;
|
||||||
begin
|
begin
|
||||||
GlobalCEFApp := TCefApplication.Create;
|
GlobalCEFApp := TCefApplication.Create;
|
||||||
GlobalCEFApp.RemoteDebuggingPort := 9000;
|
|
||||||
GlobalCEFApp.OnProcessMessageReceived := GlobalCEFApp_OnProcessMessageReceived;
|
GlobalCEFApp.OnProcessMessageReceived := GlobalCEFApp_OnProcessMessageReceived;
|
||||||
|
|
||||||
// Enabling the debug log file for then DOM visitor demo.
|
// Enabling the debug log file for then DOM visitor demo.
|
||||||
@@ -582,7 +581,8 @@ begin
|
|||||||
PostMessage(Handle, MINIBROWSER_COPYFRAMEIDS_2, 0, 0);
|
PostMessage(Handle, MINIBROWSER_COPYFRAMEIDS_2, 0, 0);
|
||||||
|
|
||||||
MINIBROWSER_CONTEXTMENU_SETINPUTVALUE_JS :
|
MINIBROWSER_CONTEXTMENU_SETINPUTVALUE_JS :
|
||||||
frame.ExecuteJavaScript('document.getElementById("' + NODE_ID + '").value = "qwerty";', 'about:blank', 0);
|
if (frame <> nil) and frame.IsValid then
|
||||||
|
frame.ExecuteJavaScript('document.getElementById("' + NODE_ID + '").value = "qwerty";', 'about:blank', 0);
|
||||||
|
|
||||||
MINIBROWSER_CONTEXTMENU_SETINPUTVALUE_DT :
|
MINIBROWSER_CONTEXTMENU_SETINPUTVALUE_DT :
|
||||||
// https://chromedevtools.github.io/devtools-protocol/tot/DOM/#method-getDocument
|
// https://chromedevtools.github.io/devtools-protocol/tot/DOM/#method-getDocument
|
||||||
|
@@ -6,7 +6,7 @@
|
|||||||
<MainSource>TinyBrowser2.dpr</MainSource>
|
<MainSource>TinyBrowser2.dpr</MainSource>
|
||||||
<Base>True</Base>
|
<Base>True</Base>
|
||||||
<Config Condition="'$(Config)'==''">Debug</Config>
|
<Config Condition="'$(Config)'==''">Debug</Config>
|
||||||
<Platform Condition="'$(Platform)'==''">Win64</Platform>
|
<Platform Condition="'$(Platform)'==''">Win32</Platform>
|
||||||
<TargetedPlatforms>3</TargetedPlatforms>
|
<TargetedPlatforms>3</TargetedPlatforms>
|
||||||
<AppType>Application</AppType>
|
<AppType>Application</AppType>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
@@ -111,6 +111,7 @@ begin
|
|||||||
GlobalCEFApp.ExternalMessagePump := False;
|
GlobalCEFApp.ExternalMessagePump := False;
|
||||||
GlobalCEFApp.ChromeRuntime := True; // Enable this line to enable the "ChromeRuntime" mode. It's in experimental state.
|
GlobalCEFApp.ChromeRuntime := True; // Enable this line to enable the "ChromeRuntime" mode. It's in experimental state.
|
||||||
GlobalCEFApp.cache := 'cache';
|
GlobalCEFApp.cache := 'cache';
|
||||||
|
GlobalCEFApp.DisablePopupBlocking := True;
|
||||||
GlobalCEFApp.OnContextInitialized := GlobalCEFApp_OnContextInitialized;
|
GlobalCEFApp.OnContextInitialized := GlobalCEFApp_OnContextInitialized;
|
||||||
GlobalCEFApp.OnGetDefaultClient := GlobalCEFApp_OnGetDefaultClient; // This event is only used in "ChromeRuntime" mode
|
GlobalCEFApp.OnGetDefaultClient := GlobalCEFApp_OnGetDefaultClient; // This event is only used in "ChromeRuntime" mode
|
||||||
|
|
||||||
|
@@ -445,7 +445,6 @@ end;
|
|||||||
procedure CreateGlobalCEFApp;
|
procedure CreateGlobalCEFApp;
|
||||||
begin
|
begin
|
||||||
GlobalCEFApp := TCefApplication.Create;
|
GlobalCEFApp := TCefApplication.Create;
|
||||||
GlobalCEFApp.RemoteDebuggingPort := 9000;
|
|
||||||
GlobalCEFApp.OnProcessMessageReceived := GlobalCEFApp_OnProcessMessageReceived;
|
GlobalCEFApp.OnProcessMessageReceived := GlobalCEFApp_OnProcessMessageReceived;
|
||||||
|
|
||||||
// Enabling the debug log file for then DOM visitor demo.
|
// Enabling the debug log file for then DOM visitor demo.
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
// ************************************************************************
|
// ************************************************************************
|
||||||
// ***************************** CEF4Delphi *******************************
|
// ***************************** CEF4Delphi *******************************
|
||||||
// ************************************************************************
|
// ************************************************************************
|
||||||
//
|
//
|
||||||
@@ -106,6 +106,7 @@ begin
|
|||||||
GlobalCEFApp.MultiThreadedMessageLoop := False;
|
GlobalCEFApp.MultiThreadedMessageLoop := False;
|
||||||
GlobalCEFApp.ExternalMessagePump := False;
|
GlobalCEFApp.ExternalMessagePump := False;
|
||||||
GlobalCEFApp.ChromeRuntime := True; // Enable this line to enable the "ChromeRuntime" mode. It's in experimental state.
|
GlobalCEFApp.ChromeRuntime := True; // Enable this line to enable the "ChromeRuntime" mode. It's in experimental state.
|
||||||
|
GlobalCEFApp.DisablePopupBlocking := True;
|
||||||
GlobalCEFApp.cache := 'cache';
|
GlobalCEFApp.cache := 'cache';
|
||||||
GlobalCEFApp.OnContextInitialized := GlobalCEFApp_OnContextInitialized;
|
GlobalCEFApp.OnContextInitialized := GlobalCEFApp_OnContextInitialized;
|
||||||
GlobalCEFApp.OnGetDefaultClient := GlobalCEFApp_OnGetDefaultClient; // This event is only used in "ChromeRuntime" mode
|
GlobalCEFApp.OnGetDefaultClient := GlobalCEFApp_OnGetDefaultClient; // This event is only used in "ChromeRuntime" mode
|
||||||
|
@@ -21,7 +21,7 @@
|
|||||||
</CompilerOptions>
|
</CompilerOptions>
|
||||||
<Description Value="CEF4Delphi is an open source project created by Salvador Díaz Fau to embed Chromium-based browsers in applications made with Delphi or Lazarus/FPC."/>
|
<Description Value="CEF4Delphi is an open source project created by Salvador Díaz Fau to embed Chromium-based browsers in applications made with Delphi or Lazarus/FPC."/>
|
||||||
<License Value="MPL 1.1"/>
|
<License Value="MPL 1.1"/>
|
||||||
<Version Major="92" Release="20"/>
|
<Version Major="92" Release="21"/>
|
||||||
<Files Count="203">
|
<Files Count="203">
|
||||||
<Item1>
|
<Item1>
|
||||||
<Filename Value="..\source\uCEFAccessibilityHandler.pas"/>
|
<Filename Value="..\source\uCEFAccessibilityHandler.pas"/>
|
||||||
|
@@ -66,7 +66,7 @@ uses
|
|||||||
const
|
const
|
||||||
CEF_SUPPORTED_VERSION_MAJOR = 92;
|
CEF_SUPPORTED_VERSION_MAJOR = 92;
|
||||||
CEF_SUPPORTED_VERSION_MINOR = 0;
|
CEF_SUPPORTED_VERSION_MINOR = 0;
|
||||||
CEF_SUPPORTED_VERSION_RELEASE = 20;
|
CEF_SUPPORTED_VERSION_RELEASE = 21;
|
||||||
CEF_SUPPORTED_VERSION_BUILD = 0;
|
CEF_SUPPORTED_VERSION_BUILD = 0;
|
||||||
|
|
||||||
CEF_CHROMEELF_VERSION_MAJOR = 92;
|
CEF_CHROMEELF_VERSION_MAJOR = 92;
|
||||||
@@ -98,67 +98,46 @@ const
|
|||||||
type
|
type
|
||||||
TCefApplicationCore = class
|
TCefApplicationCore = class
|
||||||
protected
|
protected
|
||||||
FCache : ustring;
|
// Fields used to populate TCefSettings
|
||||||
FRootCache : ustring;
|
FNoSandbox : boolean;
|
||||||
FUserDataPath : ustring;
|
|
||||||
FUserAgent : ustring;
|
|
||||||
FUserAgentProduct : ustring;
|
|
||||||
FLocale : ustring;
|
|
||||||
FLocalesRequired : ustring;
|
|
||||||
FLogFile : ustring;
|
|
||||||
FBrowserSubprocessPath : ustring;
|
FBrowserSubprocessPath : ustring;
|
||||||
FFrameworkDirPath : ustring;
|
FFrameworkDirPath : ustring;
|
||||||
FMainBundlePath : ustring; // Only used in macOS
|
FMainBundlePath : ustring; // Only used in macOS
|
||||||
FChromeRuntime : boolean;
|
FChromeRuntime : boolean;
|
||||||
|
FMultiThreadedMessageLoop : boolean;
|
||||||
|
FExternalMessagePump : boolean;
|
||||||
|
FWindowlessRenderingEnabled : boolean;
|
||||||
|
FCommandLineArgsDisabled : boolean;
|
||||||
|
FCache : ustring;
|
||||||
|
FRootCache : ustring;
|
||||||
|
FUserDataPath : ustring;
|
||||||
|
FPersistSessionCookies : boolean;
|
||||||
|
FPersistUserPreferences : boolean;
|
||||||
|
FUserAgent : ustring;
|
||||||
|
FUserAgentProduct : ustring;
|
||||||
|
FLocale : ustring;
|
||||||
|
FLogFile : ustring;
|
||||||
FLogSeverity : TCefLogSeverity;
|
FLogSeverity : TCefLogSeverity;
|
||||||
FJavaScriptFlags : ustring;
|
FJavaScriptFlags : ustring;
|
||||||
FResourcesDirPath : ustring;
|
FResourcesDirPath : ustring;
|
||||||
FLocalesDirPath : ustring;
|
FLocalesDirPath : ustring;
|
||||||
FSingleProcess : Boolean;
|
FPackLoadingDisabled : boolean;
|
||||||
FNoSandbox : Boolean;
|
FRemoteDebuggingPort : integer;
|
||||||
FCommandLineArgsDisabled : Boolean;
|
FUncaughtExceptionStackSize : integer;
|
||||||
FPackLoadingDisabled : Boolean;
|
FIgnoreCertificateErrors : boolean;
|
||||||
FRemoteDebuggingPort : Integer;
|
|
||||||
FUncaughtExceptionStackSize : Integer;
|
|
||||||
FPersistSessionCookies : Boolean;
|
|
||||||
FPersistUserPreferences : boolean;
|
|
||||||
FIgnoreCertificateErrors : Boolean;
|
|
||||||
FBackgroundColor : TCefColor;
|
FBackgroundColor : TCefColor;
|
||||||
FAcceptLanguageList : ustring;
|
FAcceptLanguageList : ustring;
|
||||||
FCookieableSchemesList : ustring;
|
FCookieableSchemesList : ustring;
|
||||||
FCookieableSchemesExcludeDefaults : boolean;
|
FCookieableSchemesExcludeDefaults : boolean;
|
||||||
FApplicationClientID : ustring;
|
FApplicationClientID : ustring;
|
||||||
FWindowsSandboxInfo : Pointer;
|
|
||||||
FWindowlessRenderingEnabled : Boolean;
|
// Fields used to set command line switches
|
||||||
FMultiThreadedMessageLoop : boolean;
|
FSingleProcess : boolean;
|
||||||
FExternalMessagePump : boolean;
|
|
||||||
FDeleteCache : boolean;
|
|
||||||
FDeleteCookies : boolean;
|
|
||||||
FCustomCommandLines : TStringList;
|
|
||||||
FCustomCommandLineValues : TStringList;
|
|
||||||
FEnableMediaStream : boolean;
|
FEnableMediaStream : boolean;
|
||||||
FEnableSpeechInput : boolean;
|
FEnableSpeechInput : boolean;
|
||||||
FUseFakeUIForMediaStream : boolean;
|
FUseFakeUIForMediaStream : boolean;
|
||||||
FEnableUsermediaScreenCapturing : boolean;
|
FEnableUsermediaScreenCapturing : boolean;
|
||||||
FEnableGPU : boolean;
|
FEnableGPU : boolean;
|
||||||
FCheckCEFFiles : boolean;
|
|
||||||
FLibLoaded : boolean;
|
|
||||||
FSmoothScrolling : TCefState;
|
|
||||||
FFastUnload : boolean;
|
|
||||||
FDisableSafeBrowsing : boolean;
|
|
||||||
FEnableHighDPISupport : boolean;
|
|
||||||
FMuteAudio : boolean;
|
|
||||||
FReRaiseExceptions : boolean;
|
|
||||||
FShowMessageDlg : boolean;
|
|
||||||
FMissingBinariesException : boolean;
|
|
||||||
FSetCurrentDir : boolean;
|
|
||||||
FGlobalContextInitialized : boolean;
|
|
||||||
FSitePerProcess : boolean;
|
|
||||||
FDisableWebSecurity : boolean;
|
|
||||||
FDisablePDFExtension : boolean;
|
|
||||||
FLogProcessInfo : boolean;
|
|
||||||
FDisableSiteIsolationTrials : boolean;
|
|
||||||
FDisableChromeLoginPrompt : boolean;
|
|
||||||
FEnableFeatures : ustring;
|
FEnableFeatures : ustring;
|
||||||
FDisableFeatures : ustring;
|
FDisableFeatures : ustring;
|
||||||
FEnableBlinkFeatures : ustring;
|
FEnableBlinkFeatures : ustring;
|
||||||
@@ -166,35 +145,22 @@ type
|
|||||||
FBlinkSettings : ustring;
|
FBlinkSettings : ustring;
|
||||||
FForceFieldTrials : ustring;
|
FForceFieldTrials : ustring;
|
||||||
FForceFieldTrialParams : ustring;
|
FForceFieldTrialParams : ustring;
|
||||||
FChromeVersionInfo : TFileVersionInfo;
|
FSmoothScrolling : TCefState;
|
||||||
{$IFDEF FPC}
|
FFastUnload : boolean;
|
||||||
FLibHandle : TLibHandle;
|
FDisableSafeBrowsing : boolean;
|
||||||
{$ELSE}
|
FMuteAudio : boolean;
|
||||||
FLibHandle : THandle;
|
FSitePerProcess : boolean;
|
||||||
{$ENDIF}
|
FDisableWebSecurity : boolean;
|
||||||
FOnRegisterCustomSchemes : TOnRegisterCustomSchemesEvent;
|
FDisablePDFExtension : boolean;
|
||||||
FAppSettings : TCefSettings;
|
FDisableSiteIsolationTrials : boolean;
|
||||||
|
FDisableChromeLoginPrompt : boolean;
|
||||||
FDisableExtensions : boolean;
|
FDisableExtensions : boolean;
|
||||||
FDisableGPUCache : boolean;
|
|
||||||
FStatus : TCefAplicationStatus;
|
|
||||||
FMissingLibFiles : string;
|
|
||||||
FProcessType : TCefProcessType;
|
|
||||||
FWidevinePath : ustring;
|
|
||||||
FMustFreeLibrary : boolean;
|
|
||||||
FAutoplayPolicy : TCefAutoplayPolicy;
|
FAutoplayPolicy : TCefAutoplayPolicy;
|
||||||
FDisableBackgroundNetworking : boolean;
|
FDisableBackgroundNetworking : boolean;
|
||||||
FMetricsRecordingOnly : boolean;
|
FMetricsRecordingOnly : boolean;
|
||||||
FAllowFileAccessFromFiles : boolean;
|
FAllowFileAccessFromFiles : boolean;
|
||||||
FAllowRunningInsecureContent : boolean;
|
FAllowRunningInsecureContent : boolean;
|
||||||
FDisableNewBrowserInfoTimeout : boolean;
|
FEnablePrintPreview : boolean;
|
||||||
FDevToolsProtocolLogFile : ustring;
|
|
||||||
FDeviceScaleFactor : single;
|
|
||||||
FForcedDeviceScaleFactor : single;
|
|
||||||
FDisableZygote : boolean;
|
|
||||||
FUseMockKeyChain : boolean;
|
|
||||||
FDisableRequestHandlingForTesting : boolean;
|
|
||||||
FLastErrorMessage : ustring;
|
|
||||||
|
|
||||||
FPluginPolicy : TCefPluginPolicySwitch;
|
FPluginPolicy : TCefPluginPolicySwitch;
|
||||||
FDefaultEncoding : ustring;
|
FDefaultEncoding : ustring;
|
||||||
FDisableJavascript : boolean;
|
FDisableJavascript : boolean;
|
||||||
@@ -210,15 +176,56 @@ type
|
|||||||
FEnableProfanityFilter : boolean;
|
FEnableProfanityFilter : boolean;
|
||||||
FDisableSpellChecking : boolean;
|
FDisableSpellChecking : boolean;
|
||||||
FOverrideSpellCheckLang : ustring;
|
FOverrideSpellCheckLang : ustring;
|
||||||
FEnablePrintPreview : boolean;
|
|
||||||
FTouchEvents : TCefState;
|
FTouchEvents : TCefState;
|
||||||
FDisableReadingFromCanvas : boolean;
|
FDisableReadingFromCanvas : boolean;
|
||||||
FHyperlinkAuditing : boolean;
|
FHyperlinkAuditing : boolean;
|
||||||
|
FDisableNewBrowserInfoTimeout : boolean;
|
||||||
|
FDevToolsProtocolLogFile : ustring;
|
||||||
|
FForcedDeviceScaleFactor : single;
|
||||||
|
FDisableZygote : boolean; // Only used in Linux
|
||||||
|
FUseMockKeyChain : boolean; // Only used in macOS
|
||||||
|
FDisableRequestHandlingForTesting : boolean;
|
||||||
|
FDisablePopupBlocking : boolean;
|
||||||
|
FDisableBackForwardCache : boolean;
|
||||||
|
|
||||||
|
// Fields used during the CEF initialization
|
||||||
|
FWindowsSandboxInfo : pointer;
|
||||||
|
FEnableHighDPISupport : boolean;
|
||||||
|
|
||||||
|
// Fields used by custom properties
|
||||||
|
FDeleteCache : boolean;
|
||||||
|
FDeleteCookies : boolean;
|
||||||
|
FCheckCEFFiles : boolean;
|
||||||
|
FShowMessageDlg : boolean;
|
||||||
|
FMissingBinariesException : boolean;
|
||||||
|
FSetCurrentDir : boolean;
|
||||||
|
FGlobalContextInitialized : boolean;
|
||||||
|
FChromeVersionInfo : TFileVersionInfo;
|
||||||
|
FLibLoaded : boolean;
|
||||||
|
FLogProcessInfo : boolean;
|
||||||
|
FReRaiseExceptions : boolean;
|
||||||
|
FDeviceScaleFactor : single;
|
||||||
|
FLocalesRequired : ustring;
|
||||||
|
FProcessType : TCefProcessType;
|
||||||
FMustCreateResourceBundleHandler : boolean;
|
FMustCreateResourceBundleHandler : boolean;
|
||||||
FMustCreateBrowserProcessHandler : boolean;
|
FMustCreateBrowserProcessHandler : boolean;
|
||||||
FMustCreateRenderProcessHandler : boolean;
|
FMustCreateRenderProcessHandler : boolean;
|
||||||
FMustCreateLoadHandler : boolean;
|
FMustCreateLoadHandler : boolean;
|
||||||
|
FStatus : TCefAplicationStatus;
|
||||||
|
FMissingLibFiles : string;
|
||||||
|
FWidevinePath : ustring;
|
||||||
|
FMustFreeLibrary : boolean;
|
||||||
|
FLastErrorMessage : ustring;
|
||||||
|
|
||||||
|
// Internal fields
|
||||||
|
FLibHandle : {$IFDEF FPC}TLibHandle{$ELSE}THandle{$ENDIF};
|
||||||
|
FCustomCommandLines : TStringList;
|
||||||
|
FCustomCommandLineValues : TStringList;
|
||||||
|
FAppSettings : TCefSettings;
|
||||||
|
FDisableGPUCache : boolean;
|
||||||
|
|
||||||
|
// ICefApp
|
||||||
|
FOnRegisterCustomSchemes : TOnRegisterCustomSchemesEvent;
|
||||||
|
|
||||||
// ICefBrowserProcessHandler
|
// ICefBrowserProcessHandler
|
||||||
FOnContextInitialized : TOnContextInitializedEvent;
|
FOnContextInitialized : TOnContextInitializedEvent;
|
||||||
@@ -490,6 +497,8 @@ type
|
|||||||
property DisableZygote : boolean read FDisableZygote write FDisableZygote; // --no-zygote
|
property DisableZygote : boolean read FDisableZygote write FDisableZygote; // --no-zygote
|
||||||
property UseMockKeyChain : boolean read FUseMockKeyChain write FUseMockKeyChain; // --use-mock-keychain
|
property UseMockKeyChain : boolean read FUseMockKeyChain write FUseMockKeyChain; // --use-mock-keychain
|
||||||
property DisableRequestHandlingForTesting : boolean read FDisableRequestHandlingForTesting write FDisableRequestHandlingForTesting; // --disable-request-handling-for-testing
|
property DisableRequestHandlingForTesting : boolean read FDisableRequestHandlingForTesting write FDisableRequestHandlingForTesting; // --disable-request-handling-for-testing
|
||||||
|
property DisablePopupBlocking : boolean read FDisablePopupBlocking write FDisablePopupBlocking; // --disable-popup-blocking
|
||||||
|
property DisableBackForwardCache : boolean read FDisableBackForwardCache write FDisableBackForwardCache; // --disable-back-forward-cache
|
||||||
|
|
||||||
// Properties used during the CEF initialization
|
// Properties used during the CEF initialization
|
||||||
property WindowsSandboxInfo : Pointer read FWindowsSandboxInfo write FWindowsSandboxInfo;
|
property WindowsSandboxInfo : Pointer read FWindowsSandboxInfo write FWindowsSandboxInfo;
|
||||||
@@ -648,107 +657,72 @@ begin
|
|||||||
if (GlobalCEFApp = nil) then
|
if (GlobalCEFApp = nil) then
|
||||||
GlobalCEFApp := Self;
|
GlobalCEFApp := Self;
|
||||||
|
|
||||||
FStatus := asLoading;
|
// Fields used to populate TCefSettings
|
||||||
FMissingLibFiles := '';
|
FNoSandbox := True;
|
||||||
FLibHandle := 0;
|
FBrowserSubprocessPath := '';
|
||||||
|
FFrameworkDirPath := '';
|
||||||
|
FMainBundlePath := {$IFDEF MACOSX}GetModulePath{$ELSE}''{$ENDIF};
|
||||||
|
FChromeRuntime := False;
|
||||||
|
FMultiThreadedMessageLoop := True;
|
||||||
|
FExternalMessagePump := False;
|
||||||
|
FWindowlessRenderingEnabled := False;
|
||||||
|
FCommandLineArgsDisabled := False;
|
||||||
FCache := '';
|
FCache := '';
|
||||||
FRootCache := '';
|
FRootCache := '';
|
||||||
FUserDataPath := '';
|
FUserDataPath := '';
|
||||||
|
FPersistSessionCookies := False;
|
||||||
|
FPersistUserPreferences := False;
|
||||||
FUserAgent := '';
|
FUserAgent := '';
|
||||||
FUserAgentProduct := '';
|
FUserAgentProduct := '';
|
||||||
FLocale := '';
|
FLocale := '';
|
||||||
FLogFile := '';
|
FLogFile := '';
|
||||||
FBrowserSubprocessPath := '';
|
|
||||||
FFrameworkDirPath := '';
|
|
||||||
{$IFDEF MACOSX}
|
|
||||||
FMainBundlePath := GetModulePath;
|
|
||||||
{$ELSE}
|
|
||||||
FMainBundlePath := '';
|
|
||||||
{$ENDIF}
|
|
||||||
FChromeRuntime := False;
|
|
||||||
FLogSeverity := LOGSEVERITY_DISABLE;
|
FLogSeverity := LOGSEVERITY_DISABLE;
|
||||||
FJavaScriptFlags := '';
|
FJavaScriptFlags := '';
|
||||||
FResourcesDirPath := '';
|
FResourcesDirPath := '';
|
||||||
FLocalesDirPath := '';
|
FLocalesDirPath := '';
|
||||||
FSingleProcess := False;
|
|
||||||
FNoSandbox := True;
|
|
||||||
FCommandLineArgsDisabled := False;
|
|
||||||
FPackLoadingDisabled := False;
|
FPackLoadingDisabled := False;
|
||||||
FRemoteDebuggingPort := 0;
|
FRemoteDebuggingPort := 0;
|
||||||
FUncaughtExceptionStackSize := 0;
|
FUncaughtExceptionStackSize := 0;
|
||||||
FPersistSessionCookies := False;
|
|
||||||
FPersistUserPreferences := False;
|
|
||||||
FIgnoreCertificateErrors := False;
|
FIgnoreCertificateErrors := False;
|
||||||
FBackgroundColor := 0;
|
FBackgroundColor := 0;
|
||||||
FAcceptLanguageList := '';
|
FAcceptLanguageList := '';
|
||||||
FCookieableSchemesList := '';
|
FCookieableSchemesList := '';
|
||||||
FCookieableSchemesExcludeDefaults := False;
|
FCookieableSchemesExcludeDefaults := False;
|
||||||
FApplicationClientID := '';
|
FApplicationClientID := '';
|
||||||
FWindowsSandboxInfo := nil;
|
|
||||||
FWindowlessRenderingEnabled := False;
|
// Fields used to set command line switches
|
||||||
FMultiThreadedMessageLoop := True;
|
FSingleProcess := False;
|
||||||
FExternalMessagePump := False;
|
|
||||||
FDeleteCache := False;
|
|
||||||
FDeleteCookies := False;
|
|
||||||
FEnableMediaStream := True;
|
FEnableMediaStream := True;
|
||||||
FEnableSpeechInput := False;
|
FEnableSpeechInput := False;
|
||||||
FUseFakeUIForMediaStream := False;
|
FUseFakeUIForMediaStream := False;
|
||||||
FEnableUsermediaScreenCapturing := False;
|
FEnableUsermediaScreenCapturing := False;
|
||||||
FEnableGPU := False;
|
FEnableGPU := False;
|
||||||
FCustomCommandLines := nil;
|
FEnableFeatures := '';
|
||||||
FCustomCommandLineValues := nil;
|
FDisableFeatures := '';
|
||||||
{$IFDEF MACOSX}
|
FEnableBlinkFeatures := '';
|
||||||
FCheckCEFFiles := False;
|
FDisableBlinkFeatures := '';
|
||||||
{$ELSE}
|
FBlinkSettings := '';
|
||||||
FCheckCEFFiles := True;
|
FForceFieldTrials := '';
|
||||||
{$ENDIF}
|
FForceFieldTrialParams := '';
|
||||||
FSmoothScrolling := STATE_DEFAULT;
|
FSmoothScrolling := STATE_DEFAULT;
|
||||||
FFastUnload := False;
|
FFastUnload := False;
|
||||||
FDisableSafeBrowsing := False;
|
FDisableSafeBrowsing := False;
|
||||||
FOnRegisterCustomSchemes := nil;
|
|
||||||
FEnableHighDPISupport := False;
|
|
||||||
FMuteAudio := False;
|
FMuteAudio := False;
|
||||||
FSitePerProcess := False;
|
FSitePerProcess := False;
|
||||||
FDisableWebSecurity := False;
|
FDisableWebSecurity := False;
|
||||||
FDisablePDFExtension := False;
|
FDisablePDFExtension := False;
|
||||||
FDisableSiteIsolationTrials := False;
|
FDisableSiteIsolationTrials := False;
|
||||||
FDisableChromeLoginPrompt := False;
|
FDisableChromeLoginPrompt := False;
|
||||||
FLogProcessInfo := False;
|
|
||||||
FReRaiseExceptions := False;
|
|
||||||
FLibLoaded := False;
|
|
||||||
FShowMessageDlg := True;
|
|
||||||
FMissingBinariesException := False;
|
|
||||||
FSetCurrentDir := False;
|
|
||||||
FGlobalContextInitialized := False;
|
|
||||||
FDisableExtensions := False;
|
FDisableExtensions := False;
|
||||||
FDisableGPUCache := True;
|
|
||||||
FLocalesRequired := '';
|
|
||||||
FProcessType := ParseProcessType;
|
|
||||||
FWidevinePath := '';
|
|
||||||
FMustFreeLibrary := False;
|
|
||||||
FAutoplayPolicy := appDefault;
|
FAutoplayPolicy := appDefault;
|
||||||
FDisableBackgroundNetworking := False;
|
FDisableBackgroundNetworking := False;
|
||||||
FMetricsRecordingOnly := False;
|
FMetricsRecordingOnly := False;
|
||||||
FAllowFileAccessFromFiles := False;
|
FAllowFileAccessFromFiles := False;
|
||||||
FAllowRunningInsecureContent := False;
|
FAllowRunningInsecureContent := False;
|
||||||
|
FEnablePrintPreview := False;
|
||||||
FPluginPolicy := PLUGIN_POLICY_SWITCH_ALLOW;
|
FPluginPolicy := PLUGIN_POLICY_SWITCH_ALLOW;
|
||||||
FDefaultEncoding := '';
|
FDefaultEncoding := '';
|
||||||
FDisableJavascript := False;
|
FDisableJavascript := False;
|
||||||
FEnableFeatures := '';
|
|
||||||
FDisableFeatures := '';
|
|
||||||
FEnableBlinkFeatures := '';
|
|
||||||
FDisableBlinkFeatures := '';
|
|
||||||
FForceFieldTrials := '';
|
|
||||||
FForceFieldTrialParams := '';
|
|
||||||
FBlinkSettings := '';
|
|
||||||
FDisableNewBrowserInfoTimeout := False;
|
|
||||||
FDevToolsProtocolLogFile := '';
|
|
||||||
FForcedDeviceScaleFactor := 0;
|
|
||||||
FDisableZygote := False;
|
|
||||||
FUseMockKeyChain := False;
|
|
||||||
FDisableRequestHandlingForTesting := False;
|
|
||||||
FLastErrorMessage := '';
|
|
||||||
|
|
||||||
FDisableJavascriptCloseWindows := False;
|
FDisableJavascriptCloseWindows := False;
|
||||||
FDisableJavascriptAccessClipboard := False;
|
FDisableJavascriptAccessClipboard := False;
|
||||||
FDisableJavascriptDomPaste := False;
|
FDisableJavascriptDomPaste := False;
|
||||||
@@ -761,15 +735,64 @@ begin
|
|||||||
FEnableProfanityFilter := False;
|
FEnableProfanityFilter := False;
|
||||||
FDisableSpellChecking := False;
|
FDisableSpellChecking := False;
|
||||||
FOverrideSpellCheckLang := '';
|
FOverrideSpellCheckLang := '';
|
||||||
FEnablePrintPreview := False;
|
|
||||||
FTouchEvents := STATE_DEFAULT;
|
FTouchEvents := STATE_DEFAULT;
|
||||||
FDisableReadingFromCanvas := False;
|
FDisableReadingFromCanvas := False;
|
||||||
FHyperlinkAuditing := True;
|
FHyperlinkAuditing := True;
|
||||||
|
FDisableNewBrowserInfoTimeout := False;
|
||||||
|
FDevToolsProtocolLogFile := '';
|
||||||
|
FForcedDeviceScaleFactor := 0;
|
||||||
|
FDisableZygote := False;
|
||||||
|
FUseMockKeyChain := False;
|
||||||
|
FDisableRequestHandlingForTesting := False;
|
||||||
|
FDisablePopupBlocking := False;
|
||||||
|
FDisableBackForwardCache := False;
|
||||||
|
|
||||||
|
// Fields used during the CEF initialization
|
||||||
|
FWindowsSandboxInfo := nil;
|
||||||
|
FEnableHighDPISupport := False;
|
||||||
|
|
||||||
|
// Fields used by custom properties
|
||||||
|
FDeleteCache := False;
|
||||||
|
FDeleteCookies := False;
|
||||||
|
FCheckCEFFiles := {$IFDEF MACOSX}False{$ELSE}True{$ENDIF};
|
||||||
|
FShowMessageDlg := True;
|
||||||
|
FMissingBinariesException := False;
|
||||||
|
FSetCurrentDir := False;
|
||||||
|
FGlobalContextInitialized := False;
|
||||||
|
FChromeVersionInfo.MajorVer := CEF_CHROMEELF_VERSION_MAJOR;
|
||||||
|
FChromeVersionInfo.MinorVer := CEF_CHROMEELF_VERSION_MINOR;
|
||||||
|
FChromeVersionInfo.Release := CEF_CHROMEELF_VERSION_RELEASE;
|
||||||
|
FChromeVersionInfo.Build := CEF_CHROMEELF_VERSION_BUILD;
|
||||||
|
FLibLoaded := False;
|
||||||
|
FLogProcessInfo := False;
|
||||||
|
FReRaiseExceptions := False;
|
||||||
|
UpdateDeviceScaleFactor;
|
||||||
|
FLocalesRequired := '';
|
||||||
|
FProcessType := ParseProcessType;
|
||||||
FMustCreateResourceBundleHandler := False;
|
FMustCreateResourceBundleHandler := False;
|
||||||
FMustCreateBrowserProcessHandler := True;
|
FMustCreateBrowserProcessHandler := True; // The official CEF sample application always creates this handler in the browser process
|
||||||
FMustCreateRenderProcessHandler := False;
|
FMustCreateRenderProcessHandler := True; // The official CEF sample application always creates this handler in the renderer process
|
||||||
FMustCreateLoadHandler := False;
|
FMustCreateLoadHandler := False;
|
||||||
|
FStatus := asLoading;
|
||||||
|
FMissingLibFiles := '';
|
||||||
|
FWidevinePath := '';
|
||||||
|
FMustFreeLibrary := False;
|
||||||
|
FLastErrorMessage := '';
|
||||||
|
{$IFDEF MSWINDOWS}
|
||||||
|
if (FProcessType = ptBrowser) then
|
||||||
|
GetDLLVersion(ChromeElfPath, FChromeVersionInfo);
|
||||||
|
{$ENDIF}
|
||||||
|
|
||||||
|
// Internal filelds
|
||||||
|
FLibHandle := 0;
|
||||||
|
FCustomCommandLines := nil;
|
||||||
|
FCustomCommandLineValues := nil;
|
||||||
|
FillChar(FAppSettings, SizeOf(TCefSettings), 0);
|
||||||
|
FAppSettings.size := SizeOf(TCefSettings);
|
||||||
|
FDisableGPUCache := True;
|
||||||
|
|
||||||
|
// ICefApp
|
||||||
|
FOnRegisterCustomSchemes := nil;
|
||||||
|
|
||||||
// ICefBrowserProcessHandler
|
// ICefBrowserProcessHandler
|
||||||
FOnContextInitialized := nil;
|
FOnContextInitialized := nil;
|
||||||
@@ -801,21 +824,6 @@ begin
|
|||||||
FOnLoadEnd := nil;
|
FOnLoadEnd := nil;
|
||||||
FOnLoadError := nil;
|
FOnLoadError := nil;
|
||||||
|
|
||||||
UpdateDeviceScaleFactor;
|
|
||||||
|
|
||||||
FillChar(FAppSettings, SizeOf(TCefSettings), 0);
|
|
||||||
FAppSettings.size := SizeOf(TCefSettings);
|
|
||||||
|
|
||||||
FChromeVersionInfo.MajorVer := CEF_CHROMEELF_VERSION_MAJOR;
|
|
||||||
FChromeVersionInfo.MinorVer := CEF_CHROMEELF_VERSION_MINOR;
|
|
||||||
FChromeVersionInfo.Release := CEF_CHROMEELF_VERSION_RELEASE;
|
|
||||||
FChromeVersionInfo.Build := CEF_CHROMEELF_VERSION_BUILD;
|
|
||||||
|
|
||||||
{$IFDEF MSWINDOWS}
|
|
||||||
if (FProcessType = ptBrowser) then
|
|
||||||
GetDLLVersion(ChromeElfPath, FChromeVersionInfo);
|
|
||||||
{$ENDIF}
|
|
||||||
|
|
||||||
IsMultiThread := True;
|
IsMultiThread := True;
|
||||||
|
|
||||||
SetExceptionMask([exInvalidOp, exDenormalized, exZeroDivide, exOverflow, exUnderflow, exPrecision]);
|
SetExceptionMask([exInvalidOp, exDenormalized, exZeroDivide, exOverflow, exUnderflow, exPrecision]);
|
||||||
@@ -2053,6 +2061,12 @@ begin
|
|||||||
if FDisableRequestHandlingForTesting then
|
if FDisableRequestHandlingForTesting then
|
||||||
ReplaceSwitch(aKeys, aValues, '--disable-request-handling-for-testing');
|
ReplaceSwitch(aKeys, aValues, '--disable-request-handling-for-testing');
|
||||||
|
|
||||||
|
if FDisablePopupBlocking then
|
||||||
|
ReplaceSwitch(aKeys, aValues, '--disable-popup-blocking');
|
||||||
|
|
||||||
|
if FDisableBackForwardCache then
|
||||||
|
ReplaceSwitch(aKeys, aValues, '--disable-back-forward-cache');
|
||||||
|
|
||||||
// The list of features you can enable is here :
|
// The list of features you can enable is here :
|
||||||
// https://chromium.googlesource.com/chromium/src/+/master/chrome/common/chrome_features.cc
|
// https://chromium.googlesource.com/chromium/src/+/master/chrome/common/chrome_features.cc
|
||||||
if (length(FEnableFeatures) > 0) then
|
if (length(FEnableFeatures) > 0) then
|
||||||
|
@@ -2,9 +2,9 @@
|
|||||||
"UpdateLazPackages" : [
|
"UpdateLazPackages" : [
|
||||||
{
|
{
|
||||||
"ForceNotify" : true,
|
"ForceNotify" : true,
|
||||||
"InternalVersion" : 310,
|
"InternalVersion" : 311,
|
||||||
"Name" : "cef4delphi_lazarus.lpk",
|
"Name" : "cef4delphi_lazarus.lpk",
|
||||||
"Version" : "92.0.20.0"
|
"Version" : "92.0.21.0"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"UpdatePackageData" : {
|
"UpdatePackageData" : {
|
||||||
|
Reference in New Issue
Block a user