示例#1
0
        public CalibrationForm(AnalogSensorType type, Settings.DefaultSettings defSettings)
        {
            InitializeComponent();

            currentType     = type;
            defaultSettings = defSettings;
            btConnect.Tag   = true;

            btBackToMain.Tag    = false;
            btBackToMain.Click += new EventHandler((s, e) => Close());

            cbPort_DropDown(null, null);
            ApplyDefaultSettings();
            TranslateManual();
        }
示例#2
0
        public AnalogForm(AnalogSensorType type, DefaultSettings defSettings, Translation trans)
        {
            InitializeComponent();
            btBackToMain.Click += new EventHandler((s, e) => Close());

            // флаг подключить/отключить
            btConnect.Tag = btCalib.Tag = true;

            cbPort_DropDown(cbPort, null);

            this.Text        = Properties.Resources.AppName + " " + Properties.Resources.AppVersion;
            this.defSettings = defSettings;
            this.type        = type;

            currentTranslation = trans;
            if (currentTranslation != null)
            {
                TranslateManual(currentTranslation);
            }

            BindSettings(defSettings);

            connectStatus = ConnectionStatus.ConnectionUnknown;
        }