mirror of
https://github.com/salvadordf/CEF4Delphi.git
synced 2025-04-17 06:57:13 +02:00
TCefFileDialogMode and TCefDuplexMode defined as constants
- Added more parameter checks in CefRegisterExtension - Minor change registering the extension in JSExtension demo. The TempHandler reference is valid until it reaches the "finally".
This commit is contained in:
parent
08977db610
commit
5e5d0dcb74
demos
JavaScript/JSExtension
SubProcess
source
@ -9,6 +9,7 @@ del /s /q *.local
|
|||||||
del /s /q *.~*
|
del /s /q *.~*
|
||||||
rmdir Win32\Debug
|
rmdir Win32\Debug
|
||||||
rmdir Win32\Release
|
rmdir Win32\Release
|
||||||
|
rmdir "Win32\Debug with log"
|
||||||
rmdir Win32
|
rmdir Win32
|
||||||
rmdir __history
|
rmdir __history
|
||||||
rmdir __recovery
|
rmdir __recovery
|
||||||
|
@ -45,6 +45,17 @@
|
|||||||
<Cfg_2>true</Cfg_2>
|
<Cfg_2>true</Cfg_2>
|
||||||
<Base>true</Base>
|
<Base>true</Base>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Config)'=='Debug with log' or '$(Cfg_3)'!=''">
|
||||||
|
<Cfg_3>true</Cfg_3>
|
||||||
|
<CfgParent>Base</CfgParent>
|
||||||
|
<Base>true</Base>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Cfg_3)'=='true') or '$(Cfg_3_Win32)'!=''">
|
||||||
|
<Cfg_3_Win32>true</Cfg_3_Win32>
|
||||||
|
<CfgParent>Cfg_3</CfgParent>
|
||||||
|
<Cfg_3>true</Cfg_3>
|
||||||
|
<Base>true</Base>
|
||||||
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Base)'!=''">
|
<PropertyGroup Condition="'$(Base)'!=''">
|
||||||
<VerInfo_Locale>3082</VerInfo_Locale>
|
<VerInfo_Locale>3082</VerInfo_Locale>
|
||||||
<Icon_MainIcon>$(BDS)\bin\delphi_PROJECTICON.ico</Icon_MainIcon>
|
<Icon_MainIcon>$(BDS)\bin\delphi_PROJECTICON.ico</Icon_MainIcon>
|
||||||
@ -102,6 +113,22 @@
|
|||||||
<AppEnableHighDPI>true</AppEnableHighDPI>
|
<AppEnableHighDPI>true</AppEnableHighDPI>
|
||||||
<BT_BuildType>Debug</BT_BuildType>
|
<BT_BuildType>Debug</BT_BuildType>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Cfg_3)'!=''">
|
||||||
|
<DCC_Define>DEBUG;INTFLOG;$(DCC_Define)</DCC_Define>
|
||||||
|
</PropertyGroup>
|
||||||
|
<PropertyGroup Condition="'$(Cfg_3_Win32)'!=''">
|
||||||
|
<DCC_RunTimeTypeInfo>true</DCC_RunTimeTypeInfo>
|
||||||
|
<DCC_DebugDCUs>true</DCC_DebugDCUs>
|
||||||
|
<DCC_IntegerOverflowCheck>true</DCC_IntegerOverflowCheck>
|
||||||
|
<DCC_RangeChecking>true</DCC_RangeChecking>
|
||||||
|
<DCC_MapFile>3</DCC_MapFile>
|
||||||
|
<DCC_RemoteDebug>true</DCC_RemoteDebug>
|
||||||
|
<DCC_DebugInfoInExe>true</DCC_DebugInfoInExe>
|
||||||
|
<VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
|
||||||
|
<VerInfo_Locale>1033</VerInfo_Locale>
|
||||||
|
<VerInfo_Keys>CompanyName=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductVersion=1.0.0.0;Comments=;ProgramID=com.embarcadero.$(MSBuildProjectName);FileDescription=$(MSBuildProjectName);ProductName=$(MSBuildProjectName)</VerInfo_Keys>
|
||||||
|
<BT_BuildType>Debug</BT_BuildType>
|
||||||
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<DelphiCompile Include="$(MainSource)">
|
<DelphiCompile Include="$(MainSource)">
|
||||||
<MainSource>MainSource</MainSource>
|
<MainSource>MainSource</MainSource>
|
||||||
@ -113,17 +140,21 @@
|
|||||||
<DCCReference Include="uSimpleTextViewer.pas">
|
<DCCReference Include="uSimpleTextViewer.pas">
|
||||||
<Form>SimpleTextViewerFrm</Form>
|
<Form>SimpleTextViewerFrm</Form>
|
||||||
</DCCReference>
|
</DCCReference>
|
||||||
|
<BuildConfiguration Include="Base">
|
||||||
|
<Key>Base</Key>
|
||||||
|
</BuildConfiguration>
|
||||||
<BuildConfiguration Include="Release">
|
<BuildConfiguration Include="Release">
|
||||||
<Key>Cfg_2</Key>
|
<Key>Cfg_2</Key>
|
||||||
<CfgParent>Base</CfgParent>
|
<CfgParent>Base</CfgParent>
|
||||||
</BuildConfiguration>
|
</BuildConfiguration>
|
||||||
<BuildConfiguration Include="Base">
|
|
||||||
<Key>Base</Key>
|
|
||||||
</BuildConfiguration>
|
|
||||||
<BuildConfiguration Include="Debug">
|
<BuildConfiguration Include="Debug">
|
||||||
<Key>Cfg_1</Key>
|
<Key>Cfg_1</Key>
|
||||||
<CfgParent>Base</CfgParent>
|
<CfgParent>Base</CfgParent>
|
||||||
</BuildConfiguration>
|
</BuildConfiguration>
|
||||||
|
<BuildConfiguration Include="Debug with log">
|
||||||
|
<Key>Cfg_3</Key>
|
||||||
|
<CfgParent>Base</CfgParent>
|
||||||
|
</BuildConfiguration>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ProjectExtensions>
|
<ProjectExtensions>
|
||||||
<Borland.Personality>Delphi.Personality.12</Borland.Personality>
|
<Borland.Personality>Delphi.Personality.12</Borland.Personality>
|
||||||
|
@ -202,15 +202,23 @@ begin
|
|||||||
' };' +
|
' };' +
|
||||||
'})();';
|
'})();';
|
||||||
|
|
||||||
TempHandler := TTestExtensionHandler.Create;
|
try
|
||||||
|
TempHandler := TTestExtensionHandler.Create;
|
||||||
CefRegisterExtension('myextension', TempExtensionCode, TempHandler);
|
CefRegisterExtension('myextension', TempExtensionCode, TempHandler);
|
||||||
|
finally
|
||||||
|
TempHandler := nil;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure CreateGlobalCEFApp;
|
procedure CreateGlobalCEFApp;
|
||||||
begin
|
begin
|
||||||
GlobalCEFApp := TCefApplication.Create;
|
GlobalCEFApp := TCefApplication.Create;
|
||||||
GlobalCEFApp.OnWebKitInitialized := GlobalCEFApp_OnWebKitInitialized;
|
GlobalCEFApp.OnWebKitInitialized := GlobalCEFApp_OnWebKitInitialized;
|
||||||
|
|
||||||
|
{$IFDEF INTFLOG}
|
||||||
|
GlobalCEFApp.LogFile := 'debug.log';
|
||||||
|
GlobalCEFApp.LogSeverity := LOGSEVERITY_INFO;
|
||||||
|
{$ENDIF}
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TJSExtensionFrm.GoBtnClick(Sender: TObject);
|
procedure TJSExtensionFrm.GoBtnClick(Sender: TObject);
|
||||||
|
@ -69,12 +69,12 @@ type
|
|||||||
// You have to handle this two messages to call NotifyMoveOrResizeStarted or some page elements will be misaligned.
|
// You have to handle this two messages to call NotifyMoveOrResizeStarted or some page elements will be misaligned.
|
||||||
procedure WMMove(var aMessage : TWMMove); message WM_MOVE;
|
procedure WMMove(var aMessage : TWMMove); message WM_MOVE;
|
||||||
procedure WMMoving(var aMessage : TMessage); message WM_MOVING;
|
procedure WMMoving(var aMessage : TMessage); message WM_MOVING;
|
||||||
// You also have to handle these two messages to set GlobalCEFApp.OsmodalLoop
|
// You also have to handle these two messages to set GlobalCEFApp.OsmodalLoop
|
||||||
procedure WMEnterMenuLoop(var aMessage: TMessage); message WM_ENTERMENULOOP;
|
procedure WMEnterMenuLoop(var aMessage: TMessage); message WM_ENTERMENULOOP;
|
||||||
procedure WMExitMenuLoop(var aMessage: TMessage); message WM_EXITMENULOOP;
|
procedure WMExitMenuLoop(var aMessage: TMessage); message WM_EXITMENULOOP;
|
||||||
protected
|
protected
|
||||||
// Variables to control when can we destroy the form safely
|
// Variables to control when can we destroy the form safely
|
||||||
FCanClose : boolean; // Set to True in TChromium.OnBeforeClose
|
FCanClose : boolean; // Set to True in TChromium.OnBeforeClose
|
||||||
FClosing : boolean; // Set to True in the CloseQuery event.
|
FClosing : boolean; // Set to True in the CloseQuery event.
|
||||||
|
|
||||||
procedure Chromium_OnBeforePopup(Sender: TObject; const browser: ICefBrowser; const frame: ICefFrame; const targetUrl, targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean; const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo; var client: ICefClient; var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean; var Result: Boolean);
|
procedure Chromium_OnBeforePopup(Sender: TObject; const browser: ICefBrowser; const frame: ICefFrame; const targetUrl, targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean; const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo; var client: ICefClient; var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean; var Result: Boolean);
|
||||||
@ -89,8 +89,8 @@ var
|
|||||||
implementation
|
implementation
|
||||||
|
|
||||||
{$R *.dfm}
|
{$R *.dfm}
|
||||||
|
|
||||||
uses
|
uses
|
||||||
uCEFApplication;
|
uCEFApplication;
|
||||||
|
|
||||||
// This is a demo with the simplest web browser you can build using CEF4Delphi and
|
// This is a demo with the simplest web browser you can build using CEF4Delphi and
|
||||||
@ -99,78 +99,79 @@ uses
|
|||||||
// Remember that it may take a few seconds to load if Windows update, your antivirus or
|
// Remember that it may take a few seconds to load if Windows update, your antivirus or
|
||||||
// any other windows service is using your hard drive.
|
// any other windows service is using your hard drive.
|
||||||
|
|
||||||
// Depending on your internet connection it may take longer than expected.
|
// Depending on your internet connection it may take longer than expected.
|
||||||
|
|
||||||
// Please check that your firewall or antivirus are not blocking this application
|
// Please check that your firewall or antivirus are not blocking this application
|
||||||
// or the domain "google.com". If you don't live in the US, you'll be redirected to
|
// or the domain "google.com". If you don't live in the US, you'll be redirected to
|
||||||
// another domain which will take a little time too.
|
// another domain which will take a little time too.
|
||||||
|
|
||||||
// Destruction steps
|
// Destruction steps
|
||||||
// =================
|
// =================
|
||||||
// 1. The FormCloseQuery event sets CanClose to False and calls TChromiumWindow.CloseBrowser, which triggers the TChromiumWindow.OnClose event.
|
// 1. The FormCloseQuery event sets CanClose to False and calls TChromiumWindow.CloseBrowser, which triggers the TChromiumWindow.OnClose event.
|
||||||
// 2. The TChromiumWindow.OnClose event calls TChromiumWindow.DestroyChildWindow which triggers the TChromiumWindow.OnBeforeClose event.
|
// 2. The TChromiumWindow.OnClose event calls TChromiumWindow.DestroyChildWindow which triggers the TChromiumWindow.OnBeforeClose event.
|
||||||
// 3. TChromiumWindow.OnBeforeClose sets FCanClose to True and closes the form.
|
// 3. TChromiumWindow.OnBeforeClose sets FCanClose to True and closes the form.
|
||||||
|
|
||||||
procedure TForm1.FormCloseQuery(Sender: TObject; var CanClose: Boolean);
|
procedure TForm1.FormCloseQuery(Sender: TObject; var CanClose: Boolean);
|
||||||
begin
|
begin
|
||||||
CanClose := FCanClose;
|
CanClose := FCanClose;
|
||||||
|
|
||||||
if not(FClosing) then
|
if not(FClosing) then
|
||||||
begin
|
begin
|
||||||
FClosing := True;
|
FClosing := True;
|
||||||
Visible := False;
|
Visible := False;
|
||||||
ChromiumWindow1.CloseBrowser(True);
|
ChromiumWindow1.CloseBrowser(True);
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.FormShow(Sender: TObject);
|
procedure TForm1.FormShow(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
Caption := 'Simple Browser - Initializing browser. Please wait...';
|
Caption := 'Simple Browser - Initializing browser. Please wait...';
|
||||||
ChromiumWindow1.ChromiumBrowser.OnBeforePopup := Chromium_OnBeforePopup;
|
|
||||||
|
ChromiumWindow1.ChromiumBrowser.OnBeforePopup := Chromium_OnBeforePopup;
|
||||||
// You *MUST* call CreateBrowser to create and initialize the browser.
|
|
||||||
// This will trigger the AfterCreated event when the browser is fully
|
// You *MUST* call CreateBrowser to create and initialize the browser.
|
||||||
// initialized and ready to receive commands.
|
// This will trigger the AfterCreated event when the browser is fully
|
||||||
|
// initialized and ready to receive commands.
|
||||||
// GlobalCEFApp.GlobalContextInitialized has to be TRUE before creating any browser
|
|
||||||
// If it's not initialized yet, we use a simple timer to create the browser later.
|
// GlobalCEFApp.GlobalContextInitialized has to be TRUE before creating any browser
|
||||||
|
// If it's not initialized yet, we use a simple timer to create the browser later.
|
||||||
if not(ChromiumWindow1.CreateBrowser) then Timer1.Enabled := True;
|
if not(ChromiumWindow1.CreateBrowser) then Timer1.Enabled := True;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.ChromiumWindow1Close(Sender: TObject);
|
procedure TForm1.ChromiumWindow1Close(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
// DestroyChildWindow will destroy the child window created by CEF at the top of the Z order.
|
// DestroyChildWindow will destroy the child window created by CEF at the top of the Z order.
|
||||||
if not(ChromiumWindow1.DestroyChildWindow) then
|
if not(ChromiumWindow1.DestroyChildWindow) then
|
||||||
begin
|
begin
|
||||||
FCanClose := True;
|
FCanClose := True;
|
||||||
Close;
|
Close;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.ChromiumWindow1BeforeClose(Sender: TObject);
|
procedure TForm1.ChromiumWindow1BeforeClose(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
FCanClose := True;
|
FCanClose := True;
|
||||||
Close;
|
Close;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.Chromium_OnBeforePopup(Sender: TObject;
|
procedure TForm1.Chromium_OnBeforePopup(Sender: TObject;
|
||||||
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
|
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
|
||||||
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
|
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
|
||||||
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
|
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
|
||||||
var windowInfo: TCefWindowInfo; var client: ICefClient;
|
var windowInfo: TCefWindowInfo; var client: ICefClient;
|
||||||
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
|
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
|
||||||
var Result: Boolean);
|
var Result: Boolean);
|
||||||
begin
|
begin
|
||||||
// For simplicity, this demo blocks all popup windows and new tabs
|
// For simplicity, this demo blocks all popup windows and new tabs
|
||||||
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);
|
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.ChromiumWindow1AfterCreated(Sender: TObject);
|
procedure TForm1.ChromiumWindow1AfterCreated(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
// Now the browser is fully initialized we can load the initial web page.
|
// Now the browser is fully initialized we can load the initial web page.
|
||||||
Caption := 'Simple Browser';
|
Caption := 'Simple Browser';
|
||||||
AddressPnl.Enabled := True;
|
AddressPnl.Enabled := True;
|
||||||
GoBtn.Click;
|
GoBtn.Click;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.GoBtnClick(Sender: TObject);
|
procedure TForm1.GoBtnClick(Sender: TObject);
|
||||||
@ -180,10 +181,10 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.Timer1Timer(Sender: TObject);
|
procedure TForm1.Timer1Timer(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
Timer1.Enabled := False;
|
Timer1.Enabled := False;
|
||||||
if not(ChromiumWindow1.CreateBrowser) and not(ChromiumWindow1.Initialized) then
|
if not(ChromiumWindow1.CreateBrowser) and not(ChromiumWindow1.Initialized) then
|
||||||
Timer1.Enabled := True;
|
Timer1.Enabled := True;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.WMMove(var aMessage : TWMMove);
|
procedure TForm1.WMMove(var aMessage : TWMMove);
|
||||||
@ -199,19 +200,19 @@ begin
|
|||||||
|
|
||||||
if (ChromiumWindow1 <> nil) then ChromiumWindow1.NotifyMoveOrResizeStarted;
|
if (ChromiumWindow1 <> nil) then ChromiumWindow1.NotifyMoveOrResizeStarted;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.WMEnterMenuLoop(var aMessage: TMessage);
|
procedure TForm1.WMEnterMenuLoop(var aMessage: TMessage);
|
||||||
begin
|
begin
|
||||||
inherited;
|
inherited;
|
||||||
|
|
||||||
if (aMessage.wParam = 0) and (GlobalCEFApp <> nil) then GlobalCEFApp.OsmodalLoop := True;
|
if (aMessage.wParam = 0) and (GlobalCEFApp <> nil) then GlobalCEFApp.OsmodalLoop := True;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TForm1.WMExitMenuLoop(var aMessage: TMessage);
|
procedure TForm1.WMExitMenuLoop(var aMessage: TMessage);
|
||||||
begin
|
begin
|
||||||
inherited;
|
inherited;
|
||||||
|
|
||||||
if (aMessage.wParam = 0) and (GlobalCEFApp <> nil) then GlobalCEFApp.OsmodalLoop := False;
|
if (aMessage.wParam = 0) and (GlobalCEFApp <> nil) then GlobalCEFApp.OsmodalLoop := False;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
@ -222,6 +222,10 @@ const
|
|||||||
DRAG_OPERATION_EVERY = $FFFFFFFF;
|
DRAG_OPERATION_EVERY = $FFFFFFFF;
|
||||||
|
|
||||||
// /include/internal/cef_types.h (cef_file_dialog_mode_t)
|
// /include/internal/cef_types.h (cef_file_dialog_mode_t)
|
||||||
|
FILE_DIALOG_OPEN = $00000000;
|
||||||
|
FILE_DIALOG_OPEN_MULTIPLE = $00000001;
|
||||||
|
FILE_DIALOG_OPEN_FOLDER = $00000002;
|
||||||
|
FILE_DIALOG_SAVE = $00000003;
|
||||||
FILE_DIALOG_TYPE_MASK = $000000FF;
|
FILE_DIALOG_TYPE_MASK = $000000FF;
|
||||||
FILE_DIALOG_OVERWRITEPROMPT_FLAG = $01000000;
|
FILE_DIALOG_OVERWRITEPROMPT_FLAG = $01000000;
|
||||||
FILE_DIALOG_HIDEREADONLY_FLAG = $02000000;
|
FILE_DIALOG_HIDEREADONLY_FLAG = $02000000;
|
||||||
@ -326,6 +330,12 @@ const
|
|||||||
LOGSEVERITY_ERROR = 4;
|
LOGSEVERITY_ERROR = 4;
|
||||||
LOGSEVERITY_DISABLE = 99;
|
LOGSEVERITY_DISABLE = 99;
|
||||||
|
|
||||||
|
// /include/internal/cef_types.h (cef_duplex_mode_t)
|
||||||
|
DUPLEX_MODE_UNKNOWN = -1;
|
||||||
|
DUPLEX_MODE_SIMPLEX = 0;
|
||||||
|
DUPLEX_MODE_LONG_EDGE = 1;
|
||||||
|
DUPLEX_MODE_SHORT_EDGE = 2;
|
||||||
|
|
||||||
|
|
||||||
//******************************************************
|
//******************************************************
|
||||||
//****************** OTHER CONSTANTS *******************
|
//****************** OTHER CONSTANTS *******************
|
||||||
|
@ -362,7 +362,10 @@ function CefRegisterExtension(const name, code: ustring; const Handler: ICefv8Ha
|
|||||||
var
|
var
|
||||||
TempName, TempCode : TCefString;
|
TempName, TempCode : TCefString;
|
||||||
begin
|
begin
|
||||||
if (GlobalCEFApp <> nil) and GlobalCEFApp.LibLoaded then
|
if (GlobalCEFApp <> nil) and
|
||||||
|
GlobalCEFApp.LibLoaded and
|
||||||
|
(length(name) > 0) and
|
||||||
|
(length(code) > 0) then
|
||||||
begin
|
begin
|
||||||
TempName := CefString(name);
|
TempName := CefString(name);
|
||||||
TempCode := CefString(code);
|
TempCode := CefString(code);
|
||||||
|
@ -276,6 +276,9 @@ type
|
|||||||
TCefJsonWriterOptions = Cardinal; // /include/internal/cef_types.h (cef_json_writer_options_t)
|
TCefJsonWriterOptions = Cardinal; // /include/internal/cef_types.h (cef_json_writer_options_t)
|
||||||
TCefSSLContentStatus = Cardinal; // /include/internal/cef_types.h (cef_ssl_content_status_t)
|
TCefSSLContentStatus = Cardinal; // /include/internal/cef_types.h (cef_ssl_content_status_t)
|
||||||
TCefLogSeverity = Cardinal; // /include/internal/cef_types.h (cef_log_severity_t)
|
TCefLogSeverity = Cardinal; // /include/internal/cef_types.h (cef_log_severity_t)
|
||||||
|
TCefFileDialogMode = Cardinal; // /include/internal/cef_types.h (cef_file_dialog_mode_t)
|
||||||
|
TCefDuplexMode = Integer; // /include/internal/cef_types.h (cef_duplex_mode_t)
|
||||||
|
|
||||||
|
|
||||||
{$IFDEF FPC}
|
{$IFDEF FPC}
|
||||||
NativeInt = PtrInt;
|
NativeInt = PtrInt;
|
||||||
@ -577,17 +580,6 @@ type
|
|||||||
MENUITEMTYPE_SUBMENU
|
MENUITEMTYPE_SUBMENU
|
||||||
);
|
);
|
||||||
|
|
||||||
// /include/internal/cef_types.h (cef_file_dialog_mode_t)
|
|
||||||
TCefFileDialogMode = (
|
|
||||||
FILE_DIALOG_OPEN,
|
|
||||||
FILE_DIALOG_OPEN_MULTIPLE,
|
|
||||||
FILE_DIALOG_OPEN_FOLDER,
|
|
||||||
FILE_DIALOG_SAVE,
|
|
||||||
FILE_DIALOG_TYPE_MASK = $FF,
|
|
||||||
FILE_DIALOG_OVERWRITEPROMPT_FLAG = $01000000,
|
|
||||||
FILE_DIALOG_HIDEREADONLY_FLAG = $02000000
|
|
||||||
);
|
|
||||||
|
|
||||||
// /include/internal/cef_types.h (cef_focus_source_t)
|
// /include/internal/cef_types.h (cef_focus_source_t)
|
||||||
TCefFocusSource = (
|
TCefFocusSource = (
|
||||||
FOCUS_SOURCE_NAVIGATION = 0,
|
FOCUS_SOURCE_NAVIGATION = 0,
|
||||||
@ -860,14 +852,6 @@ type
|
|||||||
COLOR_MODEL_PROCESSCOLORMODEL_RGB
|
COLOR_MODEL_PROCESSCOLORMODEL_RGB
|
||||||
);
|
);
|
||||||
|
|
||||||
// /include/internal/cef_types.h (cef_duplex_mode_t)
|
|
||||||
TCefDuplexMode = (
|
|
||||||
DUPLEX_MODE_UNKNOWN = -1,
|
|
||||||
DUPLEX_MODE_SIMPLEX,
|
|
||||||
DUPLEX_MODE_LONG_EDGE,
|
|
||||||
DUPLEX_MODE_SHORT_EDGE
|
|
||||||
);
|
|
||||||
|
|
||||||
// /include/internal/cef_types.h (cef_json_parser_options_t)
|
// /include/internal/cef_types.h (cef_json_parser_options_t)
|
||||||
TCefJsonParserOptions = (
|
TCefJsonParserOptions = (
|
||||||
JSON_PARSER_RFC = 0,
|
JSON_PARSER_RFC = 0,
|
||||||
|
@ -79,7 +79,7 @@ uses
|
|||||||
|
|
||||||
class function TCefv8ContextRef.Current: ICefv8Context;
|
class function TCefv8ContextRef.Current: ICefv8Context;
|
||||||
begin
|
begin
|
||||||
Result := UnWrap(cef_v8context_get_current_context())
|
Result := UnWrap(cef_v8context_get_current_context());
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TCefv8ContextRef.Enter: Boolean;
|
function TCefv8ContextRef.Enter: Boolean;
|
||||||
@ -89,7 +89,7 @@ end;
|
|||||||
|
|
||||||
class function TCefv8ContextRef.Entered: ICefv8Context;
|
class function TCefv8ContextRef.Entered: ICefv8Context;
|
||||||
begin
|
begin
|
||||||
Result := UnWrap(cef_v8context_get_entered_context())
|
Result := UnWrap(cef_v8context_get_entered_context());
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TCefv8ContextRef.Exit: Boolean;
|
function TCefv8ContextRef.Exit: Boolean;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user