protected void ClickHandler() { // NOTE: is this right? if (Clicked == null) { ParentBar?.Toggle(); } else { Clicked?.Invoke(); } }
protected Task ClickHandler() { // NOTE: is this right? if (Clicked == null) { ParentBar?.Toggle(); } else { Clicked?.Invoke(); } return(Task.CompletedTask); }
/// <summary> /// Handles the toggler onclick event. /// </summary> /// <returns>A task that represents the asynchronous operation.</returns> protected Task ClickHandler() { if (Clicked.HasDelegate) { Clicked.InvokeAsync(null); } else if (Bar != null) { return(Bar.Toggle()); } else if (ParentBar != null) { return(ParentBar.Toggle()); } return(Task.CompletedTask); }
protected Task ClickHandler() { if (Clicked != null) { Clicked.Invoke(); } else if (Bar != null) { Bar.Toggle(); } else { ParentBar?.Toggle(); } return(Task.CompletedTask); }
/// <summary> /// Handles the toggler onclick event. /// </summary> /// <returns>A task that represents the asynchronous operation.</returns> protected async Task ClickHandler() { if (Clicked.HasDelegate) { await Clicked.InvokeAsync(); } if (Bar != null) { await Bar.Toggle(); DirtyClasses(); } else if (ParentBar != null) { await ParentBar.Toggle(); } }