public unsafe int OnSetFocus(cef_browser_t *browser, CefFocusSource source) { fixed(cef_focus_handler_t *self = &this) { return(((delegate * unmanaged[Stdcall] < cef_focus_handler_t *, cef_browser_t *, CefFocusSource, int >)on_set_focus)(self, browser, source)); } }
protected override bool OnSetFocus(CefBrowser browser, CefFocusSource source) { if (source == CefFocusSource.Navigation) { return(true); } return(false); }
private int on_set_focus(cef_focus_handler_t* self, cef_browser_t* browser, CefFocusSource source) { CheckSelf(self); var m_browser = CefBrowser.FromNative(browser); return OnSetFocus(m_browser, source) ? 1 : 0; }
private int on_set_focus(cef_focus_handler_t *self, cef_browser_t *browser, CefFocusSource source) { CheckSelf(self); var m_browser = CefBrowser.FromNative(browser); return(OnSetFocus(m_browser, source) ? 1 : 0); }
protected override bool OnSetFocus(CefBrowser browser, CefFocusSource source) { var e = new SetFocusEventArgs(source); _owner.OnSetFocus(e); return(!e.Cancel); }
/// <summary> /// Called when the browser component is requesting focus. |source| indicates /// where the focus request is originating from. Return false (0) to allow the /// focus to be set or true (1) to cancel setting the focus. /// </summary> public unsafe virtual bool OnSetFocus(CefBrowser browser, CefFocusSource source) { return(default);
public virtual bool OnSetFocus(CefFocusSource source) { // Do not let the browser take focus when a Load method has been called return source == CefFocusSource.FocusSourceNavigation; }
protected override Boolean OnSetFocus(CefBrowser browser, CefFocusSource source) { Log.Trace("FocusHandler.OnSetFocus( browser: {0}, source: {1} )", browser.Identifier, Enum.GetName(typeof(CefFocusSource), source)); return(base.OnSetFocus(browser, source)); }
/// <summary> /// Called when the browser component is requesting focus. |source| indicates /// where the focus request is originating from. Return false (0) to allow the /// focus to be set or true (1) to cancel setting the focus. /// </summary> protected internal unsafe virtual bool OnSetFocus(CefBrowser browser, CefFocusSource source) { return(default);
/// <summary> /// Called when the browser component is requesting focus. /// </summary> /// <param name="chromiumWebBrowser">the ChromiumWebBrowser control</param> /// <param name="browser">the browser object, do not keep a reference to this object outside of this method</param> /// <param name="source">Indicates where the focus request is originating from.</param> /// <returns>Return false to allow the focus to be set or true to cancel setting the focus.</returns> protected virtual bool OnSetFocus(IWebBrowser chromiumWebBrowser, IBrowser browser, CefFocusSource source) { return(false); }
protected internal unsafe override bool OnSetFocus(CefBrowser browser, CefFocusSource source) { return(_implementation.OnSetFocus(browser, source)); }
protected override bool OnSetFocus(CefBrowser browser, CefFocusSource source) { return(OwnerWebView.OnSetFocus(source == CefFocusSource.System)); }
public unsafe extern int OnSetFocus(cef_browser_t *browser, CefFocusSource source);
protected override bool OnSetFocus(CefBrowser browser, CefFocusSource source) { return(base.OnSetFocus(browser, source)); }
public override bool OnSetFocus(CefBrowser browser, CefFocusSource source) { return(_implementation.OnSetFocus(browser, source)); }
public bool OnSetFocus(CefFocusSource source) { // Returning false means that we allow Chromium to take the focus away from our WinForms control. // You could also return true to keep focus in the address bar. return false; }
/// <summary> /// 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. /// </summary> // protected abstract void OnTakeFocus(cef_browser_t* browser, int next); private int on_set_focus(cef_focus_handler_t *self, cef_browser_t *browser, CefFocusSource source) { CheckSelf(self); throw new NotImplementedException(); // TODO: CefFocusHandler.OnSetFocus }
public SetFocusEventArgs(CefFocusSource source) { Source = source; }
bool IFocusHandler.OnSetFocus(IWebBrowser chromiumWebBrowser, IBrowser browser, CefFocusSource source) { if (browser.IsPopup) { return(false); } //Don't take focus return(true); }
/// <summary> /// Called when the browser component is requesting focus. /// </summary> /// <param name="chromiumWebBrowser">the ChromiumWebBrowser control</param> /// <param name="browser">the browser object</param> /// <param name="source">Indicates where the focus request is originating from.</param> /// <returns>Return false to allow the focus to be set or true to cancel setting the focus.</returns> public virtual bool OnSetFocus(IWebBrowser chromiumWebBrowser, IBrowser browser, CefFocusSource source) { //We don't deal with popups as they're rendered by default entirely by CEF if (browser.IsPopup) { return(false); } var focusSourceNavigation = source == CefFocusSource.FocusSourceNavigation; var winFormsBrowser = (ChromiumWebBrowser)chromiumWebBrowser; //The default behaviour when browser is activated by default //This was the default prior to version 73 if (winFormsBrowser.ActivateBrowserOnCreation) { // Do not let the browser take focus when a Load method has been called return(focusSourceNavigation); } //For the very first navigation we let the browser //take focus so touch screens work correctly. //See https://github.com/cefsharp/CefSharp/issues/2776 if (!initialFocusOnNavigation && focusSourceNavigation) { initialFocusOnNavigation = true; return(false); } // Do not let the browser take focus when a Load method has been called return(focusSourceNavigation); }
public bool OnSetFocus(CefFocusSource source) { // Returning false means that we allow Chromium to take the focus away from our WinForms control. // You could also return true to keep focus in the address bar. return(false); }
public bool OnSetFocus(CefFocusSource source) { return false; }
public virtual bool OnSetFocus(CefFocusSource source) { // Do not let the browser take focus when a Load method has been called return(source == CefFocusSource.FocusSourceNavigation); }
bool IFocusHandler.OnSetFocus(IWebBrowser chromiumWebBrowser, IBrowser browser, CefFocusSource source) { return(OnSetFocus(chromiumWebBrowser, browser, source)); }
/// <summary> /// 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. /// </summary> protected virtual bool OnSetFocus(CefBrowser browser, CefFocusSource source) { return false; }
/// <summary> /// Called when the browser component is requesting focus. /// </summary> /// <param name="chromiumWebBrowser">the ChromiumWebBrowser control</param> /// <param name="browser">the browser object, do not keep a reference to this object outside of this method</param> /// <param name="source">Indicates where the focus request is originating from.</param> /// <returns>Return false to allow the focus to be set or true to cancel setting the focus.</returns> protected virtual bool OnSetFocus(IWebBrowser chromiumWebBrowser, IBrowser browser, CefFocusSource source) { //We don't deal with popups as they're rendered by default entirely by CEF if (browser.IsPopup) { return(false); } // Do not let the browser take focus when a Load method has been called return(source == CefFocusSource.FocusSourceNavigation); }
/// <summary> /// Called when the browser component is requesting focus. Return false to allow /// the focus to be set or true to cancel setting the focus. /// </summary> /// <param name="browser"></param> /// <param name="source"> /// Indicates where the focus request is originating from. /// </param> /// <returns>Return false to allow the focus to be set or true to cancel setting the focus.</returns> internal protected virtual bool OnSetFocus(CefBrowser browser, CefFocusSource source) { return(false); }
public bool OnSetFocus(IWebBrowser chromiumWebBrowser, IBrowser browser, CefFocusSource source) => false;
public bool OnSetFocus(CefFocusSource source) { return(false); }
protected override bool OnSetFocus(CefBrowser browser, CefFocusSource source) { //Console.WriteLine ("OnSetFocus"); //System.Diagnostics.Debug.WriteLine(", OnSetFocus: " + source.ToString()); return(base.OnSetFocus(browser, source)); }