Overview   Project   Class   Tree   Index 
CEF C++ API Docs - Revision 1123
FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD

(default)
Class CefBrowser

CefBase
   |
   +--CefBrowser

   in cef_browser.h

class CefBrowser
extends CefBase

Class used to represent a browser window. The methods of this class may be called on any thread unless otherwise indicated in the comments.


Inner Classes, Typedefs, and Enums
typedef CefBrowser::KeyType
          
typedef CefBrowser::MouseButtonType
          
typedef CefBrowser::PaintElementType
          
 
Method Summary
 virtual bool CanGoBack()= 0
          Returns true if the browser can navigate backwards.
 virtual bool CanGoForward()= 0
          Returns true if the browser can navigate forwards.
 virtual void ClearHistory()= 0
          Clear the back/forward browsing history.
 virtual void CloseBrowser()= 0
          Closes this browser window.
 virtual void CloseDevTools()= 0
          Explicitly close the developer tools window if one exists for this browser instance.
 static bool CreateBrowser( CefWindowInfo& windowInfo, CefRefPtr< CefClient > client, const CefString& url, const CefBrowserSettings& settings )
          Create a new browser window using the window parameters specified by |windowInfo|.
 static CefRefPtr< CefBrowser > CreateBrowserSync( CefWindowInfo& windowInfo, CefRefPtr< CefClient > client, const CefString& url, const CefBrowserSettings& settings )
          Create a new browser window using the window parameters specified by |windowInfo|.
 virtual void Find( int identifier, const CefString& searchText, bool forward, bool matchCase, bool findNext )= 0
          Search for |searchText|.
 virtual CefRefPtr< CefClient > GetClient()= 0
          Returns the client for this browser.
 virtual CefRefPtr< CefFrame > GetFocusedFrame()= 0
          Returns the focused frame for the browser window.
 virtual CefRefPtr< CefFrame > GetFrame( const CefString& name )= 0
          Returns the frame with the specified name, or NULL if not found.
 virtual void GetFrameNames( std::vector< CefString >& names )= 0
          Returns the names of all existing frames.
 virtual int GetIdentifier()= 0
          Returns the globally unique identifier for this browser.
 virtual bool GetImage( CefBrowser::PaintElementType type, int width, int height, void* buffer )= 0
          Get the raw image data contained in the specified element without performing validation.
 virtual CefRefPtr< CefFrame > GetMainFrame()= 0
          Returns the main (top-level) frame for the browser window.
 virtual CefWindowHandle GetOpenerWindowHandle()= 0
          Retrieve the window handle of the browser that opened this browser.
 virtual bool GetSize( CefBrowser::PaintElementType type, int& width, int& height )= 0
          Get the size of the specified element.
 virtual CefWindowHandle GetWindowHandle()= 0
          Retrieve the window handle for this browser.
 virtual double GetZoomLevel()= 0
          Get the current zoom level.
 virtual void GoBack()= 0
          Navigate backwards.
 virtual void GoForward()= 0
          Navigate forwards.
 virtual bool HasDocument()= 0
          
 virtual void HidePopup()= 0
          Hide the currently visible popup, if any.
 virtual void Invalidate( const CefRect& dirtyRect )= 0
          Invalidate the |dirtyRect| region of the view.
 virtual bool IsPopup()= 0
          Returns true if the window is a popup window.
 virtual bool IsPopupVisible()= 0
          Returns true if a popup is currently visible.
 virtual bool IsWindowRenderingDisabled()= 0
          Returns true if window rendering is disabled.
 virtual void ParentWindowWillClose()= 0
          Call this method before destroying a contained browser window.
 virtual void Reload()= 0
          Reload the current page.
 virtual void ReloadIgnoreCache()= 0
          Reload the current page ignoring any cached data.
 virtual void SendCaptureLostEvent()= 0
          Send a capture lost event to the browser.
 virtual void SendFocusEvent( bool setFocus )= 0
          Send a focus event to the browser.
 virtual void SendKeyEvent( CefBrowser::KeyType type, const CefKeyInfo& keyInfo, int modifiers )= 0
          Send a key event to the browser.
 virtual void SendMouseClickEvent( int x, int y, CefBrowser::MouseButtonType type, bool mouseUp, int clickCount )= 0
          Send a mouse click event to the browser.
 virtual void SendMouseMoveEvent( int x, int y, bool mouseLeave )= 0
          Send a mouse move event to the browser.
 virtual void SendMouseWheelEvent( int x, int y, int deltaX, int deltaY )= 0
          Send a mouse wheel event to the browser.
 virtual void SetFocus( bool enable )= 0
          Set focus for the browser window.
 virtual void SetSize( CefBrowser::PaintElementType type, int width, int height )= 0
          Set the size of the specified element.
 virtual void SetZoomLevel( double zoomLevel )= 0
          Change the zoom level to the specified value.
 virtual void ShowDevTools()= 0
          Open developer tools in its own window.
 virtual void StopFinding( bool clearSelection )= 0
          Cancel all searches that are currently going on.
 virtual void StopLoad()= 0
          Stop loading the page.
   
