コード例 #1
0
ファイル: Form1.cs プロジェクト: alwaysmy/TimeBoxJoyDriver
        private void Button4_Click(object sender, EventArgs e)
        {
            var device = this.manager.GetDevice(this.SelectIndex);

            if (device != null)
            {
                if (device.State == deviceState.CONNECT)
                {
                    MapEdit mForm = new MapEdit(this.manager, this.manager.mapConfigs, device);
                    mForm.ShowDialog();
                    mForm.Dispose();
                }
                else
                {
                    MessageBox.Show("设备未连接!");
                }
            }
        }
コード例 #2
0
        public void ShowEdit(int index)
        {
            var device = this.manager.GetDevice(index);

            if (device != null)
            {
                if (device.State == deviceState.CONNECT)
                {
                    MapEdit mForm = new MapEdit(this.manager, this.manager.mapConfigs, device);
                    mForm.ShowDialog();
                    mForm.Dispose();
                }
                else
                {
                    ShowMsg("设备未连接!");
                }
            }
        }