コード例 #1
0
        private void onlineAllListView_MouseDoubleClick(object sender, MouseEventArgs e)
        {
            ListViewHitTestInfo info = onlineAllListView.HitTest(e.X, e.Y);

            if (info.Item != null)
            {
                int        index  = info.Item.Index;
                BaseDevice device = deviceManager.getDevice(index);

                switch (device.CurrentDeviceType)
                {
                default:
                    DemoDeviceForm form2 = new DemoDeviceForm();
                    form2.FatherForm = this;
                    form2.DemoDevice = (DemoVirtualDevice)device;
                    form2.Show();
                    break;
                }
            }
        }
コード例 #2
0
ファイル: ControlForm.cs プロジェクト: hxd3/GTL2
        private void onlineAllListView_MouseDoubleClick(object sender, MouseEventArgs e)
        {
            ListViewHitTestInfo info = onlineAllListView.HitTest(e.X, e.Y);
            if (info.Item != null)
            {
                int index = info.Item.Index;
                BaseDevice device = deviceManager.getDevice(index);

                switch (device.CurrentDeviceType)
                {
                    default:
                        DemoDeviceForm form2 = new DemoDeviceForm();
                        form2.FatherForm = this;
                        form2.DemoDevice = (DemoVirtualDevice)device;
                        form2.Show();
                        break;
                }

            }
        }