Methods inherited from class CefBase
AddRef, Release, GetRefCt
 

Method Detail

CanGoBack

public virtual bool CanGoBack()= 0;
Returns true if the browser can navigate backwards.

CanGoForward

public virtual bool CanGoForward()= 0;
Returns true if the browser can navigate forwards.

ClearHistory

public virtual void ClearHistory()= 0;
Clear the back/forward browsing history.

CloseBrowser

public virtual void CloseBrowser()= 0;
Closes this browser window.

CloseDevTools

public virtual void CloseDevTools()= 0;
Explicitly close the developer tools window if one exists for this browser instance.

CreateBrowser

public static bool CreateBrowser( CefWindowInfo& windowInfo, CefRefPtr< CefClient > client, const CefString& url, const CefBrowserSettings& settings );
Create a new browser window using the window parameters specified by |windowInfo|. All values will be copied internally and the actual window will be created on the UI thread. This method call will not block.

CreateBrowserSync

public static CefRefPtr< CefBrowser > CreateBrowserSync( CefWindowInfo& windowInfo, CefRefPtr< CefClient > client, const CefString& url, const CefBrowserSettings& settings );
Create a new browser window using the window parameters specified by |windowInfo|. This method should only be called on the UI thread.

Find

public virtual void Find( int identifier, const CefString& searchText, bool forward, bool matchCase, bool findNext )= 0;
Search for |searchText|. |identifier| can be used to have multiple searches running simultaniously. |forward| indicates whether to search forward or backward within the page. |matchCase| indicates whether the search should be case-sensitive. |findNext| indicates whether this is the first request or a follow-up.

GetClient

public virtual CefRefPtr< CefClient > GetClient()= 0;
Returns the client for this browser.

GetFocusedFrame

public virtual CefRefPtr< CefFrame > GetFocusedFrame()= 0;
Returns the focused frame for the browser window. This method should only be called on the UI thread.

GetFrame

public virtual CefRefPtr< CefFrame > GetFrame( const CefString& name )= 0;
Returns the frame with the specified name, or NULL if not found. This method should only be called on the UI thread.

GetFrameNames

public virtual void GetFrameNames( std::vector< CefString >& names )= 0;
Returns the names of all existing frames. This method should only be called on the UI thread.

GetIdentifier

public virtual int GetIdentifier()= 0;
Returns the globally unique identifier for this browser.

GetImage

public virtual bool GetImage( CefBrowser::PaintElementType type, int width, int height, void* buffer )= 0;
Get the raw image data contained in the specified element without performing validation. The specified |width| and |height| dimensions must match the current element size. On Windows |buffer| must be width*height*4 bytes in size and represents a BGRA image with an upper-left origin. This method should only be called on the UI thread.

GetMainFrame

public virtual CefRefPtr< CefFrame > GetMainFrame()= 0;
Returns the main (top-level) frame for the browser window.

GetOpenerWindowHandle

public virtual CefWindowHandle GetOpenerWindowHandle()= 0;
Retrieve the window handle of the browser that opened this browser. Will return NULL for non-popup windows. This method can be used in combination with custom handling of modal windows.

