Пример #1
0
        public FormConfiguration(CameraSummary summary)
        {
            this.summary = summary;
            specific     = summary.Specific as SpecificInfo;

            InitializeComponent();

            tbAlias.Text            = summary.Alias;
            lblSystemName.Text      = summary.Name;
            btnIcon.BackgroundImage = summary.Icon;

            cameraProperties = CameraPropertyManager.Read(specific);
            PopulateStreamFormat();
            PopulateCameraControls();
            this.Text     = CameraLang.FormConfiguration_Title;
            btnApply.Text = CameraLang.Generic_Apply;
        }
Пример #2
0
        private void cpvCameraControl_ValueChanged(object sender, EventArgs e)
        {
            AbstractCameraPropertyView control = sender as AbstractCameraPropertyView;

            if (control == null)
            {
                return;
            }

            string key = control.Tag as string;

            if (string.IsNullOrEmpty(key) || !cameraProperties.ContainsKey(key))
            {
                return;
            }

            CameraPropertyManager.Write(specific, control.Property);
            specificChanged = true;
            FixWidth();
        }