Exemple #1
0
 /// <summary>
 /// Add a control to the accessory selection and settings window. The control is wrapped to properly respond to changes in selected accessory slot (has unique values for each slot).
 /// </summary>
 public static AccessoryControlWrapper <T, TVal> AddEditableAccessoryWindowControl <T, TVal>(T control) where T : BaseEditableGuiEntry <TVal>
 {
     if (control == null)
     {
         throw new ArgumentNullException(nameof(control));
     }
     control.ThrowIfDisposed(nameof(control));
     MakerInterfaceCreator.AddAccessoryWindowControl(control);
     return(new AccessoryControlWrapper <T, TVal>(control));
 }
Exemple #2
0
 /// <summary>
 /// Add a control to the accessory selection and settings window.
 /// For editable controls that depend on the selected accessory use <see cref="AddEditableAccessoryWindowControl{T,TVal}"/>.
 /// </summary>
 public static T AddAccessoryWindowControl <T>(T control) where T : BaseGuiEntry
 {
     if (control == null)
     {
         throw new ArgumentNullException(nameof(control));
     }
     control.ThrowIfDisposed(nameof(control));
     MakerInterfaceCreator.AddAccessoryWindowControl(control);
     return(control);
 }