Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Latest commit

 

History

History
History
62 lines (42 loc) · 1.6 KB

File metadata and controls

62 lines (42 loc) · 1.6 KB
Copy raw file
Download raw file
Outline
Edit and raw actions

API categories | API index

FocusHandler (interface)

Implement this interface to handle events related to focus. The methods of this class will be called on the UI thread.

Table of contents:

Callbacks

OnTakeFocus

Parameter Type
browser Browser
next_component bool
Return void

Description from upstream CEF:

Called when the browser component is about to loose focus. For instance, if focus was on the last HTML element and the user pressed the TAB key. |next| will be true if the browser is giving focus to the next component and false if the browser is giving focus to the previous component.

OnSetFocus

Parameter Type
browser Browser
source cef_focus_source_t
Return bool

Description from upstream CEF:

Called when the browser component is requesting focus. |source| indicates where the focus request is originating from. Return false to allow the focus to be set or true to cancel setting the focus.

The cef_focus_source_t enum constants in the cefpython module:

  • FOCUS_SOURCE_NAVIGATION (The source is explicit navigation via the API (LoadURL(), etc))
  • FOCUS_SOURCE_SYSTEM (The source is a system-generated focus event)

OnGotFocus

Parameter Type
browser Browser
Return void

Description from upstream CEF:

Called when the browser component has received focus.

Morty Proxy This is a proxified and sanitized view of the page, visit original site.