Skip to content

Wrapper for: #6

@tyy-dev

Description

@tyy-dev
 /// <returns>The view instance.</returns>
 public T OnSchemeChanging(Action<ValueChangingEventArgs<Scheme>> callback)
 {
     view.SchemeChanging += (_, e) => callback(e);
     return view;
 }

 /// <summary>
 ///     Subscribes to the <see cref="View.SchemeNameChanged" /> event.
 /// </summary>
 /// <param name="callback">The callback to invoke with the <see cref="ValueChangedEventArgs{T}" /> containing the old and new scheme names.</param>
 /// <returns>The view instance.</returns>
 public T OnSchemeNameChanged(Action<ValueChangedEventArgs<string>> callback)
 {
     view.SchemeNameChanged += (_, e) => callback(e);
     return view;
 }

So we can just define them as a Dictionary maybe? This is DRY Violating

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions