private static void ApplyControllerState(OwlControllerBase controller, OwlDeviceStateBase state, bool stayAfterComplete) { if (state != null) { controller.ApplyState(state); } }
private static void SetControlEnabled(OwlControllerBase ctl, bool bEnabled) { if (ctl.IsControlEnabled != bEnabled) { ctl.IsControlEnabled = bEnabled; ctl.Initialize(); ctl.Recalibrate(); } }
private void CalibratePart(string partName) { var ignored2 = this.Dispatcher.RunAsync(CoreDispatcherPriority.Normal, () => { OwlControllerBase part = _owl.PartsList.Find(p => p.Name.ToLower() == partName.ToLower()); if (part != null) { part.Recalibrate(); } else { SetStatusLabel("Error calibrating " + partName + " - part not found."); } }); }