parent
f70ed1b63b
commit
2e6a766d09
|
|
@ -5036,6 +5036,7 @@ type TEditerEchoWnd=class(TSynMemoNorm) //
|
||||||
function Create(AOwner);override;
|
function Create(AOwner);override;
|
||||||
begin
|
begin
|
||||||
inherited;
|
inherited;
|
||||||
|
autogutterwidth := true;
|
||||||
FDoLockTime := 0;
|
FDoLockTime := 0;
|
||||||
FIsLocked := false;
|
FIsLocked := false;
|
||||||
height := 250;
|
height := 250;
|
||||||
|
|
|
||||||
|
|
@ -20,6 +20,97 @@ type TGdiplusflat=class
|
||||||
//----------------------------------------------------------------------------
|
//----------------------------------------------------------------------------
|
||||||
{$ifdef linux}
|
{$ifdef linux}
|
||||||
//20210827 需要添加gdi功能
|
//20210827 需要添加gdi功能
|
||||||
|
static fsgtkgdi;
|
||||||
|
class function getgtkgdi();
|
||||||
|
begin
|
||||||
|
if not fsgtkgdi then fsgtkgdi := new tgtkgdi();
|
||||||
|
return fsgtkgdi;
|
||||||
|
end
|
||||||
|
type tgtkgdi = class
|
||||||
|
{
|
||||||
|
class procedure cairo_pattern_destroy(p:pointer);cdecl;external 'libgtk-3.so';
|
||||||
|
class function cairo_image_surface_create_from_png(f:string):pointer;cdecl;external 'libgtk-3.so';
|
||||||
|
class function cairo_pattern_create_for_surface(f:pointer):pointer;cdecl;external 'libgtk-3.so';
|
||||||
|
class function cairo_image_surface_get_width(sf:pointer):integer;cdecl;external 'libgtk-3.so';
|
||||||
|
class function cairo_image_surface_get_height(sf:pointer):integer;cdecl;external 'libgtk-3.so';
|
||||||
|
class function gdk_pixbuf_new_from_file(f:string;er:pointer):pointer;cdecl;external 'libgtk-3.so';
|
||||||
|
class function gdk_pixbuf_save(pixbuf:pointer;p:string;tp:string;gerr:string;p1:string; p2:string;p3:string;p4:string;p5:string):integer;cdecl;external 'libgtk-3.so';
|
||||||
|
class procedure gdk_pixbuf_unref(pixbuf);cdecl;external 'libgtk-3.so';
|
||||||
|
class procedure gdk_pixbuf_ref(pixbuf);cdecl;external 'libgtk-3.so';
|
||||||
|
class function g_object_ref(g:pointer):pointer;cdecl;external 'libgtk-3.so';
|
||||||
|
class procedure g_object_unref(g:pointer);cdecl;external 'libgtk-3.so';
|
||||||
|
}
|
||||||
|
procedure cairo_pattern_destroy(p:pointer);
|
||||||
|
begin
|
||||||
|
_f_ := static procedure(p:pointer);cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_(p);
|
||||||
|
end
|
||||||
|
function cairo_image_surface_create_from_png(f:string):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(f:string):pointer;cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_(f);
|
||||||
|
end
|
||||||
|
function cairo_pattern_create_for_surface(f:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(f:pointer):pointer;cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_(f);
|
||||||
|
end
|
||||||
|
function cairo_image_surface_get_width(sf:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(sf:pointer):integer;cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_(sf);
|
||||||
|
end
|
||||||
|
function cairo_image_surface_get_height(sf:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(sf:pointer):integer;cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_(sf);
|
||||||
|
end
|
||||||
|
function gdk_pixbuf_new_from_file(f:string;er:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(f:string;er:pointer):pointer;cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_(f,er);
|
||||||
|
end
|
||||||
|
function gdk_pixbuf_save(pixbuf:pointer;p:string;tp:string;gerr:string;p1:string; p2:string;p3:string;p4:string;p5:string):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(pixbuf:pointer;p:string;tp:string;gerr:string;p1:string; p2:string;p3:string;p4:string;p5:string):integer;cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_(pixbuf,p,tp,gerr,p1,p2,p3,p4,p5);
|
||||||
|
end
|
||||||
|
procedure gdk_pixbuf_unref(pixbuf);
|
||||||
|
begin
|
||||||
|
_f_ := static procedure(pixbuf);cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
|
class procedure gdk_pixbuf_ref(pixbuf);
|
||||||
|
begin
|
||||||
|
_f_ := static procedure(pixbuf);cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
|
function g_object_ref(g:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(g:pointer):pointer;cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_(g);
|
||||||
|
end
|
||||||
|
procedure g_object_unref(g:pointer);
|
||||||
|
begin
|
||||||
|
_f_ := static procedure(g:pointer);cdecl;external getfuncptrbyname(0,functionname());
|
||||||
|
return ##_f_(g);
|
||||||
|
end
|
||||||
|
function getfuncptrbyname(lib,n);
|
||||||
|
begin
|
||||||
|
case lib of
|
||||||
|
"libc":
|
||||||
|
begin
|
||||||
|
return getdlsymaddress("libc.so.6",n);
|
||||||
|
end
|
||||||
|
"gtk":
|
||||||
|
begin
|
||||||
|
|
||||||
|
end
|
||||||
|
else return getdlsymaddress("libgtk-3.so.0",n);
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
type TTempFile = class
|
type TTempFile = class
|
||||||
function Create();
|
function Create();
|
||||||
begin
|
begin
|
||||||
|
|
@ -57,19 +148,64 @@ type TGdiplusflat=class
|
||||||
Fptr;
|
Fptr;
|
||||||
static _mtool;
|
static _mtool;
|
||||||
end
|
end
|
||||||
class procedure cairo_pattern_destroy(p:pointer);cdecl;external 'libgtk-3.so';
|
class procedure cairo_pattern_destroy(p:pointer);
|
||||||
class function cairo_image_surface_create_from_png(f:string):pointer;cdecl;external 'libgtk-3.so';
|
begin
|
||||||
class function cairo_pattern_create_for_surface(f:pointer):pointer;cdecl;external 'libgtk-3.so';
|
return getgtkgdi().cairo_pattern_destroy(p);
|
||||||
class function cairo_image_surface_get_width(sf:pointer):integer;cdecl;external 'libgtk-3.so';
|
end
|
||||||
class function cairo_image_surface_get_height(sf:pointer):integer;cdecl;external 'libgtk-3.so';
|
class function cairo_image_surface_create_from_png(f:string):pointer;
|
||||||
class function gdk_pixbuf_new_from_file(f:string;er:pointer):pointer;cdecl;external 'libgtk-3.so';
|
begin
|
||||||
class function gdk_pixbuf_save(pixbuf:pointer;p:string;tp:string;gerr:string;p1:string; p2:string;p3:string;p4:string;p5:string):integer;cdecl;external 'libgtk-3.so';
|
return getgtkgdi().cairo_image_surface_create_from_png(f);
|
||||||
class procedure gdk_pixbuf_unref(pixbuf);cdecl;external 'libgtk-3.so';
|
end
|
||||||
class procedure gdk_pixbuf_ref(pixbuf);cdecl;external 'libgtk-3.so';
|
class function cairo_pattern_create_for_surface(f:pointer):pointer;
|
||||||
class function g_object_ref(g:pointer):pointer;cdecl;external 'libgtk-3.so';
|
begin
|
||||||
class procedure g_object_unref(g:pointer);cdecl;external 'libgtk-3.so';
|
return getgtkgdi().cairo_pattern_create_for_surface(f);
|
||||||
|
end
|
||||||
|
class function cairo_image_surface_get_width(sf:pointer):integer;
|
||||||
|
begin
|
||||||
|
return getgtkgdi().cairo_image_surface_get_width(sf);
|
||||||
|
end
|
||||||
|
class function cairo_image_surface_get_height(sf:pointer):integer;
|
||||||
|
begin
|
||||||
|
return getgtkgdi().cairo_image_surface_get_height(sf);
|
||||||
|
end
|
||||||
|
class function gdk_pixbuf_new_from_file(f:string;er:pointer):pointer;
|
||||||
|
begin
|
||||||
|
return getgtkgdi().gdk_pixbuf_new_from_file(f,er);
|
||||||
|
end
|
||||||
|
class function gdk_pixbuf_save(pixbuf:pointer;p:string;tp:string;gerr:string;p1:string; p2:string;p3:string;p4:string;p5:string):integer;
|
||||||
|
begin
|
||||||
|
return getgtkgdi().gdk_pixbuf_save(pixbuf,p,tp,gerr,p1,p2,p3,p4,p5);
|
||||||
|
end
|
||||||
|
class procedure gdk_pixbuf_unref(pixbuf);
|
||||||
|
begin
|
||||||
|
return getgtkgdi().gdk_pixbuf_unref(pixbuf);
|
||||||
|
end
|
||||||
|
class procedure gdk_pixbuf_ref(pixbuf);
|
||||||
|
begin
|
||||||
|
return getgtkgdi().gdk_pixbuf_ref(pixbuf);
|
||||||
|
end
|
||||||
|
class function g_object_ref(g:pointer):pointer;
|
||||||
|
begin
|
||||||
|
return getgtkgdi().g_object_ref(g);
|
||||||
|
end
|
||||||
|
class procedure g_object_unref(g:pointer);
|
||||||
|
begin
|
||||||
|
return getgtkgdi().g_object_unref(g);
|
||||||
|
end
|
||||||
|
class function getfuncptrbyname(lib,n);
|
||||||
|
begin
|
||||||
|
case lib of
|
||||||
|
"libc":
|
||||||
|
begin
|
||||||
|
return getdlsymaddress("libc.so.6",n);
|
||||||
|
end
|
||||||
|
"gtk":
|
||||||
|
begin
|
||||||
|
|
||||||
|
end
|
||||||
|
else return getdlsymaddress("libgtk-3.so.0",n);
|
||||||
|
end
|
||||||
|
end
|
||||||
class function GdipSaveImageToStream(image:pointer;var imgestr:string); //无用到
|
class function GdipSaveImageToStream(image:pointer;var imgestr:string); //无用到
|
||||||
class function GdipLoadImageFromFile(filename:string;var image:pointer); //无用到
|
class function GdipLoadImageFromFile(filename:string;var image:pointer); //无用到
|
||||||
begin
|
begin
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -15,8 +15,8 @@ procedure cef_shutdown();
|
||||||
procedure cef_run_message_loop();
|
procedure cef_run_message_loop();
|
||||||
procedure cef_do_message_loop_work();
|
procedure cef_do_message_loop_work();
|
||||||
function cef_execute_process(arg:pointer;app:pointer;dow:pointer):integer;
|
function cef_execute_process(arg:pointer;app:pointer;dow:pointer):integer;
|
||||||
function IsBadReadPtr(ptr:pointer;ucb:pointer):integer;
|
//function IsBadReadPtr(ptr:pointer;ucb:pointer):integer;
|
||||||
function IsBadWritePtr(ptr:pointer;ucb:pointer):integer;
|
//function IsBadWritePtr(ptr:pointer;ucb:pointer):integer;
|
||||||
type cef_point_t = class(tslcstructureobj)
|
type cef_point_t = class(tslcstructureobj)
|
||||||
private
|
private
|
||||||
static SSTRUCT;
|
static SSTRUCT;
|
||||||
|
|
@ -224,9 +224,10 @@ type tcefmessage = class(TTSLProcessMsg)
|
||||||
function create(ptr);
|
function create(ptr);
|
||||||
begin
|
begin
|
||||||
inherited;
|
inherited;
|
||||||
lb := LoadLibraryA("libcef.dll");
|
proc := getceffunction("cef_do_message_loop_work");
|
||||||
p := GetProcAddress(lb,"cef_do_message_loop_work");
|
//lb := LoadLibraryA("libcef.dll");
|
||||||
proc := p;
|
//p := GetProcAddress(lb,"cef_do_message_loop_work");
|
||||||
|
//proc := p;
|
||||||
end
|
end
|
||||||
function add();
|
function add();
|
||||||
begin
|
begin
|
||||||
|
|
@ -237,8 +238,24 @@ type tcefmessage = class(TTSLProcessMsg)
|
||||||
tslRemoveProcess(_getptr_());
|
tslRemoveProcess(_getptr_());
|
||||||
end
|
end
|
||||||
private
|
private
|
||||||
procedure tslAddProcess(p:pointer);cdecl;external "tslkrnl.dll" name "tslAddProcess";
|
procedure tslAddProcess(p:pointer);
|
||||||
procedure tslRemoveProcess(p:pointer);cdecl;external "tslkrnl.dll" name "tslRemoveProcess";
|
begin
|
||||||
|
{$ifdef linux}
|
||||||
|
_f_ := static procedure(p:pointer);cdecl;external getdlsymaddress("libTSLkrnl.so","tslAddProcess");
|
||||||
|
{$else}
|
||||||
|
_f_ := static procedure(p:pointer);cdecl;external getdlsymaddress("tslkrnl.dll","tslAddProcess");
|
||||||
|
{$endif}
|
||||||
|
return ##_f_(p);
|
||||||
|
end
|
||||||
|
procedure tslRemoveProcess(p:pointer);
|
||||||
|
begin
|
||||||
|
{$ifdef linux}
|
||||||
|
_f_ := static procedure(p:pointer);cdecl;external getdlsymaddress("libTSLkrnl.so","tslRemoveProcess");
|
||||||
|
{$else}
|
||||||
|
_f_ := static procedure(p:pointer);cdecl;external getdlsymaddress("tslkrnl.dll","tslRemoveProcess");
|
||||||
|
{$endif}
|
||||||
|
return ##_f_(p);
|
||||||
|
end
|
||||||
end
|
end
|
||||||
type TTSLProcessMsg =class(tslcstructureobj)
|
type TTSLProcessMsg =class(tslcstructureobj)
|
||||||
private
|
private
|
||||||
|
|
@ -506,14 +523,46 @@ type cef_string_map_t = class()
|
||||||
private
|
private
|
||||||
fptr;
|
fptr;
|
||||||
private
|
private
|
||||||
function cef_string_map_alloc():pointer;cdecl;external "libcef.dll" name "cef_string_map_alloc";
|
function cef_string_map_alloc():pointer;
|
||||||
function cef_string_map_size(map:pointer):pointer;cdecl;external "libcef.dll" name "cef_string_map_size";
|
begin
|
||||||
function cef_string_map_find(map:pointer;key:pointer;value:pointer):pointer;cdecl;external "libcef.dll" name "cef_string_map_find";
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
function cef_string_map_key(map:pointer;index:pointer;key:pointer):integer;cdecl;external "libcef.dll" name "cef_string_map_key";
|
return ##_f_();
|
||||||
function cef_string_map_value(map:pointer;index:pointer;value:pointer):integer;cdecl;external "libcef.dll" name "cef_string_map_value";
|
end
|
||||||
function cef_string_map_append(map:pointer;key:pointer;value:pointer):integer;cdecl;external "libcef.dll" name "cef_string_map_append";
|
function cef_string_map_size(map:pointer):pointer;
|
||||||
procedure cef_string_map_clear(map:pointer);cdecl;external "libcef.dll" name "cef_string_map_clear";
|
begin
|
||||||
procedure cef_string_map_free(map:pointer);cdecl;external "libcef.dll" name "cef_string_map_free";
|
_f_ := static function(map:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map);
|
||||||
|
end
|
||||||
|
function cef_string_map_find(map:pointer;key:pointer;value:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(map:pointer;key:pointer;value:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map,key,value);
|
||||||
|
end
|
||||||
|
function cef_string_map_key(map:pointer;index:pointer;key:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(map:pointer;index:pointer;key:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map,index,key);
|
||||||
|
end
|
||||||
|
function cef_string_map_value(map:pointer;index:pointer;value:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(map:pointer;index:pointer;value:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map,index,value);
|
||||||
|
end
|
||||||
|
function cef_string_map_append(map:pointer;key:pointer;value:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(map:pointer;key:pointer;value:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map,key,value);
|
||||||
|
end
|
||||||
|
procedure cef_string_map_clear(map:pointer);
|
||||||
|
begin
|
||||||
|
_f_ := static procedure(map:pointer);cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map);
|
||||||
|
end
|
||||||
|
procedure cef_string_map_free(map:pointer);
|
||||||
|
begin
|
||||||
|
_f_ := static procedure(map:pointer);cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map);
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
type cef_main_args_t=class(tslcstructureobj)
|
type cef_main_args_t=class(tslcstructureobj)
|
||||||
|
|
@ -5742,11 +5791,8 @@ type cef_log_severity_t = class
|
||||||
//LOGSEVERITY_DISABLE = 99
|
//LOGSEVERITY_DISABLE = 99
|
||||||
end
|
end
|
||||||
|
|
||||||
function IsBadReadPtr(ptr:pointer;ucb:pointer):integer;stdcall;external "Kernel32.dll" name "IsBadReadPtr";
|
//function IsBadReadPtr(ptr:pointer;ucb:pointer):integer;stdcall;external "Kernel32.dll" name "IsBadReadPtr";
|
||||||
function IsBadWritePtr(ptr:pointer;ucb:pointer):integer;stdcall;external "Kernel32.dll" name "IsBadWritePtr";
|
//function IsBadWritePtr(ptr:pointer;ucb:pointer):integer;stdcall;external "Kernel32.dll" name "IsBadWritePtr";
|
||||||
function LoadLibraryA(txt:string):POINTER;stdcall;external "Kernel32.dll" name "LoadLibraryA";
|
|
||||||
function FreeLibrary(hd:pointer):integer;stdcall;external "Kernel32.dll" name "FreeLibrary";
|
|
||||||
function GetProcAddress(h:pointer;n:string):pointer;stdcall;external "Kernel32.dll" name "GetProcAddress";
|
|
||||||
function addcefref(id);
|
function addcefref(id);
|
||||||
begin
|
begin
|
||||||
global g_cef_counter_;
|
global g_cef_counter_;
|
||||||
|
|
@ -5846,11 +5892,11 @@ begin
|
||||||
for i,v in g_cef_objects_ do
|
for i,v in g_cef_objects_ do
|
||||||
begin
|
begin
|
||||||
ptr := v._getptr_();
|
ptr := v._getptr_();
|
||||||
if IsBadReadPtr(ptr,v.memsize()) then //Ö¸ÕëÎÞЧ
|
{if IsBadReadPtr(ptr,v.memsize()) then //Ö¸ÕëÎÞЧ
|
||||||
begin
|
begin
|
||||||
rs[i] := nil;
|
rs[i] := nil;
|
||||||
continue;
|
continue;
|
||||||
end
|
end }
|
||||||
isv := v._getvalue_("is_valid");
|
isv := v._getvalue_("is_valid");
|
||||||
if isv then
|
if isv then
|
||||||
begin
|
begin
|
||||||
|
|
@ -5878,69 +5924,204 @@ begin
|
||||||
end
|
end
|
||||||
/// Create a new cef_drag_data_t object.
|
/// Create a new cef_drag_data_t object.
|
||||||
//CEF_EXPORT cef_drag_data_t* cef_drag_data_create(void);
|
//CEF_EXPORT cef_drag_data_t* cef_drag_data_create(void);
|
||||||
function cef_drag_data_create():pointer;cdecl;external "libcef.dll" name "cef_drag_data_create";
|
function cef_drag_data_create():pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
/// Create a new cef_stream_writer_t object for a file.
|
/// Create a new cef_stream_writer_t object for a file.
|
||||||
//CEF_EXPORT cef_stream_writer_t* cef_stream_writer_create_for_file(const cef_string_t* fileName);
|
//CEF_EXPORT cef_stream_writer_t* cef_stream_writer_create_for_file(const cef_string_t* fileName);
|
||||||
function cef_stream_writer_create_for_file(name:pointer):pointer;cdecl;external "libcef.dll" name "cef_stream_writer_create_for_file";
|
function cef_stream_writer_create_for_file(name:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(name:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(name);
|
||||||
|
end
|
||||||
//CEF_EXPORT cef_process_message_t* cef_process_message_create(const cef_string_t* name);
|
//CEF_EXPORT cef_process_message_t* cef_process_message_create(const cef_string_t* name);
|
||||||
function cef_process_message_create(name:pointer):pointer;cdecl;external "libcef.dll" name "cef_process_message_create";
|
function cef_process_message_create(name:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(name:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(name);
|
||||||
|
end
|
||||||
//cef_request_t* cef_request_create(void);
|
//cef_request_t* cef_request_create(void);
|
||||||
function cef_request_create():pointer;cdecl;external "libcef.dll" name "cef_request_create";
|
function cef_request_create():pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
//CEF_EXPORT cef_binary_value_t* cef_binary_value_create(const void* data,size_t data_size);
|
//CEF_EXPORT cef_binary_value_t* cef_binary_value_create(const void* data,size_t data_size);
|
||||||
function cef_binary_value_create(s:string;data_size:pointer):pointer;cdecl;external "libcef.dll" name "cef_binary_value_create";
|
function cef_binary_value_create(s:string;data_size:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(s:string;data_size:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(s,data_size);
|
||||||
|
end
|
||||||
//CEF_EXPORT cef_dictionary_value_t* cef_dictionary_value_create(void);
|
//CEF_EXPORT cef_dictionary_value_t* cef_dictionary_value_create(void);
|
||||||
function cef_dictionary_value_create():pointer;cdecl;external "libcef.dll" name "cef_dictionary_value_create";
|
function cef_dictionary_value_create():pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
//CEF_EXPORT cef_cookie_manager_t* cef_cookie_manager_get_global_manager(struct _cef_completion_callback_t* callback);
|
//CEF_EXPORT cef_cookie_manager_t* cef_cookie_manager_get_global_manager(struct _cef_completion_callback_t* callback);
|
||||||
function cef_cookie_manager_get_global_manager(callback:pointer):pointer;cdecl;external "libcef.dll" name "cef_cookie_manager_get_global_manager";
|
function cef_cookie_manager_get_global_manager(callback:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(callback:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(callback);
|
||||||
|
end
|
||||||
//CEF_EXPORT cef_request_context_t* cef_request_context_get_global_context(void);
|
//CEF_EXPORT cef_request_context_t* cef_request_context_get_global_context(void);
|
||||||
function cef_request_context_get_global_context():pointer;cdecl;external "libcef.dll" name "cef_request_context_get_global_context";
|
function cef_request_context_get_global_context():pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
//CEF_EXPORT cef_value_t* cef_value_create(void);
|
//CEF_EXPORT cef_value_t* cef_value_create(void);
|
||||||
function cef_value_create():pointer;cdecl;external "libcef.dll" name "cef_value_create";
|
function cef_value_create():pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
//CEF_EXPORT cef_preference_manager_t* cef_preference_manager_get_global(void);
|
//CEF_EXPORT cef_preference_manager_t* cef_preference_manager_get_global(void);
|
||||||
function cef_preference_manager_get_global():pointer;cdecl;external "libcef.dll" name "cef_preference_manager_get_global";
|
function cef_preference_manager_get_global():pointer;
|
||||||
procedure cef_shutdown();cdecl;external "libcef.dll" name "cef_shutdown";
|
begin
|
||||||
function cef_string_list_alloc():pointer;cdecl;external "libcef.dll" name "cef_string_list_alloc";
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
|
procedure cef_shutdown();
|
||||||
|
begin
|
||||||
|
_f_ := static procedure();cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
|
function cef_string_list_alloc():pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
/// Return the number of elements in the string list.
|
/// Return the number of elements in the string list.
|
||||||
function cef_string_list_size(list:pointer):pointer;cdecl;external "libcef.dll" name "cef_string_list_size";
|
function cef_string_list_size(list:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(list:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(list);
|
||||||
|
end
|
||||||
/// Retrieve the value at the specified zero-based string list index. Returns
|
/// Retrieve the value at the specified zero-based string list index. Returns
|
||||||
/// true (1) if the value was successfully retrieved.
|
/// true (1) if the value was successfully retrieved.
|
||||||
function cef_string_list_value(list:pointer;index:pointer;value:pointer):integer;cdecl;external "libcef.dll" name "cef_string_list_value";
|
function cef_string_list_value(list:pointer;index:pointer;value:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(list:pointer;index:pointer;value:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(list,index,value);
|
||||||
|
end
|
||||||
/// Append a new value at the end of the string list.
|
/// Append a new value at the end of the string list.
|
||||||
procedure cef_string_list_append(list:pointer;value:pointer);cdecl;external "libcef.dll" name "cef_string_list_append";
|
procedure cef_string_list_append(list:pointer;value:pointer);
|
||||||
|
begin
|
||||||
|
_f_ := static procedure(list:pointer;value:pointer);cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(list,value);
|
||||||
|
end
|
||||||
/// Clear the string list.
|
/// Clear the string list.
|
||||||
procedure cef_string_list_clear(list:pointer);cdecl;external "libcef.dll" name "cef_string_list_clear";
|
procedure cef_string_list_clear(list:pointer);
|
||||||
|
begin
|
||||||
|
_f_ := static procedure(list:pointer);cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(list);
|
||||||
|
end
|
||||||
/// Free the string list.
|
/// Free the string list.
|
||||||
procedure cef_string_list_free(list:pointer);cdecl;external "libcef.dll" name "cef_string_list_free";
|
procedure cef_string_list_free(list:pointer);
|
||||||
|
begin
|
||||||
|
_f_ := static procedure(list:pointer);cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(list);
|
||||||
|
end
|
||||||
/// Creates a copy of an existing string list.
|
/// Creates a copy of an existing string list.
|
||||||
function cef_string_list_copy(list:pointer):pointer;cdecl;external "libcef.dll" name "cef_string_list_copy";
|
function cef_string_list_copy(list:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(list:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(list);
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
//cef_string_multimap_t
|
//cef_string_multimap_t
|
||||||
function cef_string_multimap_alloc():pointer;cdecl;external "libcef.dll" name "cef_string_multimap_alloc";
|
function cef_string_multimap_alloc():pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
/// Return the number of elements in the string multimap.
|
/// Return the number of elements in the string multimap.
|
||||||
function cef_string_multimap_size( map:pointer):pointer;cdecl;external "libcef.dll" name "cef_string_multimap_size";
|
function cef_string_multimap_size( map:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function( map:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map);
|
||||||
|
end
|
||||||
/// Return the number of values with the specified key.
|
/// Return the number of values with the specified key.
|
||||||
function cef_string_multimap_find_count(map:pointer;key:pointer):pointer;cdecl;external "libcef.dll" name "cef_string_multimap_find_count";
|
function cef_string_multimap_find_count(map:pointer;key:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(map:pointer;key:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map,key);
|
||||||
|
end
|
||||||
/// Return the value_index-th value with the specified key.
|
/// Return the value_index-th value with the specified key.
|
||||||
function cef_string_multimap_enumerate(map:pointer;key:pointer;value_index:pointer;value:pointer):integer;cdecl;external "libcef.dll" name "cef_string_multimap_enumerate";
|
function cef_string_multimap_enumerate(map:pointer;key:pointer;value_index:pointer;value:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(map:pointer;key:pointer;value_index:pointer;value:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map,key,value_index,value);
|
||||||
|
end
|
||||||
/// Return the key at the specified zero-based string multimap index.
|
/// Return the key at the specified zero-based string multimap index.
|
||||||
function cef_string_multimap_key(map:pointer;index:pointer;key:pointer):integer;cdecl;external "libcef.dll" name "cef_string_multimap_key";
|
function cef_string_multimap_key(map:pointer;index:pointer;key:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(map:pointer;index:pointer;key:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map,index,key);
|
||||||
|
end
|
||||||
/// Return the value at the specified zero-based string multimap index.
|
/// Return the value at the specified zero-based string multimap index.
|
||||||
function cef_string_multimap_value(map:pointer;index:pointer;value:pointer):integer;cdecl;external "libcef.dll" name "cef_string_multimap_value";
|
function cef_string_multimap_value(map:pointer;index:pointer;value:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(map:pointer;index:pointer;value:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map,index,value);
|
||||||
|
end
|
||||||
/// Append a new key/value pair at the end of the string multimap.
|
/// Append a new key/value pair at the end of the string multimap.
|
||||||
function cef_string_multimap_append(map:pointer;key:pointer;value:pointer):integer;cdecl;external "libcef.dll" name "cef_string_multimap_append";
|
function cef_string_multimap_append(map:pointer;key:pointer;value:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(map:pointer;key:pointer;value:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map,key,value);
|
||||||
|
end
|
||||||
/// Clear the string multimap.
|
/// Clear the string multimap.
|
||||||
procedure cef_string_multimap_clear( map:pointer);cdecl;external "libcef.dll" name "cef_string_multimap_clear";
|
procedure cef_string_multimap_clear( map:pointer);
|
||||||
|
begin
|
||||||
|
_f_ := static procedure( map:pointer);cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(map);
|
||||||
|
end
|
||||||
/// Free the string multimap.
|
/// Free the string multimap.
|
||||||
procedure cef_string_multimap_free(map:pointer);cdecl;external "libcef.dll" name "cef_string_multimap_free";
|
procedure cef_string_multimap_free(map:pointer);
|
||||||
|
begin
|
||||||
function cef_post_data_element_create():pointer;cdecl;external "libcef.dll" name "cef_post_data_element_create";
|
_f_ := static procedure(map:pointer);cdecl;external getceffunction(functionname());
|
||||||
function cef_post_data_create():pointer;cdecl;external "libcef.dll" name "cef_post_data_create";
|
return ##_f_(map);
|
||||||
function cef_string_utf8_to_utf16(uf8:string;len:pointer;o:pointer):integer;cdecl;external "libcef.dll" name "cef_string_utf8_to_utf16";
|
end
|
||||||
function cef_string_ascii_to_utf16(uf8:string;len:pointer;o:pointer):integer;cdecl;external "libcef.dll" name "cef_string_ascii_to_utf16";
|
function cef_post_data_element_create():pointer;
|
||||||
function cef_initialize(args:pointer;sett:pointer;app:pointer;info:pointer):integer;cdecl;external "libcef.dll" name "cef_initialize";
|
begin
|
||||||
function cef_browser_host_create_browser_sync(winfo:pointer;client:pointer;url:pointer;bs:pointer;ef:pointer;ef2:pointer):pointer;cdecl;external "libcef.dll" name "cef_browser_host_create_browser_sync";
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
function cef_browser_host_create_browser(winfo:pointer;client:pointer;url:pointer;bs:pointer;ef:pointer;ef2:pointer):pointer;cdecl;external "libcef.dll" name "cef_browser_host_create_browser";
|
return ##_f_();
|
||||||
|
end
|
||||||
|
function cef_post_data_create():pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function():pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
|
function cef_string_utf8_to_utf16(uf8:string;len:pointer;o:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(uf8:string;len:pointer;o:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(uf8,len,o);
|
||||||
|
end
|
||||||
|
function cef_string_ascii_to_utf16(uf8:string;len:pointer;o:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(uf8:string;len:pointer;o:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(uf8,len,o);
|
||||||
|
end
|
||||||
|
function cef_initialize(args:pointer;sett:pointer;app:pointer;info:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(args:pointer;sett:pointer;app:pointer;info:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(args,sett,app,info);
|
||||||
|
end
|
||||||
|
function cef_browser_host_create_browser_sync(winfo:pointer;client:pointer;url:pointer;bs:pointer;ef:pointer;ef2:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(winfo:pointer;client:pointer;url:pointer;bs:pointer;ef:pointer;ef2:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(winfo,client,url,bs,ef,ef2);
|
||||||
|
end
|
||||||
|
function cef_browser_host_create_browser(winfo:pointer;client:pointer;url:pointer;bs:pointer;ef:pointer;ef2:pointer):pointer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(winfo:pointer;client:pointer;url:pointer;bs:pointer;ef:pointer;ef2:pointer):pointer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(winfo,client,url,bs,ef,ef2);
|
||||||
|
end
|
||||||
function cef_initialize_tsl(args:pointer;sett:pointer;app:pointer;info:pointer);
|
function cef_initialize_tsl(args:pointer;sett:pointer;app:pointer;info:pointer);
|
||||||
begin
|
begin
|
||||||
return cef_initialize(args?args._getptr_():0,sett?sett._getptr_():0,app?app._getptr_():0,info?info._getptr_():0);
|
return cef_initialize(args?args._getptr_():0,sett?sett._getptr_():0,app?app._getptr_():0,info?info._getptr_():0);
|
||||||
|
|
@ -5961,9 +6142,21 @@ begin
|
||||||
return cef_object_get(h,class( cef_browser_t));
|
return cef_object_get(h,class( cef_browser_t));
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
procedure cef_run_message_loop();external "libcef.dll" name "cef_run_message_loop";
|
procedure cef_run_message_loop();
|
||||||
procedure cef_do_message_loop_work();external "libcef.dll" name "cef_do_message_loop_work";
|
begin
|
||||||
function cef_execute_process(arg:pointer;app:pointer;dow:pointer):integer;cdecl;external "libcef.dll" name "cef_execute_process";
|
_f_ := static procedure();cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
|
procedure cef_do_message_loop_work();
|
||||||
|
begin
|
||||||
|
_f_ := static procedure();cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_();
|
||||||
|
end
|
||||||
|
function cef_execute_process(arg:pointer;app:pointer;dow:pointer):integer;
|
||||||
|
begin
|
||||||
|
_f_ := static function(arg:pointer;app:pointer;dow:pointer):integer;cdecl;external getceffunction(functionname());
|
||||||
|
return ##_f_(arg,app,dow);
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
function getcefboundsstruct();
|
function getcefboundsstruct();
|
||||||
|
|
@ -5996,6 +6189,13 @@ begin
|
||||||
g_cef_counter_ := new tcefcounter();
|
g_cef_counter_ := new tcefcounter();
|
||||||
g_cef_objects_ := array();
|
g_cef_objects_ := array();
|
||||||
end
|
end
|
||||||
|
function getceffunction(n);
|
||||||
|
begin
|
||||||
|
{$ifdef linux}
|
||||||
|
return getdlsymaddress("libcef.so",n);
|
||||||
|
{$endif}
|
||||||
|
return getdlsymaddress("libcef.dll",n);
|
||||||
|
end
|
||||||
initialization
|
initialization
|
||||||
init();
|
init();
|
||||||
end.
|
end.
|
||||||
Loading…
Reference in New Issue