mirror of
https://github.com/salvadordf/CEF4Delphi.git
synced 2024-11-24 08:02:15 +02:00
Fixed AV and build error in win64. Support for CEF 3.2924.1571.gcdcdfa9 and new parameter to skip reading dll version in tcefapplication
This commit is contained in:
parent
e0b50fa338
commit
e592e2716a
@ -66,6 +66,14 @@ begin
|
||||
// Uncomment the following line to change the user agent string.
|
||||
//GlobalCEFApp.AddCustomCommandLine('--user-agent', 'MiniBrowser');
|
||||
|
||||
|
||||
//GlobalCEFApp.LibCef := 'cef\libcef.dll';
|
||||
//GlobalCEFApp.FrameworkDirPath := 'k:\cef\';
|
||||
//GlobalCEFApp.ResourcesDirPath := 'k:\cef\';
|
||||
//GlobalCEFApp.LocalesDirPath := 'k:\cef\locales\';
|
||||
//GlobalCEFApp.CheckCEFFiles := False;
|
||||
|
||||
|
||||
if GlobalCEFApp.StartMainProcess then
|
||||
begin
|
||||
Application.Initialize;
|
||||
|
@ -2,10 +2,10 @@
|
||||
<BorlandProject>
|
||||
<Transactions>
|
||||
<Transaction>2017/02/11 10:15:32.000.980,=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\Unit1.pas</Transaction>
|
||||
<Transaction>2017/02/11 10:16:27.000.174,C:\Users\usuario\Documents\Embarcadero\Studio\Projects\Unit1.pas=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uMiniBrowser.pas</Transaction>
|
||||
<Transaction>2017/02/11 10:16:27.000.174,C:\Users\usuario\Documents\Embarcadero\Studio\Projects\Unit1.dfm=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uMiniBrowser.dfm</Transaction>
|
||||
<Transaction>2017/02/11 10:16:37.000.392,C:\Users\usuario\Documents\Embarcadero\Studio\Projects\Project1.dproj=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\MiniBrowser.dproj</Transaction>
|
||||
<Transaction>2017/02/11 10:16:27.000.174,C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uMiniBrowser.dfm=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\Unit1.dfm</Transaction>
|
||||
<Transaction>2017/02/11 10:16:27.000.174,C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uMiniBrowser.pas=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\Unit1.pas</Transaction>
|
||||
<Transaction>2017/02/11 10:16:37.000.392,C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\MiniBrowser.dproj=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\Project1.dproj</Transaction>
|
||||
<Transaction>2017/02/11 17:10:26.000.471,=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\Unit1.pas</Transaction>
|
||||
<Transaction>2017/02/11 17:11:01.000.244,C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uTestExtension.pas=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\Unit1.pas</Transaction>
|
||||
<Transaction>2017/02/11 17:11:01.000.244,C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\Unit1.pas=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uTestExtension.pas</Transaction>
|
||||
</Transactions>
|
||||
</BorlandProject>
|
||||
|
@ -1,31 +1,20 @@
|
||||
[Closed Files]
|
||||
File_0=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFApplication.pas',0,1,162,19,177,0,0,,
|
||||
File_1=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFChromium.pas',0,1,98,81,126,0,0,,
|
||||
File_2=TSourceModule,'V:\dcef3-2883\demos\guiclient\main.pas',0,1,489,5,526,0,0,,
|
||||
File_3=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFProcessMessage.pas',0,1,12,24,38,0,0,,
|
||||
File_4=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFv8Context.pas',0,1,27,16,43,0,0,,
|
||||
File_5=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFv8Handler.pas',0,1,13,19,38,0,0,,
|
||||
File_6=TSourceModule,'C:\Program Files\Embarcadero\Studio\17.0\Indy10\Lib\System\IdGlobal.pas',0,1,4258,21,4281,0,0,,
|
||||
File_7=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFRenderProcessHandler.pas',0,1,1,30,38,0,0,,
|
||||
File_8=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFBrowserProcessHandler.pas',0,1,7,31,38,0,0,,
|
||||
File_9=TSourceModule,'c:\program files\embarcadero\studio\17.0\SOURCE\RTL\SYS\System.Types.pas',0,1,82,1,111,0,0,,
|
||||
File_0=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFApplication.pas',0,1,738,90,771,0,0,,
|
||||
File_1=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFTypes.pas',0,1,961,23,995,0,0,,
|
||||
File_2=TSourceModule,'V:\dcef3-2883\src\ceflib.pas',0,1,2391,60,2406,0,0,,
|
||||
File_3=TSourceModule,'V:\2924\include\internal\cef_types.h',0,1,173,11,182,0,0,,
|
||||
File_4=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uTestExtension.pas',0,1,1,61,103,0,0,,
|
||||
File_5=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFMiscFunctions.pas',0,1,397,11,431,0,0,,
|
||||
File_6=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFLibFunctions.pas',0,1,200,75,229,0,0,,
|
||||
File_7=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFConstants.pas',0,1,208,11,248,0,0,,
|
||||
File_8=TSourceModule,'c:\program files\embarcadero\studio\17.0\SOURCE\RTL\SYS\System.pas',0,1,29880,1,29902,0,0,,
|
||||
|
||||
[Modules]
|
||||
Module0=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\MiniBrowser.dproj
|
||||
Module1=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uTestExtension.pas
|
||||
Module2=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uMiniBrowser.pas
|
||||
Module3=default.htm
|
||||
Count=4
|
||||
Module0=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uMiniBrowser.pas
|
||||
Module1=default.htm
|
||||
Count=2
|
||||
EditWindowCount=1
|
||||
|
||||
[C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\MiniBrowser.dproj]
|
||||
ModuleType=TBaseProject
|
||||
|
||||
[C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uTestExtension.pas]
|
||||
ModuleType=TSourceModule
|
||||
FormState=0
|
||||
FormOnTop=0
|
||||
|
||||
[C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uMiniBrowser.pas]
|
||||
ModuleType=TSourceModule
|
||||
FormState=1
|
||||
@ -35,12 +24,10 @@ FormOnTop=0
|
||||
ModuleType=TURLModule
|
||||
|
||||
[EditWindow0]
|
||||
ViewCount=4
|
||||
CurrentEditView=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\MiniBrowser.dpr
|
||||
ViewCount=2
|
||||
CurrentEditView=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uMiniBrowser.pas
|
||||
View0=0
|
||||
View1=1
|
||||
View2=2
|
||||
View3=3
|
||||
PercentageSizes=1
|
||||
Create=1
|
||||
Visible=1
|
||||
@ -57,18 +44,18 @@ ClientHeight=9428
|
||||
DockedToMainForm=1
|
||||
BorlandEditorCodeExplorer=BorlandEditorCodeExplorer@EditWindow0
|
||||
TopPanelSize=0
|
||||
LeftPanelSize=0
|
||||
LeftPanelSize=1898
|
||||
LeftPanelClients=PropertyInspector,DockSite3
|
||||
LeftPanelData=00000800010100000000AA19000000000000016A0700000000000001000000005D0E000009000000446F636B53697465330100000000A12300001100000050726F7065727479496E73706563746F72FFFFFFFF
|
||||
RightPanelSize=2000
|
||||
RightPanelClients=DockSite2
|
||||
RightPanelData=00000800010100000000AA1900000000000001D0070000000000000100000000A123000009000000446F636B5369746532FFFFFFFF
|
||||
RightPanelClients=DockSite2,DockSite4
|
||||
RightPanelData=00000800010100000000AA1900000000000001D00700000000000001000000004312000009000000446F636B53697465320100000000A123000009000000446F636B5369746534FFFFFFFF
|
||||
BottomPanelSize=0
|
||||
BottomPanelClients=DockSite1,MessageView
|
||||
BottomPanelData=0000080001020200000009000000446F636B53697465310F0000004D65737361676556696577466F726D1234000000000000022506000000000000FFFFFFFF
|
||||
BottomMiddlePanelSize=0
|
||||
BottomMiddlePanelClients=DockSite0,GraphDrawingModel
|
||||
BottomMiddelPanelData=0000080001020200000009000000446F636B536974653010000000477261706844726177696E67566965779D1D00000000000002F306000000000000FFFFFFFF
|
||||
TabDockLeftClients=PropertyInspector=0,DockSite3=1
|
||||
TabDockRightClients=DockSite4=0
|
||||
|
||||
[View0]
|
||||
CustomEditViewType=TWelcomePageView
|
||||
@ -76,37 +63,15 @@ WelcomePageURL=bds:/default.htm
|
||||
|
||||
[View1]
|
||||
CustomEditViewType=TEditView
|
||||
Module=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\MiniBrowser.dpr
|
||||
CursorX=57
|
||||
CursorY=67
|
||||
TopLine=28
|
||||
LeftCol=1
|
||||
Elisions=
|
||||
Bookmarks=
|
||||
EditViewName=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\MiniBrowser.dpr
|
||||
|
||||
[View2]
|
||||
CustomEditViewType=TEditView
|
||||
Module=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uMiniBrowser.pas
|
||||
CursorX=69
|
||||
CursorY=181
|
||||
TopLine=38
|
||||
CursorX=45
|
||||
CursorY=268
|
||||
TopLine=233
|
||||
LeftCol=1
|
||||
Elisions=
|
||||
Bookmarks=
|
||||
EditViewName=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uMiniBrowser.pas
|
||||
|
||||
[View3]
|
||||
CustomEditViewType=TEditView
|
||||
Module=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uTestExtension.pas
|
||||
CursorX=61
|
||||
CursorY=103
|
||||
TopLine=31
|
||||
LeftCol=1
|
||||
Elisions=
|
||||
Bookmarks=
|
||||
EditViewName=C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\demos\MiniBrowser\uTestExtension.pas
|
||||
|
||||
[Watches]
|
||||
Count=0
|
||||
|
||||
@ -169,11 +134,11 @@ State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Width=2000
|
||||
Height=8868
|
||||
Height=4226
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=2000
|
||||
ClientHeight=8868
|
||||
ClientHeight=4226
|
||||
TBDockHeight=5897
|
||||
LRDockWidth=2352
|
||||
Dockable=1
|
||||
@ -206,12 +171,12 @@ Docked=1
|
||||
State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Width=1875
|
||||
Height=6738
|
||||
Width=2000
|
||||
Height=4339
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=1875
|
||||
ClientHeight=6738
|
||||
ClientWidth=2000
|
||||
ClientHeight=4339
|
||||
TBDockHeight=7152
|
||||
LRDockWidth=2000
|
||||
Dockable=1
|
||||
@ -261,8 +226,8 @@ Create=1
|
||||
Visible=0
|
||||
Docked=1
|
||||
State=0
|
||||
Left=-8
|
||||
Top=-30
|
||||
Left=-121
|
||||
Top=-74
|
||||
Width=1844
|
||||
Height=3139
|
||||
MaxLeft=-1
|
||||
@ -315,18 +280,18 @@ StayOnTop=0
|
||||
[PropertyInspector]
|
||||
PercentageSizes=1
|
||||
Create=1
|
||||
Visible=0
|
||||
Visible=1
|
||||
Docked=1
|
||||
State=0
|
||||
Left=78
|
||||
Top=386
|
||||
Left=0
|
||||
Top=362
|
||||
Width=1898
|
||||
Height=7164
|
||||
Height=5370
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=1898
|
||||
ClientHeight=7164
|
||||
TBDockHeight=7164
|
||||
ClientHeight=5370
|
||||
TBDockHeight=7119
|
||||
LRDockWidth=1898
|
||||
Dockable=1
|
||||
StayOnTop=0
|
||||
@ -376,8 +341,8 @@ Create=1
|
||||
Visible=0
|
||||
Docked=1
|
||||
State=0
|
||||
Left=-8
|
||||
Top=287
|
||||
Left=-1152
|
||||
Top=243
|
||||
Width=273
|
||||
Height=359
|
||||
MaxLeft=-1
|
||||
@ -609,12 +574,12 @@ Docked=1
|
||||
State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Width=1773
|
||||
Height=6738
|
||||
Width=1898
|
||||
Height=3498
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=1773
|
||||
ClientHeight=6738
|
||||
ClientWidth=1898
|
||||
ClientHeight=3498
|
||||
TBDockHeight=3677
|
||||
LRDockWidth=1898
|
||||
Dockable=1
|
||||
@ -720,12 +685,12 @@ State=0
|
||||
Left=0
|
||||
Top=23
|
||||
Width=2000
|
||||
Height=9170
|
||||
Height=4529
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=2000
|
||||
ClientHeight=9170
|
||||
TBDockHeight=7164
|
||||
ClientHeight=4529
|
||||
TBDockHeight=7119
|
||||
LRDockWidth=2000
|
||||
Dockable=1
|
||||
StayOnTop=0
|
||||
@ -734,22 +699,22 @@ ActiveTabID=ProjectManager
|
||||
TabDockClients=ProjectManager,ModelViewTool,DataExplorerContainer,frmDesignPreview,TFileExplorerForm
|
||||
|
||||
[DockSite3]
|
||||
HostDockSite=LeftDockTabSet
|
||||
HostDockSite=DockLeftPanel
|
||||
DockSiteType=1
|
||||
PercentageSizes=1
|
||||
Create=1
|
||||
Visible=0
|
||||
Visible=1
|
||||
Docked=1
|
||||
State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Top=23
|
||||
Width=1898
|
||||
Height=7164
|
||||
Height=3498
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=1773
|
||||
ClientHeight=6738
|
||||
TBDockHeight=7164
|
||||
ClientWidth=1898
|
||||
ClientHeight=3498
|
||||
TBDockHeight=7119
|
||||
LRDockWidth=1898
|
||||
Dockable=1
|
||||
StayOnTop=0
|
||||
@ -758,22 +723,22 @@ ActiveTabID=StructureView
|
||||
TabDockClients=StructureView,ClassBrowserTool
|
||||
|
||||
[DockSite4]
|
||||
HostDockSite=RightTabDock
|
||||
HostDockSite=DockRightPanel
|
||||
DockSiteType=1
|
||||
PercentageSizes=1
|
||||
Create=1
|
||||
Visible=0
|
||||
Visible=1
|
||||
Docked=1
|
||||
State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Top=454
|
||||
Width=2000
|
||||
Height=7164
|
||||
Height=4339
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=1875
|
||||
ClientHeight=6738
|
||||
TBDockHeight=7164
|
||||
ClientWidth=2000
|
||||
ClientHeight=4339
|
||||
TBDockHeight=7119
|
||||
LRDockWidth=2000
|
||||
Dockable=1
|
||||
StayOnTop=0
|
||||
|
@ -1,10 +1,10 @@
|
||||
[Stats]
|
||||
EditorSecs=5349
|
||||
EditorSecs=8825
|
||||
DesignerSecs=233
|
||||
InspectorSecs=236
|
||||
CompileSecs=138273
|
||||
OtherSecs=631
|
||||
CompileSecs=450273
|
||||
OtherSecs=1279
|
||||
StartTime=11/02/2017 10:51:15
|
||||
RealKeys=0
|
||||
EffectiveKeys=0
|
||||
DebugSecs=988
|
||||
DebugSecs=2514
|
||||
|
@ -171,7 +171,7 @@ procedure TMiniBrowserFrm.Chromium1ContextMenuCommand(Sender: TObject;
|
||||
const params: ICefContextMenuParams; commandId: Integer;
|
||||
eventFlags: TCefEventFlags; out Result: Boolean);
|
||||
var
|
||||
TempPoint : TSmallPoint;
|
||||
TempParam : WParam;
|
||||
begin
|
||||
Result := False;
|
||||
|
||||
@ -181,9 +181,8 @@ begin
|
||||
|
||||
MINIBROWSER_CONTEXTMENU_SHOWDEVTOOLS :
|
||||
begin
|
||||
TempPoint.x := params.XCoord;
|
||||
TempPoint.y := params.YCoord;
|
||||
PostMessage(Handle, MINIBROWSER_SHOWDEVTOOLS, wParam(TempPoint), 0);
|
||||
TempParam := ((params.XCoord and $FFFF) shl 16) or (params.YCoord and $FFFF);
|
||||
PostMessage(Handle, MINIBROWSER_SHOWDEVTOOLS, TempParam, 0);
|
||||
end;
|
||||
|
||||
MINIBROWSER_CONTEXTMENU_SHOWJSALERT :
|
||||
@ -260,8 +259,12 @@ begin
|
||||
end;
|
||||
|
||||
procedure TMiniBrowserFrm.ShowDevToolsMsg(var aMessage : TMessage);
|
||||
var
|
||||
TempPoint : TPoint;
|
||||
begin
|
||||
ShowDevTools(SmallPointToPoint(TSmallPoint(aMessage.wParam)));
|
||||
TempPoint.x := (aMessage.wParam shr 16) and $FFFF;
|
||||
TempPoint.y := aMessage.wParam and $FFFF;
|
||||
ShowDevTools(TempPoint);
|
||||
end;
|
||||
|
||||
procedure TMiniBrowserFrm.HideDevToolsMsg(var aMessage : TMessage);
|
||||
@ -282,7 +285,7 @@ begin
|
||||
Chromium1.CloseDevTools(DevTools);
|
||||
Splitter1.Visible := False;
|
||||
DevTools.Visible := False;
|
||||
DevTools.Width := 0;
|
||||
DevTools.Width := 0;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
@ -255,7 +255,16 @@
|
||||
<Overwrite>true</Overwrite>
|
||||
</Platform>
|
||||
</DeployFile>
|
||||
<DeployClass Name="ProjectiOSDeviceResourceRules"/>
|
||||
<DeployClass Name="DependencyModule">
|
||||
<Platform Name="Win32">
|
||||
<Operation>0</Operation>
|
||||
<Extensions>.dll;.bpl</Extensions>
|
||||
</Platform>
|
||||
<Platform Name="OSX32">
|
||||
<Operation>1</Operation>
|
||||
<Extensions>.dylib</Extensions>
|
||||
</Platform>
|
||||
</DeployClass>
|
||||
<DeployClass Name="ProjectOSXResource">
|
||||
<Platform Name="OSX32">
|
||||
<RemoteDir>Contents\Resources</RemoteDir>
|
||||
@ -569,16 +578,7 @@
|
||||
<Operation>1</Operation>
|
||||
</Platform>
|
||||
</DeployClass>
|
||||
<DeployClass Name="DependencyModule">
|
||||
<Platform Name="Win32">
|
||||
<Operation>0</Operation>
|
||||
<Extensions>.dll;.bpl</Extensions>
|
||||
</Platform>
|
||||
<Platform Name="OSX32">
|
||||
<Operation>1</Operation>
|
||||
<Extensions>.dylib</Extensions>
|
||||
</Platform>
|
||||
</DeployClass>
|
||||
<DeployClass Name="ProjectiOSDeviceResourceRules"/>
|
||||
<ProjectRoot Platform="iOSDevice64" Name="$(PROJECTNAME).app"/>
|
||||
<ProjectRoot Platform="Win64" Name="$(PROJECTNAME)"/>
|
||||
<ProjectRoot Platform="iOSDevice32" Name="$(PROJECTNAME).app"/>
|
||||
|
@ -1,14 +1,14 @@
|
||||
[Closed Files]
|
||||
File_0=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFApplication.pas',0,1,267,67,315,0,0,,
|
||||
File_1=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFTypes.pas',0,1,984,49,1017,0,0,,
|
||||
File_2=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFLibFunctions.pas',0,1,31,85,45,0,0,,
|
||||
File_3=TSourceModule,'V:\2924\include\internal\cef_types.h',0,1,295,51,318,0,0,,{1
|
||||
File_4=TSourceModule,'V:\2924\include\capi\cef_app_capi.h',0,1,100,1,1,0,0,,
|
||||
File_5=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFConstants.pas',0,1,55,18,89,0,0,,
|
||||
File_6=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFWebPluginUnstableCallback.pas',0,1,1,1,1,0,0,,
|
||||
File_7=TSourceModule,'V:\source_D7\uCEFWebPluginUnstableCallback.pas',0,1,1,1,1,0,0,,
|
||||
File_8=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFv8Types.pas',0,1,16,1,1,0,0,,
|
||||
File_9=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFv8Handler.pas',0,1,34,57,81,0,0,,
|
||||
File_0=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFApplication.pas',0,1,262,53,297,0,0,,
|
||||
File_1=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFChromium.pas',0,1,2030,67,2056,0,0,,{1
|
||||
File_2=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFMiscFunctions.pas',0,1,191,46,218,0,0,,
|
||||
File_3=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFTypes.pas',0,1,216,3,246,0,0,,
|
||||
File_4=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFLibFunctions.pas',0,1,40,3,69,0,0,,
|
||||
File_5=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFRequestContextHandler.pas',0,1,31,43,57,0,0,,
|
||||
File_6=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFRequestContext.pas',0,1,59,16,65,0,0,,
|
||||
File_7=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFCookieManager.pas',0,1,49,3,58,0,0,,
|
||||
File_8=TSourceModule,'C:\Users\usuario\Documents\Embarcadero\Studio\Projects\CEF4Delphi\source\uCEFInterfaces.pas',0,1,877,20,897,0,0,,
|
||||
File_9=TSourceModule,'C:\Program Files\Embarcadero\Studio\17.0\Componentes\misc\uMiscFunctions.pas',0,1,6055,26,6083,0,0,,
|
||||
|
||||
[Modules]
|
||||
Module0=default.htm
|
||||
@ -38,7 +38,9 @@ ClientHeight=9428
|
||||
DockedToMainForm=1
|
||||
BorlandEditorCodeExplorer=BorlandEditorCodeExplorer@EditWindow0
|
||||
TopPanelSize=0
|
||||
LeftPanelSize=0
|
||||
LeftPanelSize=1898
|
||||
LeftPanelClients=PropertyInspector,DockSite3
|
||||
LeftPanelData=00000800010100000000AA19000000000000016A0700000000000001000000005D0E000009000000446F636B53697465330100000000A12300001100000050726F7065727479496E73706563746F72FFFFFFFF
|
||||
RightPanelSize=2000
|
||||
RightPanelClients=DockSite2,DockSite4
|
||||
RightPanelData=00000800010100000000AA1900000000000001D00700000000000001000000004312000009000000446F636B53697465320100000000A123000009000000446F636B5369746534FFFFFFFF
|
||||
@ -48,7 +50,6 @@ BottomPanelData=0000080001020200000009000000446F636B53697465310F0000004D65737361
|
||||
BottomMiddlePanelSize=0
|
||||
BottomMiddlePanelClients=DockSite0,GraphDrawingModel
|
||||
BottomMiddelPanelData=0000080001020200000009000000446F636B536974653010000000477261706844726177696E67566965779D1D00000000000002F306000000000000FFFFFFFF
|
||||
TabDockLeftClients=PropertyInspector=0,DockSite3=1
|
||||
|
||||
[View0]
|
||||
CustomEditViewType=TWelcomePageView
|
||||
@ -208,8 +209,8 @@ Create=1
|
||||
Visible=0
|
||||
Docked=1
|
||||
State=0
|
||||
Left=-8
|
||||
Top=-30
|
||||
Left=-148
|
||||
Top=-137
|
||||
Width=1844
|
||||
Height=3139
|
||||
MaxLeft=-1
|
||||
@ -262,17 +263,17 @@ StayOnTop=0
|
||||
[PropertyInspector]
|
||||
PercentageSizes=1
|
||||
Create=1
|
||||
Visible=0
|
||||
Visible=1
|
||||
Docked=1
|
||||
State=0
|
||||
Left=78
|
||||
Top=386
|
||||
Left=0
|
||||
Top=362
|
||||
Width=1898
|
||||
Height=7164
|
||||
Height=5370
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=1898
|
||||
ClientHeight=7164
|
||||
ClientHeight=5370
|
||||
TBDockHeight=7164
|
||||
LRDockWidth=1898
|
||||
Dockable=1
|
||||
@ -288,11 +289,11 @@ State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Width=2000
|
||||
Height=6816
|
||||
Height=6861
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=2000
|
||||
ClientHeight=6816
|
||||
ClientHeight=6861
|
||||
TBDockHeight=5964
|
||||
LRDockWidth=2508
|
||||
Dockable=1
|
||||
@ -304,8 +305,8 @@ Create=1
|
||||
Visible=0
|
||||
Docked=1
|
||||
State=0
|
||||
Left=-946
|
||||
Top=1
|
||||
Left=-898
|
||||
Top=-137
|
||||
Width=2844
|
||||
Height=6200
|
||||
MaxLeft=-1
|
||||
@ -323,8 +324,8 @@ Create=1
|
||||
Visible=0
|
||||
Docked=1
|
||||
State=0
|
||||
Left=-1152
|
||||
Top=243
|
||||
Left=-1026
|
||||
Top=-137
|
||||
Width=273
|
||||
Height=359
|
||||
MaxLeft=-1
|
||||
@ -428,11 +429,11 @@ State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Width=2336
|
||||
Height=942
|
||||
Height=1177
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=2336
|
||||
ClientHeight=942
|
||||
ClientHeight=1177
|
||||
TBDockHeight=2321
|
||||
LRDockWidth=2820
|
||||
Dockable=1
|
||||
@ -493,11 +494,11 @@ State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Width=2000
|
||||
Height=6816
|
||||
Height=6861
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=2000
|
||||
ClientHeight=6816
|
||||
ClientHeight=6861
|
||||
TBDockHeight=4888
|
||||
LRDockWidth=7148
|
||||
Dockable=1
|
||||
@ -509,8 +510,8 @@ Create=1
|
||||
Visible=0
|
||||
Docked=1
|
||||
State=0
|
||||
Left=249
|
||||
Top=709
|
||||
Left=0
|
||||
Top=0
|
||||
Width=2859
|
||||
Height=3206
|
||||
MaxLeft=-1
|
||||
@ -556,12 +557,12 @@ Docked=1
|
||||
State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Width=1773
|
||||
Height=6738
|
||||
Width=1898
|
||||
Height=3498
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=1773
|
||||
ClientHeight=6738
|
||||
ClientWidth=1898
|
||||
ClientHeight=3498
|
||||
TBDockHeight=3677
|
||||
LRDockWidth=1898
|
||||
Dockable=1
|
||||
@ -576,11 +577,11 @@ State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Width=2000
|
||||
Height=6816
|
||||
Height=6861
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=2000
|
||||
ClientHeight=6816
|
||||
ClientHeight=6861
|
||||
TBDockHeight=4888
|
||||
LRDockWidth=5305
|
||||
Dockable=1
|
||||
@ -641,7 +642,7 @@ Visible=0
|
||||
Docked=1
|
||||
State=0
|
||||
Left=0
|
||||
Top=23
|
||||
Top=0
|
||||
Width=3820
|
||||
Height=1424
|
||||
MaxLeft=-1
|
||||
@ -672,7 +673,7 @@ MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=2000
|
||||
ClientHeight=4529
|
||||
TBDockHeight=7119
|
||||
TBDockHeight=7164
|
||||
LRDockWidth=2000
|
||||
Dockable=1
|
||||
StayOnTop=0
|
||||
@ -681,21 +682,21 @@ ActiveTabID=ProjectManager
|
||||
TabDockClients=ProjectManager,ModelViewTool,DataExplorerContainer,frmDesignPreview,TFileExplorerForm
|
||||
|
||||
[DockSite3]
|
||||
HostDockSite=LeftDockTabSet
|
||||
HostDockSite=DockLeftPanel
|
||||
DockSiteType=1
|
||||
PercentageSizes=1
|
||||
Create=1
|
||||
Visible=0
|
||||
Visible=1
|
||||
Docked=1
|
||||
State=0
|
||||
Left=0
|
||||
Top=0
|
||||
Top=23
|
||||
Width=1898
|
||||
Height=7164
|
||||
Height=3498
|
||||
MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=1773
|
||||
ClientHeight=6738
|
||||
ClientWidth=1898
|
||||
ClientHeight=3498
|
||||
TBDockHeight=7164
|
||||
LRDockWidth=1898
|
||||
Dockable=1
|
||||
@ -720,7 +721,7 @@ MaxLeft=-1
|
||||
MaxTop=-1
|
||||
ClientWidth=2000
|
||||
ClientHeight=4339
|
||||
TBDockHeight=7119
|
||||
TBDockHeight=7164
|
||||
LRDockWidth=2000
|
||||
Dockable=1
|
||||
StayOnTop=0
|
||||
|
Binary file not shown.
@ -1,9 +1,9 @@
|
||||
[Stats]
|
||||
EditorSecs=36202
|
||||
EditorSecs=39830
|
||||
DesignerSecs=14
|
||||
InspectorSecs=9
|
||||
CompileSecs=689217
|
||||
OtherSecs=3488
|
||||
CompileSecs=812456
|
||||
OtherSecs=4166
|
||||
StartTime=22/01/2017 10:49:52
|
||||
RealKeys=0
|
||||
EffectiveKeys=0
|
||||
|
@ -113,6 +113,8 @@ type
|
||||
FBrowserProcessHandler : ICefBrowserProcessHandler;
|
||||
FRenderProcessHandler : ICefRenderProcessHandler;
|
||||
FLibCef : string;
|
||||
FChromeElf : string;
|
||||
FAppSettings : TCefSettings;
|
||||
|
||||
function LoadCEFlibrary : boolean;
|
||||
function Load_cef_app_capi_h : boolean;
|
||||
@ -181,7 +183,7 @@ type
|
||||
procedure App_OnGetRenderProcessHandler(var aCefRenderProcessHandler : ICefRenderProcessHandler);
|
||||
|
||||
public
|
||||
constructor Create;
|
||||
constructor Create(aUpdateChromeVer : boolean = True);
|
||||
destructor Destroy; override;
|
||||
procedure AfterConstruction; override;
|
||||
procedure AddCustomCommandLine(const aCommandLine : string; const aValue : string = '');
|
||||
@ -288,11 +290,16 @@ uses
|
||||
const
|
||||
CEF_SUPPORTED_VERSION_MAJOR = 3;
|
||||
CEF_SUPPORTED_VERSION_MINOR = 2924;
|
||||
CEF_SUPPORTED_VERSION_RELEASE = 1569;
|
||||
CEF_SUPPORTED_VERSION_RELEASE = 1571;
|
||||
CEF_SUPPORTED_VERSION_BUILD = 0;
|
||||
|
||||
CEF_CHROMEELF_VERSION_MAJOR = 56;
|
||||
CEF_CHROMEELF_VERSION_MINOR = 0;
|
||||
CEF_CHROMEELF_VERSION_RELEASE = 2924;
|
||||
CEF_CHROMEELF_VERSION_BUILD = 76;
|
||||
|
||||
constructor TCefApplication.Create;
|
||||
|
||||
constructor TCefApplication.Create(aUpdateChromeVer : boolean);
|
||||
begin
|
||||
inherited Create;
|
||||
|
||||
@ -342,8 +349,17 @@ begin
|
||||
FRenderProcessHandler := nil;
|
||||
FLibLoaded := False;
|
||||
FLibCef := 'libcef.dll';
|
||||
FChromeElf := 'chrome_elf.dll';
|
||||
|
||||
UpdateChromeVersionInfo;
|
||||
FAppSettings.size := SizeOf(TCefSettings);
|
||||
FillChar(FAppSettings, FAppSettings.size, 0);
|
||||
|
||||
FChromeVersionInfo.MajorVer := CEF_CHROMEELF_VERSION_MAJOR;
|
||||
FChromeVersionInfo.MinorVer := CEF_CHROMEELF_VERSION_MINOR;
|
||||
FChromeVersionInfo.Release := CEF_CHROMEELF_VERSION_RELEASE;
|
||||
FChromeVersionInfo.Build := CEF_CHROMEELF_VERSION_BUILD;
|
||||
|
||||
if aUpdateChromeVer then UpdateChromeVersionInfo;
|
||||
|
||||
IsMultiThread := True;
|
||||
|
||||
@ -623,8 +639,8 @@ begin
|
||||
else
|
||||
TempDir := '';
|
||||
|
||||
Result := FileExists('chrome_elf.dll') and
|
||||
FileExists(FLibCef) and
|
||||
Result := FileExists(FChromeElf) and
|
||||
FileExists(FLibCef) and
|
||||
FileExists(TempDir + 'd3dcompiler_43.dll') and
|
||||
FileExists(TempDir + 'd3dcompiler_47.dll') and
|
||||
FileExists(TempDir + 'libEGL.dll') and
|
||||
@ -670,9 +686,9 @@ var
|
||||
TempVersion : uint64;
|
||||
begin
|
||||
try
|
||||
if FileExists('chrome_elf.dll') then
|
||||
if FileExists(FChromeElf) then
|
||||
begin
|
||||
TempVersion := GetFileVersion('chrome_elf.dll');
|
||||
TempVersion := GetFileVersion(FChromeElf);
|
||||
UInt64ToFileVersionInfo(TempVersion, FChromeVersionInfo);
|
||||
end;
|
||||
except
|
||||
@ -762,8 +778,6 @@ begin
|
||||
end;
|
||||
|
||||
function TCefApplication.InitializeLibrary : boolean;
|
||||
var
|
||||
TempSettings : TCefSettings;
|
||||
begin
|
||||
Result := False;
|
||||
|
||||
@ -771,8 +785,8 @@ begin
|
||||
if FDeleteCache then DeleteDirContents(FCache);
|
||||
if FDeleteCookies then DeleteDirContents(FCookies);
|
||||
|
||||
InitializeSettings(TempSettings);
|
||||
Result := (cef_initialize(@HInstance, @TempSettings, FApp.Wrap, FWindowsSandboxInfo) <> 0);
|
||||
InitializeSettings(FAppSettings);
|
||||
Result := (cef_initialize(@HInstance, @FAppSettings, FApp.Wrap, FWindowsSandboxInfo) <> 0);
|
||||
except
|
||||
on e : exception do
|
||||
OutputDebugMessage('TCefApplication.InitializeLibrary error: ' + e.Message);
|
||||
|
@ -98,6 +98,10 @@ type
|
||||
FIsOSR : boolean;
|
||||
FInitialized : boolean;
|
||||
FClosing : boolean;
|
||||
FWindowInfo : TCefWindowInfo;
|
||||
FBrowserSettings : TCefBrowserSettings;
|
||||
FDevWindowInfo : TCefWindowInfo;
|
||||
FDevBrowserSettings : TCefBrowserSettings;
|
||||
|
||||
// ICefClient
|
||||
FOnProcessMessageReceived : TOnProcessMessageReceived;
|
||||
@ -638,6 +642,12 @@ begin
|
||||
FProxyScriptURL := '';
|
||||
FProxyByPassList := '';
|
||||
|
||||
FillChar(FWindowInfo, SizeOf(TCefWindowInfo), 0);
|
||||
FillChar(FDevWindowInfo, SizeOf(TCefWindowInfo), 0);
|
||||
|
||||
InitializeSettings(FBrowserSettings);
|
||||
InitializeSettings(FDevBrowserSettings);
|
||||
|
||||
InitializeEvents;
|
||||
|
||||
inherited Create(AOwner);
|
||||
@ -829,9 +839,6 @@ begin
|
||||
end;
|
||||
|
||||
function TChromium.CreateBrowser(const aBrowserParent : TWinControl; const aWindowName : string) : boolean;
|
||||
var
|
||||
TempInfo : TCefWindowInfo;
|
||||
TempSettings : TCefBrowserSettings;
|
||||
begin
|
||||
Result := False;
|
||||
|
||||
@ -842,19 +849,19 @@ begin
|
||||
(GlobalCEFApp <> nil) and
|
||||
CreateClientHandler(aBrowserParent = nil) then
|
||||
begin
|
||||
GetSettings(TempSettings);
|
||||
GetSettings(FBrowserSettings);
|
||||
|
||||
if FIsOSR then
|
||||
WindowInfoAsWindowless(TempInfo, FCompHandle, False, aWindowName)
|
||||
WindowInfoAsWindowless(FWindowInfo, FCompHandle, False, aWindowName)
|
||||
else
|
||||
WindowInfoAsChild(TempInfo, aBrowserParent.Handle, aBrowserParent.ClientRect, aWindowName);
|
||||
WindowInfoAsChild(FWindowInfo, aBrowserParent.Handle, aBrowserParent.ClientRect, aWindowName);
|
||||
|
||||
|
||||
if MultithreadApp then
|
||||
Result := CreateBrowserHost(@TempInfo, FDefaultUrl, @TempSettings, nil)
|
||||
Result := CreateBrowserHost(@FWindowInfo, FDefaultUrl, @FBrowserSettings, nil)
|
||||
else
|
||||
begin
|
||||
FBrowser := CreateBrowserHostSync(@TempInfo, FDefaultUrl, @TempSettings, nil);
|
||||
FBrowser := CreateBrowserHostSync(@FWindowInfo, FDefaultUrl, @FBrowserSettings, nil);
|
||||
|
||||
if (FBrowser <> nil) then
|
||||
begin
|
||||
@ -2031,19 +2038,16 @@ end;
|
||||
|
||||
procedure TChromium.ShowDevTools(inspectElementAt: TPoint; const aDevTools : TWinControl);
|
||||
var
|
||||
TempInfo : TCefWindowInfo;
|
||||
TempSettings : TCefBrowserSettings;
|
||||
TempPoint : TCefPoint;
|
||||
TempPPoint : PCefPoint;
|
||||
begin
|
||||
if not(Initialized) or HasDevTools then Exit;
|
||||
|
||||
InitializeSettings(TempSettings);
|
||||
InitializeSettings(FDevBrowserSettings);
|
||||
|
||||
if (aDevTools <> nil) then
|
||||
WindowInfoAsChild(TempInfo, aDevTools.Handle, aDevTools.ClientRect, aDevTools.Name)
|
||||
WindowInfoAsChild(FDevWindowInfo, aDevTools.Handle, aDevTools.ClientRect, aDevTools.Name)
|
||||
else
|
||||
WindowInfoAsPopUp(TempInfo, WindowHandle, DEVTOOLS_WINDOWNAME);
|
||||
WindowInfoAsPopUp(FDevWindowInfo, WindowHandle, DEVTOOLS_WINDOWNAME);
|
||||
|
||||
|
||||
if (inspectElementAt.x <> low(integer)) and
|
||||
@ -2051,12 +2055,11 @@ begin
|
||||
begin
|
||||
TempPoint.x := inspectElementAt.x;
|
||||
TempPoint.y := inspectElementAt.y;
|
||||
TempPPoint := @TempPoint;
|
||||
|
||||
FBrowser.Host.ShowDevTools(@FDevWindowInfo, TCefClientOwn.Create as ICefClient, @FDevBrowserSettings, @TempPoint);
|
||||
end
|
||||
else
|
||||
TempPPoint := nil;
|
||||
|
||||
FBrowser.Host.ShowDevTools(@TempInfo, TCefClientOwn.Create as ICefClient, @TempSettings, TempPPoint);
|
||||
FBrowser.Host.ShowDevTools(@FDevWindowInfo, TCefClientOwn.Create as ICefClient, @FDevBrowserSettings, nil);
|
||||
end;
|
||||
|
||||
procedure TChromium.CloseDevTools(const aDevTools : TWinControl);
|
||||
|
@ -209,7 +209,7 @@ end;
|
||||
|
||||
function CefString(const str: PCefString): ustring;
|
||||
begin
|
||||
if str <> nil then
|
||||
if (str <> nil) then
|
||||
SetString(Result, str.str, str.length)
|
||||
else
|
||||
Result := '';
|
||||
@ -217,53 +217,50 @@ end;
|
||||
|
||||
function CefString(const str: ustring): TCefString;
|
||||
begin
|
||||
Result.str := PChar16(PWideChar(str));
|
||||
Result.str := PChar16(PWideChar(str));
|
||||
Result.length := Length(str);
|
||||
Result.dtor := nil;
|
||||
Result.dtor := nil;
|
||||
end;
|
||||
|
||||
procedure CefStringFree(const str: PCefString);
|
||||
begin
|
||||
if str <> nil then
|
||||
cef_string_utf16_clear(str);
|
||||
if (str <> nil) then cef_string_utf16_clear(str);
|
||||
end;
|
||||
|
||||
procedure CefStringSet(const str: PCefString; const value: ustring);
|
||||
begin
|
||||
if str <> nil then
|
||||
cef_string_utf16_set(PWideChar(value), Length(value), str, 1);
|
||||
if (str <> nil) then cef_string_utf16_set(PWideChar(value), Length(value), str, 1);
|
||||
end;
|
||||
|
||||
function CefStringFreeAndGet(const str: PCefStringUserFree): ustring;
|
||||
begin
|
||||
if str <> nil then
|
||||
begin
|
||||
Result := CefString(PCefString(str));
|
||||
cef_string_userfree_utf16_free(str);
|
||||
end else
|
||||
if (str <> nil) then
|
||||
begin
|
||||
Result := CefString(PCefString(str));
|
||||
cef_string_userfree_utf16_free(str);
|
||||
end
|
||||
else
|
||||
Result := '';
|
||||
end;
|
||||
|
||||
function CefStringAlloc(const str: ustring): TCefString;
|
||||
begin
|
||||
FillChar(Result, SizeOf(Result), 0);
|
||||
if str <> '' then
|
||||
cef_string_wide_to_utf16(PWideChar(str), Length(str), @Result);
|
||||
if (str <> '') then cef_string_wide_to_utf16(PWideChar(str), Length(str), @Result);
|
||||
end;
|
||||
|
||||
procedure _free_string(str: PChar16); stdcall;
|
||||
begin
|
||||
if str <> nil then
|
||||
FreeMem(str);
|
||||
if (str <> nil) then FreeMem(str);
|
||||
end;
|
||||
|
||||
function CefUserFreeString(const str: ustring): PCefStringUserFree;
|
||||
begin
|
||||
Result := cef_string_userfree_utf16_alloc;
|
||||
Result := cef_string_userfree_utf16_alloc;
|
||||
Result.length := Length(str);
|
||||
GetMem(Result.str, Result.length * SizeOf(TCefChar));
|
||||
Move(PCefChar(str)^, Result.str^, Result.length * SizeOf(TCefChar));
|
||||
Result.dtor := @_free_string;
|
||||
Result.dtor := @_free_string;
|
||||
end;
|
||||
|
||||
function CefExecuteProcess(var app : ICefApp; aWindowsSandboxInfo : Pointer) : integer;
|
||||
@ -273,10 +270,10 @@ end;
|
||||
|
||||
function CefRegisterExtension(const name, code: ustring; const Handler: ICefv8Handler): Boolean;
|
||||
var
|
||||
n, c: TCefString;
|
||||
n, c : TCefString;
|
||||
begin
|
||||
n := CefString(name);
|
||||
c := CefString(code);
|
||||
n := CefString(name);
|
||||
c := CefString(code);
|
||||
Result := cef_register_extension(@n, @c, CefGetData(handler)) <> 0;
|
||||
end;
|
||||
|
||||
@ -292,33 +289,33 @@ end;
|
||||
|
||||
function CefTimeToSystemTime(const dt: TCefTime): TSystemTime;
|
||||
begin
|
||||
Result.wYear := dt.year;
|
||||
Result.wMonth := dt.month;
|
||||
Result.wDayOfWeek := dt.day_of_week;
|
||||
Result.wDay := dt.day_of_month;
|
||||
Result.wHour := dt.hour;
|
||||
Result.wMinute := dt.minute;
|
||||
Result.wSecond := dt.second;
|
||||
Result.wMilliseconds := dt.millisecond;
|
||||
Result.wYear := dt.year;
|
||||
Result.wMonth := dt.month;
|
||||
Result.wDayOfWeek := dt.day_of_week;
|
||||
Result.wDay := dt.day_of_month;
|
||||
Result.wHour := dt.hour;
|
||||
Result.wMinute := dt.minute;
|
||||
Result.wSecond := dt.second;
|
||||
Result.wMilliseconds := dt.millisecond;
|
||||
end;
|
||||
|
||||
function SystemTimeToCefTime(const dt: TSystemTime): TCefTime;
|
||||
begin
|
||||
Result.year := dt.wYear;
|
||||
Result.month := dt.wMonth;
|
||||
Result.day_of_week := dt.wDayOfWeek;
|
||||
Result.year := dt.wYear;
|
||||
Result.month := dt.wMonth;
|
||||
Result.day_of_week := dt.wDayOfWeek;
|
||||
Result.day_of_month := dt.wDay;
|
||||
Result.hour := dt.wHour;
|
||||
Result.minute := dt.wMinute;
|
||||
Result.second := dt.wSecond;
|
||||
Result.millisecond := dt.wMilliseconds;
|
||||
Result.hour := dt.wHour;
|
||||
Result.minute := dt.wMinute;
|
||||
Result.second := dt.wSecond;
|
||||
Result.millisecond := dt.wMilliseconds;
|
||||
end;
|
||||
|
||||
function CefTimeToDateTime(const dt: TCefTime): TDateTime;
|
||||
var
|
||||
st: TSystemTime;
|
||||
begin
|
||||
st := CefTimeToSystemTime(dt);
|
||||
st := CefTimeToSystemTime(dt);
|
||||
SystemTimeToTzSpecificLocalTime(nil, @st, @st);
|
||||
Result := SystemTimeToDateTime(st);
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user