1
0
mirror of https://github.com/salvadordf/CEF4Delphi.git synced 2025-06-12 22:07:39 +02:00

Update to CEF 3.3325.1755.g7c74b17

This commit is contained in:
Salvador Díaz Fau
2018-03-29 20:02:04 +02:00
parent 665957e132
commit 6fa50706a1
133 changed files with 7633 additions and 6008 deletions

View File

@ -78,7 +78,7 @@ type
FCallback : ICefJsDialogCallback;
procedure Chromium_OnJsdialog(Sender: TObject; const browser: ICefBrowser; const originUrl: ustring; dialogType: TCefJsDialogType; const messageText, defaultPromptText: ustring; const callback: ICefJsDialogCallback; out suppressMessage: Boolean; out Result: Boolean);
procedure Chromium_OnBeforePopup(Sender: TObject; const browser: ICefBrowser; const frame: ICefFrame; const targetUrl, targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean; var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo; var client: ICefClient; var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean; out Result: Boolean);
procedure Chromium_OnBeforePopup(Sender: TObject; const browser: ICefBrowser; const frame: ICefFrame; const targetUrl, targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean; const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo; var client: ICefClient; var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean; var Result: Boolean);
procedure WMMove(var aMessage : TWMMove); message WM_MOVE;
procedure WMMoving(var aMessage : TMessage); message WM_MOVING;
@ -212,10 +212,10 @@ end;
procedure TJSDialogBrowserFrm.Chromium_OnBeforePopup(Sender: TObject;
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
userGesture: Boolean; var popupFeatures: TCefPopupFeatures;
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
var windowInfo: TCefWindowInfo; var client: ICefClient;
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
out Result: Boolean);
var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);

View File

@ -90,9 +90,9 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
private
{ Private declarations }
@ -130,31 +130,29 @@ uses
// Steps to evaluate some JavaScript code using the V8Context
// ----------------------------------------------------------
// 1. Create a TCefCustomRenderProcessHandler in the DPR file, add a message name and set the OnCustomMessage event.
// 2. Set the TCefCustomRenderProcessHandler in the GlobalCEFApp.RenderProcessHandler property.
// 3. To get the Javascript code in this demo we use a context menu that sends a MINIBROWSER_EVALJSCODE to the form.
// 4. The EvalJSCodeMsg asks for the Javascript code and sends it to the renderer using a process message.
// 5. RenderProcessHandler_OnProcessMessageReceivedEvent receives the process message and calls ParseEvalJsAnswer
// 1. Set GlobalCEFApp.OnProcessMessageReceived to JSEvalFrm.RenderProcessHandler_OnProcessMessageReceivedEvent in the DPR file.
// 2. To get the Javascript code in this demo we use a context menu that sends a MINIBROWSER_EVALJSCODE to the form.
// 3. The EvalJSCodeMsg asks for the Javascript code and sends it to the renderer using a process message.
// 4. RenderProcessHandler_OnProcessMessageReceivedEvent receives the process message and calls ParseEvalJsAnswer
// to evaluate the code.
// 6. ParseEvalJsAnswer evaluates the code and sends a message with the results to the browser process using a
// 5. ParseEvalJsAnswer evaluates the code and sends a message with the results to the browser process using a
// process message.
// 7. Chromium1ProcessMessageReceived receives the message, stores the results and sends a
// 6. Chromium1ProcessMessageReceived receives the message, stores the results and sends a
// MINIBROWSER_SHOWTEXTVIEWER message to the form.
// 8. ShowTextViewerMsg shows the results safely using a SimpleTextViewer.
// 7. ShowTextViewerMsg shows the results safely using a SimpleTextViewer.
// This demo also has an example of binary parameters in process messages
// ----------------------------------------------------------------------
// 1. Create a TCefCustomRenderProcessHandler in the DPR file, add a message name and set the OnCustomMessage event.
// 2. Set the TCefCustomRenderProcessHandler in the GlobalCEFApp.RenderProcessHandler property.
// 3. The context menu has a 'Send JPEG image' option that sends a MINIBROWSER_JSBINPARAM message to the form.
// 4. EvalJSBinParamMsg asks for a JPEG image and sends a process message with a ICefBinaryValue parameter to the
// 1. Set GlobalCEFApp.OnProcessMessageReceived to JSEvalFrm.RenderProcessHandler_OnProcessMessageReceivedEvent in the DPR file.
// 2. The context menu has a 'Send JPEG image' option that sends a MINIBROWSER_JSBINPARAM message to the form.
// 3. EvalJSBinParamMsg asks for a JPEG image and sends a process message with a ICefBinaryValue parameter to the
// renderer process.
// 5. The renderer process parses the binary parameter in the ParseBinaryValue function and sends back the image
// 4. The renderer process parses the binary parameter in the ParseBinaryValue function and sends back the image
// size and encoded image data to the browser process.
// 6. Chromium1ProcessMessageReceived receives the message, stores the results and sends a
// 5. Chromium1ProcessMessageReceived receives the message, stores the results and sends a
// MINIBROWSER_SHOWTEXTVIEWER message to the form.
// 7. ShowTextViewerMsg shows the results safely using a SimpleTextViewer.
// 6. ShowTextViewerMsg shows the results safely using a SimpleTextViewer.
// About binary parameters
@ -185,10 +183,10 @@ end;
procedure TJSEvalFrm.Chromium1BeforePopup(Sender: TObject;
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
userGesture: Boolean; var popupFeatures: TCefPopupFeatures;
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
var windowInfo: TCefWindowInfo; var client: ICefClient;
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
out Result: Boolean);
var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);

