mirror of
https://github.com/salvadordf/CEF4Delphi.git
synced 2025-02-02 10:25:26 +02:00
Update to CEF 112.3.0
This commit is contained in:
parent
94fff08cc8
commit
000f162de2
14
README.md
14
README.md
@ -3,15 +3,15 @@ CEF4Delphi is an open source project created by Salvador Díaz Fau to embed Chro
|
||||
|
||||
CEF4Delphi is based on DCEF3 and fpCEF3. The original license of those projects still applies to CEF4Delphi. Read the license terms in the first lines of any *.pas file.
|
||||
|
||||
CEF4Delphi uses CEF 112.2.10 which includes Chromium 112.0.5615.121.
|
||||
CEF4Delphi uses CEF 112.3.0 which includes Chromium 112.0.5615.165.
|
||||
|
||||
The CEF binaries used by CEF4Delphi are available for download at Spotify :
|
||||
* [Windows 32 bits](https://cef-builds.spotifycdn.com/cef_binary_112.2.10%2Bgd000e45%2Bchromium-112.0.5615.121_windows32.tar.bz2)
|
||||
* [Windows 64 bits](https://cef-builds.spotifycdn.com/cef_binary_112.2.10%2Bgd000e45%2Bchromium-112.0.5615.121_windows64.tar.bz2)
|
||||
* [Linux x86 64 bits](https://cef-builds.spotifycdn.com/cef_binary_112.2.10%2Bgd000e45%2Bchromium-112.0.5615.121_linux64.tar.bz2)
|
||||
* [Linux ARM 32 bits](https://cef-builds.spotifycdn.com/cef_binary_112.2.10%2Bgd000e45%2Bchromium-112.0.5615.121_linuxarm.tar.bz2)
|
||||
* [Linux ARM 64 bits](https://cef-builds.spotifycdn.com/cef_binary_112.2.10%2Bgd000e45%2Bchromium-112.0.5615.121_linuxarm64.tar.bz2)
|
||||
* [MacOS x86 64 bits](https://cef-builds.spotifycdn.com/cef_binary_112.2.10%2Bgd000e45%2Bchromium-112.0.5615.121_macosx64.tar.bz2)
|
||||
* [Windows 32 bits](https://cef-builds.spotifycdn.com/cef_binary_112.3.0%2Bgb09c4ca%2Bchromium-112.0.5615.165_windows32.tar.bz2)
|
||||
* [Windows 64 bits](https://cef-builds.spotifycdn.com/cef_binary_112.3.0%2Bgb09c4ca%2Bchromium-112.0.5615.165_windows64.tar.bz2)
|
||||
* [Linux x86 64 bits](https://cef-builds.spotifycdn.com/cef_binary_112.3.0%2Bgb09c4ca%2Bchromium-112.0.5615.165_linux64.tar.bz2)
|
||||
* [Linux ARM 32 bits](https://cef-builds.spotifycdn.com/cef_binary_112.3.0%2Bgb09c4ca%2Bchromium-112.0.5615.165_linuxarm.tar.bz2)
|
||||
* [Linux ARM 64 bits](https://cef-builds.spotifycdn.com/cef_binary_112.3.0%2Bgb09c4ca%2Bchromium-112.0.5615.165_linuxarm64.tar.bz2)
|
||||
* [MacOS x86 64 bits](https://cef-builds.spotifycdn.com/cef_binary_112.3.0%2Bgb09c4ca%2Bchromium-112.0.5615.165_macosx64.tar.bz2)
|
||||
|
||||
CEF4Delphi was developed and tested on Delphi 11.3 and it has been tested in Delphi 7, Delphi XE, Delphi 10, Delphi 10.2, Delphi 10.3, Delphi 10.4 and Lazarus 2.2.6/FPC 3.2.2. CEF4Delphi includes VCL, FireMonkey (FMX) and Lazarus components.
|
||||
|
||||
|
@ -21,7 +21,7 @@
|
||||
</CompilerOptions>
|
||||
<Description Value="CEF4Delphi is an open source project created by Salvador Díaz Fau to embed Chromium-based browsers in applications made with Delphi or Lazarus/FPC."/>
|
||||
<License Value="MPL 1.1"/>
|
||||
<Version Major="112" Minor="2" Release="10"/>
|
||||
<Version Major="112" Minor="3"/>
|
||||
<Files Count="214">
|
||||
<Item1>
|
||||
<Filename Value="..\source\uCEFAccessibilityHandler.pas"/>
|
||||
|
@ -3039,6 +3039,7 @@ type
|
||||
procedure OnCanClose(const window_: ICefWindow; var aResult : boolean);
|
||||
procedure OnAccelerator(const window_: ICefWindow; command_id: Integer; var aResult : boolean);
|
||||
procedure OnKeyEvent(const window_: ICefWindow; const event: TCefKeyEvent; var aResult : boolean);
|
||||
procedure OnWindowFullscreenTransition(const window_: ICefWindow; is_completed: boolean);
|
||||
end;
|
||||
|
||||
ICefWindowDelegateEvents = interface(ICefPanelDelegateEvents)
|
||||
@ -3060,6 +3061,7 @@ type
|
||||
procedure doOnCanClose(const window_: ICefWindow; var aResult : boolean);
|
||||
procedure doOnAccelerator(const window_: ICefWindow; command_id: Integer; var aResult : boolean);
|
||||
procedure doOnKeyEvent(const window_: ICefWindow; const event: TCefKeyEvent; var aResult : boolean);
|
||||
procedure doOnWindowFullscreenTransition(const window_: ICefWindow; is_completed: boolean);
|
||||
end;
|
||||
|
||||
implementation
|
||||
|
@ -3552,6 +3552,7 @@ type
|
||||
can_close : function(self: PCefWindowDelegate; window: PCefWindow): Integer; stdcall;
|
||||
on_accelerator : function(self: PCefWindowDelegate; window: PCefWindow; command_id: Integer): Integer; stdcall;
|
||||
on_key_event : function(self: PCefWindowDelegate; window: PCefWindow; const event: PCefKeyEvent): Integer; stdcall;
|
||||
on_window_fullscreen_transition : procedure(self: PCefWindowDelegate; window: PCefWindow; is_completed: integer); stdcall;
|
||||
end;
|
||||
|
||||
implementation
|
||||
|
@ -1,9 +1,9 @@
|
||||
CEF_SUPPORTED_VERSION_MAJOR = 112;
|
||||
CEF_SUPPORTED_VERSION_MINOR = 2;
|
||||
CEF_SUPPORTED_VERSION_RELEASE = 10;
|
||||
CEF_SUPPORTED_VERSION_MINOR = 3;
|
||||
CEF_SUPPORTED_VERSION_RELEASE = 0;
|
||||
CEF_SUPPORTED_VERSION_BUILD = 0;
|
||||
|
||||
CEF_CHROMEELF_VERSION_MAJOR = CEF_SUPPORTED_VERSION_MAJOR;
|
||||
CEF_CHROMEELF_VERSION_MINOR = 0;
|
||||
CEF_CHROMEELF_VERSION_RELEASE = 5615;
|
||||
CEF_CHROMEELF_VERSION_BUILD = 121;
|
||||
CEF_CHROMEELF_VERSION_BUILD = 165;
|
@ -90,23 +90,24 @@ type
|
||||
TOnMenuButtonPressedEvent = procedure(const Sender: TObject; const menu_button: ICefMenuButton; const screen_point: TCefPoint; const button_pressed_lock: ICefMenuButtonPressedLock) of object;
|
||||
|
||||
// ICefWindowDelegate
|
||||
TOnWindowCreatedEvent = procedure(const Sender: TObject; const window_: ICefWindow) of object;
|
||||
TOnWindowClosingEvent = procedure(const Sender: TObject; const window_: ICefWindow) of object;
|
||||
TOnWindowDestroyedEvent = procedure(const Sender: TObject; const window_: ICefWindow) of object;
|
||||
TOnWindowActivationChangedEvent = procedure(const Sender: TObject; const window_: ICefWindow; active: boolean) of object;
|
||||
TOnWindowBoundsChangedEvent = procedure(const Sender: TObject; const window_: ICefWindow; const new_bounds: TCefRect) of object;
|
||||
TOnGetParentWindowEvent = procedure(const Sender: TObject; const window_: ICefWindow; var is_menu, can_activate_menu: boolean; var aResult : ICefWindow) of object;
|
||||
TOnGetInitialBoundsEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : TCefRect) of object;
|
||||
TOnGetInitialShowStateEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : TCefShowState) of object;
|
||||
TOnIsFramelessEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnWithStandardWindowButtonsEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnGetTitlebarHeightEvent = procedure(const Sender: TObject; const window_: ICefWindow; var titlebar_height: Single; var aResult : boolean) of object;
|
||||
TOnCanResizeEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnCanMaximizeEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnCanMinimizeEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnCanCloseEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnAcceleratorEvent = procedure(const Sender: TObject; const window_: ICefWindow; command_id: Integer; var aResult : boolean) of object;
|
||||
TOnWindowKeyEventEvent = procedure(const Sender: TObject; const window_: ICefWindow; const event: TCefKeyEvent; var aResult : boolean) of object;
|
||||
TOnWindowCreatedEvent = procedure(const Sender: TObject; const window_: ICefWindow) of object;
|
||||
TOnWindowClosingEvent = procedure(const Sender: TObject; const window_: ICefWindow) of object;
|
||||
TOnWindowDestroyedEvent = procedure(const Sender: TObject; const window_: ICefWindow) of object;
|
||||
TOnWindowActivationChangedEvent = procedure(const Sender: TObject; const window_: ICefWindow; active: boolean) of object;
|
||||
TOnWindowBoundsChangedEvent = procedure(const Sender: TObject; const window_: ICefWindow; const new_bounds: TCefRect) of object;
|
||||
TOnGetParentWindowEvent = procedure(const Sender: TObject; const window_: ICefWindow; var is_menu, can_activate_menu: boolean; var aResult : ICefWindow) of object;
|
||||
TOnGetInitialBoundsEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : TCefRect) of object;
|
||||
TOnGetInitialShowStateEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : TCefShowState) of object;
|
||||
TOnIsFramelessEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnWithStandardWindowButtonsEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnGetTitlebarHeightEvent = procedure(const Sender: TObject; const window_: ICefWindow; var titlebar_height: Single; var aResult : boolean) of object;
|
||||
TOnCanResizeEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnCanMaximizeEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnCanMinimizeEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnCanCloseEvent = procedure(const Sender: TObject; const window_: ICefWindow; var aResult : boolean) of object;
|
||||
TOnAcceleratorEvent = procedure(const Sender: TObject; const window_: ICefWindow; command_id: Integer; var aResult : boolean) of object;
|
||||
TOnWindowKeyEventEvent = procedure(const Sender: TObject; const window_: ICefWindow; const event: TCefKeyEvent; var aResult : boolean) of object;
|
||||
TOnWindowFullscreenTransitionEvent = procedure(const Sender: TObject; const window_: ICefWindow; is_completed: boolean) of object;
|
||||
|
||||
implementation
|
||||
|
||||
|
@ -63,27 +63,28 @@ type
|
||||
{$IFNDEF FPC}{$IFDEF DELPHI16_UP}[ComponentPlatformsAttribute(pfidWindows or pfidOSX or pfidLinux)]{$ENDIF}{$ENDIF}
|
||||
TCEFWindowComponent = class(TCEFPanelComponent, ICefWindowDelegateEvents)
|
||||
protected
|
||||
FWindow : ICefWindow;
|
||||
FWindowDlg : ICefWindowDelegate;
|
||||
FWindow : ICefWindow;
|
||||
FWindowDlg : ICefWindowDelegate;
|
||||
|
||||
// ICefWindowDelegateEvents
|
||||
FOnWindowCreated : TOnWindowCreatedEvent;
|
||||
FOnWindowClosing : TOnWindowClosingEvent;
|
||||
FOnWindowDestroyed : TOnWindowDestroyedEvent;
|
||||
FOnWindowActivationChanged : TOnWindowActivationChangedEvent;
|
||||
FOnWindowBoundsChanged : TOnWindowBoundsChangedEvent;
|
||||
FOnGetParentWindow : TOnGetParentWindowEvent;
|
||||
FOnGetInitialBounds : TOnGetInitialBoundsEvent;
|
||||
FOnGetInitialShowState : TOnGetInitialShowStateEvent;
|
||||
FOnIsFrameless : TOnIsFramelessEvent;
|
||||
FOnWithStandardWindowButtons : TOnWithStandardWindowButtonsEvent;
|
||||
FOnGetTitlebarHeight : TOnGetTitlebarHeightEvent;
|
||||
FOnCanResize : TOnCanResizeEvent;
|
||||
FOnCanMaximize : TOnCanMaximizeEvent;
|
||||
FOnCanMinimize : TOnCanMinimizeEvent;
|
||||
FOnCanClose : TOnCanCloseEvent;
|
||||
FOnAccelerator : TOnAcceleratorEvent;
|
||||
FOnKeyEvent : TOnWindowKeyEventEvent;
|
||||
FOnWindowCreated : TOnWindowCreatedEvent;
|
||||
FOnWindowClosing : TOnWindowClosingEvent;
|
||||
FOnWindowDestroyed : TOnWindowDestroyedEvent;
|
||||
FOnWindowActivationChanged : TOnWindowActivationChangedEvent;
|
||||
FOnWindowBoundsChanged : TOnWindowBoundsChangedEvent;
|
||||
FOnGetParentWindow : TOnGetParentWindowEvent;
|
||||
FOnGetInitialBounds : TOnGetInitialBoundsEvent;
|
||||
FOnGetInitialShowState : TOnGetInitialShowStateEvent;
|
||||
FOnIsFrameless : TOnIsFramelessEvent;
|
||||
FOnWithStandardWindowButtons : TOnWithStandardWindowButtonsEvent;
|
||||
FOnGetTitlebarHeight : TOnGetTitlebarHeightEvent;
|
||||
FOnCanResize : TOnCanResizeEvent;
|
||||
FOnCanMaximize : TOnCanMaximizeEvent;
|
||||
FOnCanMinimize : TOnCanMinimizeEvent;
|
||||
FOnCanClose : TOnCanCloseEvent;
|
||||
FOnAccelerator : TOnAcceleratorEvent;
|
||||
FOnKeyEvent : TOnWindowKeyEventEvent;
|
||||
FOnWindowFullscreenTransition : TOnWindowFullscreenTransitionEvent;
|
||||
|
||||
procedure DestroyView; override;
|
||||
procedure Initialize; override;
|
||||
@ -129,6 +130,7 @@ type
|
||||
procedure doOnCanClose(const window_: ICefWindow; var aResult : boolean);
|
||||
procedure doOnAccelerator(const window_: ICefWindow; command_id: Integer; var aResult : boolean);
|
||||
procedure doOnKeyEvent(const window_: ICefWindow; const event: TCefKeyEvent; var aResult : boolean);
|
||||
procedure doOnWindowFullscreenTransition(const window_: ICefWindow; is_completed: boolean);
|
||||
|
||||
// ICefViewDelegateEvents
|
||||
procedure doCreateCustomView; override;
|
||||
@ -170,23 +172,24 @@ type
|
||||
property IsMinimized : boolean read GetIsMinimized;
|
||||
|
||||
published
|
||||
property OnWindowCreated : TOnWindowCreatedEvent read FOnWindowCreated write FOnWindowCreated;
|
||||
property OnWindowClosing : TOnWindowClosingEvent read FOnWindowClosing write FOnWindowClosing;
|
||||
property OnWindowDestroyed : TOnWindowDestroyedEvent read FOnWindowDestroyed write FOnWindowDestroyed;
|
||||
property OnWindowActivationChanged : TOnWindowActivationChangedEvent read FOnWindowActivationChanged write FOnWindowActivationChanged;
|
||||
property OnWindowBoundsChanged : TOnWindowBoundsChangedEvent read FOnWindowBoundsChanged write FOnWindowBoundsChanged;
|
||||
property OnGetParentWindow : TOnGetParentWindowEvent read FOnGetParentWindow write FOnGetParentWindow;
|
||||
property OnGetInitialBounds : TOnGetInitialBoundsEvent read FOnGetInitialBounds write FOnGetInitialBounds;
|
||||
property OnGetInitialShowState : TOnGetInitialShowStateEvent read FOnGetInitialShowState write FOnGetInitialShowState;
|
||||
property OnIsFrameless : TOnIsFramelessEvent read FOnIsFrameless write FOnIsFrameless;
|
||||
property OnWithStandardWindowButtons : TOnWithStandardWindowButtonsEvent read FOnWithStandardWindowButtons write FOnWithStandardWindowButtons;
|
||||
property OnGetTitlebarHeight : TOnGetTitlebarHeightEvent read FOnGetTitlebarHeight write FOnGetTitlebarHeight;
|
||||
property OnCanResize : TOnCanResizeEvent read FOnCanResize write FOnCanResize;
|
||||
property OnCanMaximize : TOnCanMaximizeEvent read FOnCanMaximize write FOnCanMaximize;
|
||||
property OnCanMinimize : TOnCanMinimizeEvent read FOnCanMinimize write FOnCanMinimize;
|
||||
property OnCanClose : TOnCanCloseEvent read FOnCanClose write FOnCanClose;
|
||||
property OnAccelerator : TOnAcceleratorEvent read FOnAccelerator write FOnAccelerator;
|
||||
property OnKeyEvent : TOnWindowKeyEventEvent read FOnKeyEvent write FOnKeyEvent;
|
||||
property OnWindowCreated : TOnWindowCreatedEvent read FOnWindowCreated write FOnWindowCreated;
|
||||
property OnWindowClosing : TOnWindowClosingEvent read FOnWindowClosing write FOnWindowClosing;
|
||||
property OnWindowDestroyed : TOnWindowDestroyedEvent read FOnWindowDestroyed write FOnWindowDestroyed;
|
||||
property OnWindowActivationChanged : TOnWindowActivationChangedEvent read FOnWindowActivationChanged write FOnWindowActivationChanged;
|
||||
property OnWindowBoundsChanged : TOnWindowBoundsChangedEvent read FOnWindowBoundsChanged write FOnWindowBoundsChanged;
|
||||
property OnGetParentWindow : TOnGetParentWindowEvent read FOnGetParentWindow write FOnGetParentWindow;
|
||||
property OnGetInitialBounds : TOnGetInitialBoundsEvent read FOnGetInitialBounds write FOnGetInitialBounds;
|
||||
property OnGetInitialShowState : TOnGetInitialShowStateEvent read FOnGetInitialShowState write FOnGetInitialShowState;
|
||||
property OnIsFrameless : TOnIsFramelessEvent read FOnIsFrameless write FOnIsFrameless;
|
||||
property OnWithStandardWindowButtons : TOnWithStandardWindowButtonsEvent read FOnWithStandardWindowButtons write FOnWithStandardWindowButtons;
|
||||
property OnGetTitlebarHeight : TOnGetTitlebarHeightEvent read FOnGetTitlebarHeight write FOnGetTitlebarHeight;
|
||||
property OnCanResize : TOnCanResizeEvent read FOnCanResize write FOnCanResize;
|
||||
property OnCanMaximize : TOnCanMaximizeEvent read FOnCanMaximize write FOnCanMaximize;
|
||||
property OnCanMinimize : TOnCanMinimizeEvent read FOnCanMinimize write FOnCanMinimize;
|
||||
property OnCanClose : TOnCanCloseEvent read FOnCanClose write FOnCanClose;
|
||||
property OnAccelerator : TOnAcceleratorEvent read FOnAccelerator write FOnAccelerator;
|
||||
property OnKeyEvent : TOnWindowKeyEventEvent read FOnKeyEvent write FOnKeyEvent;
|
||||
property OnWindowFullscreenTransition : TOnWindowFullscreenTransitionEvent read FOnWindowFullscreenTransition write FOnWindowFullscreenTransition;
|
||||
end;
|
||||
|
||||
{$IFDEF FPC}
|
||||
@ -229,25 +232,26 @@ procedure TCEFWindowComponent.Initialize;
|
||||
begin
|
||||
inherited Initialize;
|
||||
|
||||
FWindow := nil;
|
||||
FWindowDlg := nil;
|
||||
FOnWindowCreated := nil;
|
||||
FOnWindowClosing := nil;
|
||||
FOnWindowDestroyed := nil;
|
||||
FOnWindowActivationChanged := nil;
|
||||
FOnWindowBoundsChanged := nil;
|
||||
FOnGetParentWindow := nil;
|
||||
FOnGetInitialBounds := nil;
|
||||
FOnGetInitialShowState := nil;
|
||||
FOnIsFrameless := nil;
|
||||
FOnWithStandardWindowButtons := nil;
|
||||
FOnGetTitlebarHeight := nil;
|
||||
FOnCanResize := nil;
|
||||
FOnCanMaximize := nil;
|
||||
FOnCanMinimize := nil;
|
||||
FOnCanClose := nil;
|
||||
FOnAccelerator := nil;
|
||||
FOnKeyEvent := nil;
|
||||
FWindow := nil;
|
||||
FWindowDlg := nil;
|
||||
FOnWindowCreated := nil;
|
||||
FOnWindowClosing := nil;
|
||||
FOnWindowDestroyed := nil;
|
||||
FOnWindowActivationChanged := nil;
|
||||
FOnWindowBoundsChanged := nil;
|
||||
FOnGetParentWindow := nil;
|
||||
FOnGetInitialBounds := nil;
|
||||
FOnGetInitialShowState := nil;
|
||||
FOnIsFrameless := nil;
|
||||
FOnWithStandardWindowButtons := nil;
|
||||
FOnGetTitlebarHeight := nil;
|
||||
FOnCanResize := nil;
|
||||
FOnCanMaximize := nil;
|
||||
FOnCanMinimize := nil;
|
||||
FOnCanClose := nil;
|
||||
FOnAccelerator := nil;
|
||||
FOnKeyEvent := nil;
|
||||
FOnWindowFullscreenTransition := nil;
|
||||
end;
|
||||
|
||||
procedure TCEFWindowComponent.CreateTopLevelWindow;
|
||||
@ -410,6 +414,12 @@ begin
|
||||
FOnKeyEvent(self, window_, event, aResult);
|
||||
end;
|
||||
|
||||
procedure TCEFWindowComponent.doOnWindowFullscreenTransition(const window_: ICefWindow; is_completed: boolean);
|
||||
begin
|
||||
if assigned(FOnWindowFullscreenTransition) then
|
||||
FOnWindowFullscreenTransition(self, window_, is_completed);
|
||||
end;
|
||||
|
||||
procedure TCEFWindowComponent.Show;
|
||||
begin
|
||||
if Initialized then FWindow.Show;
|
||||
|
@ -76,6 +76,7 @@ type
|
||||
procedure OnCanClose(const window_: ICefWindow; var aResult : boolean);
|
||||
procedure OnAccelerator(const window_: ICefWindow; command_id: Integer; var aResult : boolean);
|
||||
procedure OnKeyEvent(const window_: ICefWindow; const event: TCefKeyEvent; var aResult : boolean);
|
||||
procedure OnWindowFullscreenTransition(const window_: ICefWindow; is_completed: boolean);
|
||||
|
||||
public
|
||||
class function UnWrap(data: Pointer): ICefWindowDelegate;
|
||||
@ -100,6 +101,7 @@ type
|
||||
procedure OnCanClose(const window_: ICefWindow; var aResult : boolean); virtual;
|
||||
procedure OnAccelerator(const window_: ICefWindow; command_id: Integer; var aResult : boolean); virtual;
|
||||
procedure OnKeyEvent(const window_: ICefWindow; const event: TCefKeyEvent; var aResult : boolean); virtual;
|
||||
procedure OnWindowFullscreenTransition(const window_: ICefWindow; is_completed: boolean); virtual;
|
||||
|
||||
procedure InitializeCEFMethods; override;
|
||||
|
||||
@ -141,6 +143,7 @@ type
|
||||
procedure OnCanClose(const window_: ICefWindow; var aResult : boolean); override;
|
||||
procedure OnAccelerator(const window_: ICefWindow; command_id: Integer; var aResult : boolean); override;
|
||||
procedure OnKeyEvent(const window_: ICefWindow; const event: TCefKeyEvent; var aResult : boolean); override;
|
||||
procedure OnWindowFullscreenTransition(const window_: ICefWindow; is_completed: boolean); override;
|
||||
|
||||
public
|
||||
constructor Create(const events: ICefWindowDelegateEvents); reintroduce;
|
||||
@ -253,6 +256,11 @@ begin
|
||||
aResult := (PCefWindowDelegate(FData)^.on_key_event(PCefWindowDelegate(FData), CefGetData(window_), @event) <> 0);
|
||||
end;
|
||||
|
||||
procedure TCefWindowDelegateRef.OnWindowFullscreenTransition(const window_: ICefWindow; is_completed: boolean);
|
||||
begin
|
||||
PCefWindowDelegate(FData)^.on_window_fullscreen_transition(PCefWindowDelegate(FData), CefGetData(window_), ord(is_completed));
|
||||
end;
|
||||
|
||||
class function TCefWindowDelegateRef.UnWrap(data: Pointer): ICefWindowDelegate;
|
||||
begin
|
||||
if (data <> nil) then
|
||||
@ -460,6 +468,19 @@ begin
|
||||
Result := ord(TempResult);
|
||||
end;
|
||||
|
||||
procedure cef_window_delegate_on_window_fullscreen_transition(self : PCefWindowDelegate;
|
||||
window_ : PCefWindow;
|
||||
is_completed : integer); stdcall;
|
||||
var
|
||||
TempObject : TObject;
|
||||
begin
|
||||
TempObject := CefGetObject(self);
|
||||
|
||||
if (TempObject <> nil) and (TempObject is TCefWindowDelegateOwn) then
|
||||
TCefWindowDelegateOwn(TempObject).OnWindowFullscreenTransition(TCefWindowRef.UnWrap(window_),
|
||||
is_completed <> 0);
|
||||
end;
|
||||
|
||||
constructor TCefWindowDelegateOwn.Create;
|
||||
begin
|
||||
inherited CreateData(SizeOf(TCefWindowDelegate));
|
||||
@ -486,6 +507,7 @@ begin
|
||||
can_close := {$IFDEF FPC}@{$ENDIF}cef_window_delegate_can_close;
|
||||
on_accelerator := {$IFDEF FPC}@{$ENDIF}cef_window_delegate_on_accelerator;
|
||||
on_key_event := {$IFDEF FPC}@{$ENDIF}cef_window_delegate_on_key_event;
|
||||
on_window_fullscreen_transition := {$IFDEF FPC}@{$ENDIF}cef_window_delegate_on_window_fullscreen_transition;
|
||||
end;
|
||||
end;
|
||||
|
||||
@ -574,6 +596,11 @@ begin
|
||||
//
|
||||
end;
|
||||
|
||||
procedure TCefWindowDelegateOwn.OnWindowFullscreenTransition(const window_: ICefWindow; is_completed: boolean);
|
||||
begin
|
||||
//
|
||||
end;
|
||||
|
||||
|
||||
// **************************************************************
|
||||
// ******************* TCustomWindowDelegate ********************
|
||||
@ -883,6 +910,17 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TCustomWindowDelegate.OnWindowFullscreenTransition(const window_: ICefWindow; is_completed: boolean);
|
||||
begin
|
||||
try
|
||||
if (FEvents <> nil) then
|
||||
ICefWindowDelegateEvents(FEvents).doOnWindowFullscreenTransition(window_, is_completed);
|
||||
except
|
||||
on e : exception do
|
||||
if CustomExceptionHandler('TCustomWindowDelegate.OnWindowFullscreenTransition', e) then raise;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
end.
|
||||
|
||||
|
@ -2,9 +2,9 @@
|
||||
"UpdateLazPackages" : [
|
||||
{
|
||||
"ForceNotify" : true,
|
||||
"InternalVersion" : 482,
|
||||
"InternalVersion" : 483,
|
||||
"Name" : "cef4delphi_lazarus.lpk",
|
||||
"Version" : "112.2.10"
|
||||
"Version" : "112.3.0"
|
||||
}
|
||||
],
|
||||
"UpdatePackageData" : {
|
||||
|
Loading…
x
Reference in New Issue
Block a user