コード例 #1
0
 public CoordinatesVisualizer(LeapListener leapListener, TextBox coordTextBox, MainWindow mainWindow)
 {
     _leapListener = leapListener;
     _readingThread = new Thread(GetInfoFromLeap);
     _readingThread.Start();
     this.mainWindow = mainWindow;
     this.coordinatesTextBox = coordTextBox;
 }
コード例 #2
0
 public CoordinatesVisualizer(LeapListener leapListener, TextBox coordTextBox, MainWindow mainWindow)
 {
     _leapListener  = leapListener;
     _readingThread = new Thread(GetInfoFromLeap);
     _readingThread.Start();
     this.mainWindow         = mainWindow;
     this.coordinatesTextBox = coordTextBox;
 }
コード例 #3
0
ファイル: MainWindow.cs プロジェクト: tbarczyk/Lipmon
        private void Connect_Click(object sender, EventArgs e)
        {
            var device = groupBox1.Controls.OfType<RadioButton>().FirstOrDefault(n => n.Checked);
            leapListener = new LeapListener();

            robotController = new RobotController(leapListener, device != null ? (Device)device.Tag : Device.Platform);
            coordinatesVisualizer = new CoordinatesVisualizer(leapListener, coordinatesTextBox, this);
            ConnectedLabel.Visible = true;
        }
コード例 #4
0
        private void Connect_Click(object sender, EventArgs e)
        {
            var device = groupBox1.Controls.OfType <RadioButton>().FirstOrDefault(n => n.Checked);

            leapListener = new LeapListener();

            robotController        = new RobotController(leapListener, device != null ? (Device)device.Tag : Device.Platform);
            coordinatesVisualizer  = new CoordinatesVisualizer(leapListener, coordinatesTextBox, this);
            ConnectedLabel.Visible = true;
        }
コード例 #5
0
ファイル: RobotController.cs プロジェクト: tbarczyk/Lipmon
        public RobotController(LeapListener leapListener, Device device)
        {
            Console.WriteLine(device.ToString());
            _leapListener = leapListener;

            switch (device)
            {
                case Device.Platform:
                    deviceController = new PlatformController();
                    break;
                case Device.ArmBigger:
                    deviceController = new ArmBiggerController();
                    break;
                case Device.ArmSmaller:
                    deviceController = new ArmSmallerController();
                    break;
            }
            _controlThread = new Thread(controlRobot);
            _controlThread.Start();
        }
コード例 #6
0
ファイル: RobotController.cs プロジェクト: tobmek/Lipmon
        public RobotController(LeapListener leapListener, Device device)
        {
            Console.WriteLine(device.ToString());
            _leapListener = leapListener;

            switch (device)
            {
            case Device.Platform:
                deviceController = new PlatformController();
                break;

            case Device.ArmBigger:
                deviceController = new ArmBiggerController();
                break;

            case Device.ArmSmaller:
                deviceController = new ArmSmallerController();
                break;
            }
            _controlThread = new Thread(controlRobot);
            _controlThread.Start();
        }