# Class TCefBrowserProcessHandlerOwn

Description
Hierarchy
Fields
Methods
Properties

## Unit

uCEFBrowserProcessHandler

## Declaration

`type TCefBrowserProcessHandlerOwn = class(TCefBaseRefCountedOwn, ICefBrowserProcessHandler)`

## Description

This item has no description.

## Hierarchy

- TInterfacedObject
- TCefBaseRefCountedOwn
- TCefBrowserProcessHandlerOwn

## Overview

### Methods

| `procedure OnRegisterCustomPreferences(type_: TCefPreferencesType; registrar: PCefPreferenceRegistrar); virtual; abstract;`
| `procedure OnContextInitialized; virtual; abstract;`
| `procedure OnBeforeChildProcessLaunch(const commandLine: ICefCommandLine); virtual; abstract;`
| `procedure OnAlreadyRunningAppRelaunch(const commandLine: ICefCommandLine; const current_directory: ustring; var aResult: boolean); virtual; abstract;`
| `procedure OnScheduleMessagePumpWork(const delayMs: Int64); virtual; abstract;`
| `procedure GetDefaultClient(var aClient : ICefClient); virtual;`
| `procedure GetDefaultRequestContextHandler(var aRequestContextHandler : ICefRequestContextHandler); virtual;`
| `procedure RemoveReferences; virtual; abstract;`
| `constructor Create; virtual;`

## Description

### Methods

| `procedure OnRegisterCustomPreferences(type_: TCefPreferencesType; registrar: PCefPreferenceRegistrar); virtual; abstract;`
This item has no description. Showing description inherited from ICefBrowserProcessHandler.OnRegisterCustomPreferences. Provides an opportunity to register custom preferences prior to global and request context initialization. If |type| is CEF_PREFERENCES_TYPE_GLOBAL the registered preferences can be accessed via ICefPreferenceManager.GetGlobalPreferences after OnContextInitialized is called. Global preferences are registered a single time at application startup. See related TCefSettings.cache_path configuration. If |type| is CEF_PREFERENCES_TYPE_REQUEST_CONTEXT the preferences can be accessed via the ICefRequestContext after ICefRequestContextHandler.OnRequestContextInitialized is called. Request context preferences are registered each time a new ICefRequestContext is created. It is intended but not required that all request contexts have the same registered preferences. See related TCefRequestContextSettings.cache_path configuration. Do not keep a reference to the |registrar| object. This function is called on the browser process UI thread.

| `procedure OnContextInitialized; virtual; abstract;`
This item has no description. Showing description inherited from ICefBrowserProcessHandler.OnContextInitialized. Called on the browser process UI thread immediately after the CEF context has been initialized.

| `procedure OnBeforeChildProcessLaunch(const commandLine: ICefCommandLine); virtual; abstract;`
This item has no description. Showing description inherited from ICefBrowserProcessHandler.OnBeforeChildProcessLaunch. Called before a child process is launched. Will be called on the browser process UI thread when launching a render process and on the browser process IO thread when launching a GPU process. Provides an opportunity to modify the child process command line. Do not keep a reference to |command_line| outside of this function.

| `procedure OnAlreadyRunningAppRelaunch(const commandLine: ICefCommandLine; const current_directory: ustring; var aResult: boolean); virtual; abstract;`
This item has no description. Showing description inherited from ICefBrowserProcessHandler.OnAlreadyRunningAppRelaunch. Implement this function to provide app-specific behavior when an already running app is relaunched with the same TCefSettings.root_cache_path value. For example, activate an existing app window or create a new app window. |command_line| will be read-only. Do not keep a reference to |command_line| outside of this function. Return true (1) if the relaunch is handled or false (0) for default relaunch behavior. Default behavior will create a new default styled Chrome window. To avoid cache corruption only a single app instance is allowed to run for a given TCefSettings.root_cache_path value. On relaunch the app checks a process singleton lock and then forwards the new launch arguments to the already running app process before exiting early. Client apps should therefore check the cef_initialize() return value for early exit before proceeding. This function will be called on the browser process UI thread.

| `procedure OnScheduleMessagePumpWork(const delayMs: Int64); virtual; abstract;`
This item has no description. Showing description inherited from ICefBrowserProcessHandler.OnScheduleMessagePumpWork. Called from any thread when work has been scheduled for the browser process main (UI) thread. This callback is used in combination with TCefSettings.external_message_pump and GlobalCEFApp.DoMessageLoopWork in cases where the CEF message loop must be integrated into an existing application message loop (see additional comments and warnings on GlobalCEFApp.DoMessageLoopWork). This callback should schedule a GlobalCEFApp.DoMessageLoopWork call to happen on the main (UI) thread. |delay_ms| is the requested delay in milliseconds. If |delay_ms| is <= 0 then the call should happen reasonably soon. If |delay_ms| is > 0 then the call should be scheduled to happen after the specified delay and any currently pending scheduled call should be cancelled.

| `procedure GetDefaultClient(var aClient : ICefClient); virtual;`
This item has no description. Showing description inherited from ICefBrowserProcessHandler.GetDefaultClient. Return the default client for use with a newly created browser window (TCefBrowser object). If null is returned the TCefBrowser will be unmanaged (no callbacks will be executed for that TCefBrowser) and application shutdown will be blocked until the browser window is closed manually. This function is currently only used with Chrome style when creating new browser windows via Chrome UI.

| `procedure GetDefaultRequestContextHandler(var aRequestContextHandler : ICefRequestContextHandler); virtual;`
This item has no description. Showing description inherited from ICefBrowserProcessHandler.GetDefaultRequestContextHandler. Return the default handler for use with a new user or incognito profile (TCefRequestContext object). If null is returned the TCefRequestContext will be unmanaged (no callbacks will be executed for that TCefRequestContext). This function is currently only used with Chrome style when creating new browser windows via Chrome UI.

| `procedure RemoveReferences; virtual; abstract;`
This item has no description. Showing description inherited from ICefBrowserProcessHandler.RemoveReferences. Custom procedure to clear all references.

| `constructor Create; virtual;`
This item has no description.

Generated by PasDoc 0.16.0-snapshot.