예제 #1
0
        private void SetupOK()
        {
            if (!IsTelescopeActive && TelescopeID != TelescopeSetupVm.TelescopeID)
            {
                TelescopeID = TelescopeSetupVm.TelescopeID;
                TelescopeManager.SetTelescopeID(TelescopeID);
            }

            if (!IsDomeActive && DomeID != DomeSetupVm.DomeID)
            {
                DomeID = DomeSetupVm.DomeID;
                DomeManager.SetDomeID(DomeID);
            }

            Globals.DomeLayout = DomeSetupVm.GetLayout();

            if (!IsFocuserActive && FocuserID != FocuserSetupVm.FocuserID)
            {
                FocuserID = FocuserSetupVm.FocuserID;
                FocuserManager.SetFocuserID(FocuserID);
            }

            Globals.SuppressTrayBubble       = SuppressTrayBubble;
            Globals.UseCustomTheme           = UseCustomTheme;
            Globals.FocuserTemperatureOffset = FocuserSetupVm.TemperatureOffset;

            SaveSettings();

            OnRequestClose(true);
        }
예제 #2
0
 public void InitializeCurrentDome(string domeID)
 {
     DomeID             = domeID;
     DomeSetupVm.DomeID = domeID;
     DomeSetupVm.Initialize(Globals.DomeLayout);
     IsDomeActive = DomeManager.Instance.IsConnected;
 }
예제 #3
0
 public void InitializeCurrentDome(string domeID, double fastUpdatePeriod)
 {
     DomeID             = domeID;
     DomeSetupVm.DomeID = domeID;
     DomeSetupVm.InitializeLayout(Globals.DomeLayout);
     DomeSetupVm.FastUpdatePeriod = fastUpdatePeriod;
     IsDomeActive = DomeManager.Instance.IsConnected;
 }
예제 #4
0
        protected override void DoDispose()
        {
            _setupOKCommand     = null;
            _setupCancelCommand = null;

            TelescopeSetupVm.Dispose();
            TelescopeSetupVm = null;
            DomeSetupVm.Dispose();
            DomeSetupVm = null;
            FocuserSetupVm.Dispose();
            FocuserSetupVm = null;
        }