1
0
mirror of https://github.com/salvadordf/CEF4Delphi.git synced 2025-11-23 21:34:53 +02:00

Added touch support for Windows 8,8.1,10 to FMXExternalPumpBrowser

- Removed GestureBrowser demo
- Added TBufferPanel.OnWrongSize event
- Added TFMXBufferPanel.OnWrongSize event
- More touch support fixes in SimpleOSRBrowser and KioskOSRBrowser.
This commit is contained in:
Salvador Díaz Fau
2020-02-08 12:59:59 +01:00
parent 75258ea8e7
commit e8d2db5b57
19 changed files with 289 additions and 2005 deletions

View File

@@ -75,6 +75,7 @@ type
FScanlineSize : integer;
FTransparent : boolean;
FOnPaintParentBkg : TNotifyEvent;
FOnWrongSize : TNotifyEvent;
{$IFDEF MSWINDOWS}
FIMEHandler : TCEFOSRIMEHandler;
FOnIMECancelComposition : TNotifyEvent;
@@ -149,6 +150,7 @@ type
property OnPointerUpdate : TOnHandledMessageEvent read FOnPointerUpdate write FOnPointerUpdate;
{$ENDIF}
property OnPaintParentBkg : TNotifyEvent read FOnPaintParentBkg write FOnPaintParentBkg;
property OnWrongSize : TNotifyEvent read FOnWrongSize write FOnWrongSize;
property Transparent : boolean read FTransparent write SetTransparent default False;
@@ -255,9 +257,11 @@ constructor TBufferPanel.Create(AOwner: TComponent);
begin
inherited Create(AOwner);
FMutex := 0;
FBuffer := nil;
FTransparent := False;
FMutex := 0;
FBuffer := nil;
FTransparent := False;
FOnPaintParentBkg := nil;
FOnWrongSize := nil;
{$IFDEF MSWINDOWS}
FIMEHandler := nil;
@@ -390,12 +394,15 @@ begin
end;
function TBufferPanel.CopyBuffer : boolean;
{$IFDEF MSWINDOWS}
var
TempFunction : TBlendFunction;
{$ENDIF}
{$IFDEF MSWINDOWS}
TempFunction : TBlendFunction;
{$ENDIF}
TempWrongSize : boolean;
begin
Result := False;
Result := False;
TempWrongSize := False;
{$IFDEF MSWINDOWS}
if BeginBufferDraw then
try
@@ -422,11 +429,15 @@ begin
Result := BitBlt(Canvas.Handle, 0, 0, Width, Height,
FBuffer.Canvas.Handle, 0, 0,
SrcCopy);
TempWrongSize := (Width <> FBuffer.Width) or (Height <> FBuffer.Height);
end;
finally
EndBufferDraw;
end;
{$ENDIF}
if TempWrongSize and assigned(FOnWrongSize) then FOnWrongSize(self);
end;
procedure TBufferPanel.Paint;