Ejemplo n.º 1
0
        public LdalignControl(LuiConfig Config) : base(Config)
        {
            InitializeComponent();
            Init();

            Beta.ValueChanged += Beta_ValueChanged;
            SaveData.Click    += (sender, e) => SaveOutput();

            DdgConfigBox.Config    = Config;
            DdgConfigBox.Commander = Commander;
            DdgConfigBox.AllowZero = false;
            DdgConfigBox.HandleParametersChanged(this, EventArgs.Empty);
        }
Ejemplo n.º 2
0
        public TrldControl(LuiConfig Config) : base(Config)
        {
            InitializeComponent();
            Init();

            Beta.ValueChanged += Beta_ValueChanged;

            TimesList.AllowEdit            = false;
            TimesView.DefaultValuesNeeded += (sender, e) => { e.Row.Cells["Value"].Value = 0; };
            TimesView.DataSource           = new BindingSource(TimesList, null);
            TimesView.CellValidating      += TimesView_CellValidating;
            TimesView.CellEndEdit         += TimesView_CellEndEdit;

            SaveData.Click += (sender, e) => SaveOutput();

            DdgConfigBox.Config    = Config;
            DdgConfigBox.Commander = Commander;
            DdgConfigBox.AllowZero = false;
            DdgConfigBox.HandleParametersChanged(this, EventArgs.Empty);
        }
Ejemplo n.º 3
0
        public ResidualsControl(LuiConfig config) : base(config)
        {
            InitializeComponent();
            Graph.YLabelFormat = "g";

            SaveData.Click  += SaveData_Click;
            SaveData.Enabled = false;

            CollectLaser.CheckedChanged += CollectLaser_CheckedChanged;
            ImageMode.CheckedChanged    += ImageMode_CheckedChanged;
            FvbMode.CheckedChanged      += FvbMode_CheckedChanged;
            SoftFvbMode.CheckedChanged  += SoftFvbMode_CheckedChanged;

            GraphScroll.Scroll       += GraphScroll_Scroll;
            GraphScroll.ValueChanged += GraphScroll_ValueChanged;
            GraphScroll.Enabled       = false;
            GraphScroll.Minimum       = 0;
            GraphScroll.Maximum       = Commander.Camera.Height - 1;
            GraphScroll.LargeChange   = 1;
            SelectedRow = 0;

            CameraTemperature.Enabled = false;

            VBin.Minimum         = 1;
            VBin.Value           = 1;
            VBin.ValueChanged   += CameraImage_ValueChanged;
            VStart.Minimum       = 1;
            VStart.ValueChanged += CameraImage_ValueChanged;
            VEnd.Minimum         = 1;
            VEnd.ValueChanged   += CameraImage_ValueChanged;

            DdgConfigBox.Config    = Config;
            DdgConfigBox.Commander = Commander;
            DdgConfigBox.AllowZero = true;
            DdgConfigBox.Enabled   = false;
            DdgConfigBox.HandleParametersChanged(this, EventArgs.Empty);
        }
Ejemplo n.º 4
0
        public override void HandleParametersChanged(object sender, EventArgs e)
        {
            base.HandleParametersChanged(sender, e); // Takes care of ObjectSelectPanel.
            DdgConfigBox.HandleParametersChanged(sender, e);

            var PolarizersAvailable = Config.GetParameters(typeof(PolarizerParameters));

            if (PolarizersAvailable.Count() > 0)
            {
                var selectedPolarizer = PolarizerBox.SelectedObject;
                PolarizerBox.Objects.Items.Clear();
                foreach (var p in PolarizersAvailable)
                {
                    PolarizerBox.Objects.Items.Add(p);
                }
                // One of next two lines will trigger CameraChanged event.
                PolarizerBox.SelectedObject = selectedPolarizer;
                if (PolarizerBox.Objects.SelectedItem == null)
                {
                    PolarizerBox.Objects.SelectedIndex = 0;
                }

                Beta.Minimum = Commander.Polarizer.MinBeta;
                Beta.Maximum = Commander.Polarizer.MaxBeta;
                Beta.Value   = (decimal)Commander.Polarizer.PolarizerBeta;

                PolarizerBox.Enabled = true;
            }
            else
            {
                Beta.Minimum         = 0;
                Beta.Maximum         = 0;
                Beta.Value           = 0;
                PolarizerBox.Enabled = false;
            }
        }
Ejemplo n.º 5
0
 public override void HandleContainingTabSelected(object sender, EventArgs e)
 {
     base.HandleContainingTabSelected(sender, e);
     DdgConfigBox.UpdatePrimaryDelayValue();
 }