public SdlWindow(Sdl2Window window) { RawWindow = window; RawWindow.Closed += () => { Closed?.Invoke(); }; RawWindow.Resized += () => { Resized?.Invoke(); }; RawWindow.FocusLost += () => { FocusLost?.Invoke(); }; RawWindow.FocusGained += () => { FocusGained?.Invoke(); }; RawWindow.Closing += () => { Closing?.Invoke(); }; }
private void OnWindowFocusChanged(object sender, EventArgs e) { if (NativeWindow.Focused) { FocusGained?.Invoke(); } else { FocusLost?.Invoke(); } }
private void ChangeState(bool state) { Input.gameObject.SetActive(state); Label.gameObject.SetActive(!state); Activator.gameObject.SetActive(!state); if (state) { Input.ActivateInputField(); FocusGained?.Invoke(this); } else { FocusLost?.Invoke(this); } }
protected virtual void OnFocusLost(object sender, LeapEventArgs eventArgs) { FocusLost.DispatchOnContext <LeapEventArgs> (this, EventContext, eventArgs); }
protected override void OnFocusLost(FocusLostEvent e) { base.OnFocusLost(e); FocusLost?.Invoke(); }
public virtual void OnFocusLost() { FocusLost?.Invoke(this); }
public virtual void Dispose() { Owner = null; FocusLost?.Invoke(this, EventArgs.Empty); }
protected void OnFocusLost() { _hasFocus = false; FocusLost.InvokeAsync(null); }
protected virtual void OnFocusLost() => FocusLost?.Invoke();
protected virtual void OnFocusLost() { FocusLost?.Invoke(this, EventArgs.Empty); }