View File

@ -12,6 +12,7 @@ object JSExecutingFunctionsFrm: TJSExecutingFunctionsFrm
Font.Style = []
OldCreateOrder = False
Position = poScreenCenter
OnDestroy = FormDestroy
OnShow = FormShow
PixelsPerInch = 96
TextHeight = 13

View File

@ -80,9 +80,10 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
procedure FormDestroy(Sender: TObject);
protected
procedure BrowserCreatedMsg(var aMessage : TMessage); message CEF_AFTERCREATED;
procedure WMMove(var aMessage : TWMMove); message WM_MOVE;
@ -174,10 +175,10 @@ end;
procedure TJSExecutingFunctionsFrm.Chromium1BeforePopup(Sender: TObject;
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
userGesture: Boolean; var popupFeatures: TCefPopupFeatures;
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
var windowInfo: TCefWindowInfo; var client: ICefClient;
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
out Result: Boolean);
var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);
@ -201,6 +202,12 @@ begin
end;
end;
procedure TJSExecutingFunctionsFrm.FormDestroy(Sender: TObject);
begin
GlobalCallbackFunc := nil;
GlobalCallbackContext := nil;
end;
procedure TJSExecutingFunctionsFrm.FormShow(Sender: TObject);
begin
// GlobalCEFApp.GlobalContextInitialized has to be TRUE before creating any browser

View File

@ -87,9 +87,9 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
protected
FText : string;
@ -184,10 +184,10 @@ end;
procedure TJSExtensionFrm.Chromium1BeforePopup(Sender: TObject;
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
userGesture: Boolean; var popupFeatures: TCefPopupFeatures;
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
var windowInfo: TCefWindowInfo; var client: ICefClient;
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
out Result: Boolean);
var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);

View File

@ -59,7 +59,6 @@ object JSExtensionWithFunctionFrm: TJSExtensionWithFunctionFrm
Height = 540
Align = alClient
TabOrder = 1
ExplicitHeight = 559
end
object StatusBar1: TStatusBar
Left = 0
@ -70,9 +69,6 @@ object JSExtensionWithFunctionFrm: TJSExtensionWithFunctionFrm
item
Width = 500
end>
ExplicitLeft = 336
ExplicitTop = 544
ExplicitWidth = 0
end
object Chromium1: TChromium
OnProcessMessageReceived = Chromium1ProcessMessageReceived

View File

@ -68,9 +68,9 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
procedure Chromium1ProcessMessageReceived(Sender: TObject;
const browser: ICefBrowser; sourceProcess: TCefProcessId;
const message: ICefProcessMessage; out Result: Boolean);
@ -138,10 +138,10 @@ end;
procedure TJSExtensionWithFunctionFrm.Chromium1BeforePopup(Sender: TObject;
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
userGesture: Boolean; var popupFeatures: TCefPopupFeatures;
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
var windowInfo: TCefWindowInfo; var client: ICefClient;
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
out Result: Boolean);
var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);

View File

@ -67,9 +67,9 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
protected
procedure BrowserCreatedMsg(var aMessage : TMessage); message CEF_AFTERCREATED;
procedure WMMove(var aMessage : TWMMove); message WM_MOVE;
@ -142,9 +142,9 @@ procedure TJSExtensionWithObjectParameterFrm.Chromium1BeforePopup(
Sender: TObject; const browser: ICefBrowser; const frame: ICefFrame;
const targetUrl, targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);

View File

@ -87,9 +87,9 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
protected
FText : string;
@ -163,10 +163,10 @@ end;
procedure TJSRTTIExtensionFrm.Chromium1BeforePopup(Sender: TObject;
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
userGesture: Boolean; var popupFeatures: TCefPopupFeatures;
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
var windowInfo: TCefWindowInfo; var client: ICefClient;
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
out Result: Boolean);
var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);

View File