GetSize

public virtual bool GetSize( CefBrowser::PaintElementType type, int& width, int& height )= 0;
Get the size of the specified element. This method should only be called on the UI thread.

GetWindowHandle

public virtual CefWindowHandle GetWindowHandle()= 0;
Retrieve the window handle for this browser.

GetZoomLevel

public virtual double GetZoomLevel()= 0;
Get the current zoom level. The default zoom level is 0.0. This method can only be called on the UI thread.

GoBack

public virtual void GoBack()= 0;
Navigate backwards.

GoForward

public virtual void GoForward()= 0;
Navigate forwards.

HasDocument

public virtual bool HasDocument()= 0;

HidePopup

public virtual void HidePopup()= 0;
Hide the currently visible popup, if any.

Invalidate

public virtual void Invalidate( const CefRect& dirtyRect )= 0;
Invalidate the |dirtyRect| region of the view. This method is only used when window rendering is disabled and will result in a call to HandlePaint().

IsPopup

public virtual bool IsPopup()= 0;
Returns true if the window is a popup window.

IsPopupVisible

public virtual bool IsPopupVisible()= 0;
Returns true if a popup is currently visible. This method should only be called on the UI thread.

IsWindowRenderingDisabled

public virtual bool IsWindowRenderingDisabled()= 0;
Returns true if window rendering is disabled.

ParentWindowWillClose

public virtual void ParentWindowWillClose()= 0;
Call this method before destroying a contained browser window. This method performs any internal cleanup that may be needed before the browser window is destroyed.

Reload

public virtual void Reload()= 0;
Reload the current page.

ReloadIgnoreCache

public virtual void ReloadIgnoreCache()= 0;
Reload the current page ignoring any cached data.

SendCaptureLostEvent

public virtual void SendCaptureLostEvent()= 0;
Send a capture lost event to the browser.

SendFocusEvent

public virtual void SendFocusEvent( bool setFocus )= 0;
Send a focus event to the browser.

SendKeyEvent

public virtual void SendKeyEvent( CefBrowser::KeyType type, const CefKeyInfo& keyInfo, int modifiers )= 0;
Send a key event to the browser.

SendMouseClickEvent

public virtual void SendMouseClickEvent( int x, int y, CefBrowser::MouseButtonType type, bool mouseUp, int clickCount )= 0;
Send a mouse click event to the browser. The |x| and |y| coordinates are relative to the upper-left corner of the view.

SendMouseMoveEvent

public virtual void SendMouseMoveEvent( int x, int y, bool mouseLeave )= 0;
Send a mouse move event to the browser. The |x| and |y| coordinates are relative to the upper-left corner of the view.

SendMouseWheelEvent

public virtual void SendMouseWheelEvent( int x, int y, int deltaX, int deltaY )= 0;
Send a mouse wheel event to the browser. The |x| and |y| coordinates are relative to the upper-left corner of the view. The |deltaX| and |deltaY| values represent the movement delta in the X and Y directions respectively.

SetFocus

public virtual void SetFocus( bool enable )= 0;
Set focus for the browser window. If |enable| is true focus will be set to the window. Otherwise, focus will be removed.

SetSize

public virtual void SetSize( CefBrowser::PaintElementType type, int width, int height )= 0;
Set the size of the specified element. This method is only used when window rendering is disabled.

SetZoomLevel

public virtual void SetZoomLevel( double zoomLevel )= 0;
Change the zoom level to the specified value. Specify 0.0 to reset the zoom level. The change will be applied asynchronously on the UI thread.

ShowDevTools

public virtual void ShowDevTools()= 0;
Open developer tools in its own window.

StopFinding

public virtual void StopFinding( bool clearSelection )= 0;
Cancel all searches that are currently going on.

StopLoad

public virtual void StopLoad()= 0;
Stop loading the page.

 Overview   Project   Class   Tree   Index 
CEF C++ API Docs - Revision 1123
FRAMES    NO FRAMES
SUMMARY:  INNER | FIELD | CONSTR | METHOD

Chromium Embedded Framework (CEF) Copyright © 2011 Marshall A. Greenblatt