@ -67,9 +67,9 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
protected
procedure BrowserCreatedMsg(var aMessage : TMessage); message CEF_AFTERCREATED;
procedure WMMove(var aMessage : TWMMove); message WM_MOVE;
@ -128,10 +128,10 @@ end;
procedure TJSSimpleExtensionFrm.Chromium1BeforePopup(Sender: TObject;
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
userGesture: Boolean; var popupFeatures: TCefPopupFeatures;
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
var windowInfo: TCefWindowInfo; var client: ICefClient;
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
out Result: Boolean);
var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);

View File

@ -68,9 +68,9 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
protected
procedure BrowserCreatedMsg(var aMessage : TMessage); message CEF_AFTERCREATED;
procedure WMMove(var aMessage : TWMMove); message WM_MOVE;
@ -121,10 +121,10 @@ end;
procedure TJSSimpleWindowBindingFrm.Chromium1BeforePopup(Sender: TObject;
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
userGesture: Boolean; var popupFeatures: TCefPopupFeatures;
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
var windowInfo: TCefWindowInfo; var client: ICefClient;
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
out Result: Boolean);
var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);

View File

@ -63,10 +63,9 @@ begin
// Follow these steps to test this demo :
// 1. Build the SubProcess project in this directory.
// 2. Copy the crash_reporter.cfg file to the BIN directory in CEF4Delphi.
// 3. Copy the CEF binaries to the BIN directory in CEF4Delphi.
// 4. Build this project : JSSimpleWindowBinding
// 5. Run this demo : JSSimpleWindowBinding
// 2. Copy the CEF binaries to the BIN directory in CEF4Delphi.
// 3. Build this project : JSSimpleWindowBinding
// 4. Run this demo : JSSimpleWindowBinding
GlobalCEFApp.BrowserSubprocessPath := 'SubProcess.exe';

View File

@ -72,8 +72,8 @@ begin
// The main process and the subprocess *MUST* have the same FrameworkDirPath, ResourcesDirPath,
// LocalesDirPath, cache, cookies and UserDataPath paths
// The demos are compiled into the BIN directory. Make sure the crash_reporter.cfg file is in that
// directory too or this demo won't work.
// The demos are compiled into the BIN directory. Make sure SubProcess.exe and JSSimpleWindowBinding.exe are in that
// directory or this demo won't work.
// In case you want to use custom directories for the CEF3 binaries, cache, cookies and user data.
{

View File

@ -68,9 +68,9 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
protected
procedure BrowserCreatedMsg(var aMessage : TMessage); message CEF_AFTERCREATED;
procedure WMMove(var aMessage : TWMMove); message WM_MOVE;
@ -107,10 +107,10 @@ end;
procedure TJSSimpleWindowBindingFrm.Chromium1BeforePopup(Sender: TObject;
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring; targetDisposition: TCefWindowOpenDisposition;
userGesture: Boolean; var popupFeatures: TCefPopupFeatures;
userGesture: Boolean; const popupFeatures: TCefPopupFeatures;
var windowInfo: TCefWindowInfo; var client: ICefClient;
var settings: TCefBrowserSettings; var noJavascriptAccess: Boolean;
out Result: Boolean);
var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);

View File

@ -67,9 +67,9 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
protected
procedure BrowserCreatedMsg(var aMessage : TMessage); message CEF_AFTERCREATED;
procedure WMMove(var aMessage : TWMMove); message WM_MOVE;
@ -126,9 +126,9 @@ procedure TJSWindowBindingWithFunctionFrm.Chromium1BeforePopup(
Sender: TObject; const browser: ICefBrowser; const frame: ICefFrame;
const targetUrl, targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);

View File

@ -67,9 +67,9 @@ type
const browser: ICefBrowser; const frame: ICefFrame; const targetUrl,
targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
protected
procedure BrowserCreatedMsg(var aMessage : TMessage); message CEF_AFTERCREATED;
procedure WMMove(var aMessage : TWMMove); message WM_MOVE;
@ -127,9 +127,9 @@ procedure TJSWindowBindingWithObjectFrm.Chromium1BeforePopup(
Sender: TObject; const browser: ICefBrowser; const frame: ICefFrame;
const targetUrl, targetFrameName: ustring;
targetDisposition: TCefWindowOpenDisposition; userGesture: Boolean;
var popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
const popupFeatures: TCefPopupFeatures; var windowInfo: TCefWindowInfo;
var client: ICefClient; var settings: TCefBrowserSettings;
var noJavascriptAccess: Boolean; out Result: Boolean);
var noJavascriptAccess: Boolean; var Result: Boolean);
begin
// For simplicity, this demo blocks all popup windows and new tabs
Result := (targetDisposition in [WOD_NEW_FOREGROUND_TAB, WOD_NEW_BACKGROUND_TAB, WOD_NEW_POPUP, WOD_NEW_WINDOW]);