Ejemplo n.º 1
0
        private void SetDeviceList()
        {
            string active = String.Empty;

            this.Invoke((Action) delegate
            {
                devicecheck.Clear();
            });

            List <DataModelDevicesItem> adbDevices      = ADB.Devices();
            List <DataModelDevicesItem> fastbootDevices = Fastboot.Devices();

            foreach (DataModelDevicesItem device in adbDevices)
            {
                this.Invoke((Action) delegate
                {
                    cAppend("Device adb connected!");
                    devicecheck.Add(" Device: Online! - ADB");
                    devicecheck.Add(" Mode: " + state);
                    listBoxDeviceStatus.DataSource = devicecheck;
                });
            }
            foreach (DataModelDevicesItem device in fastbootDevices)
            {
                this.Invoke((Action) delegate
                {
                    cAppend("Device fastboot connected!");
                    devicecheck.Add(" Device: Online! - FASTBOOT");
                    devicecheck.Add(" Mode: " + state);
                    listBoxDeviceStatus.DataSource = devicecheck;
                });
            }
            ADB.SelectDevice();
            Fastboot.SelectDevice();
        }
Ejemplo n.º 2
0
        private void SetDeviceList()
        {
            string active = String.Empty;

            List <DataModelDevicesItem> adbDevices      = ADB.Devices();
            List <DataModelDevicesItem> fastbootDevices = Fastboot.Devices();

            foreach (DataModelDevicesItem device in adbDevices)
            {
                this.Invoke((Action) delegate
                {
                    cAppend("Device: Online! - ADB");
                    cAppend("Device Codename: " + LoadDeviceServer.devicecodename);
                    cAppend("Mode: " + state);
                    cAppendDebloat("Device: Online! - ADB");
                    cAppendDebloat("Device Codename: " + LoadDeviceServer.devicecodename);
                    cAppendDebloat("Mode: " + state);
                });
            }
            foreach (DataModelDevicesItem device in fastbootDevices)
            {
                this.Invoke((Action) delegate
                {
                    cAppend("Device: Online! - FASTBOOT");
                    cAppend("Device Codename: " + LoadDeviceServer.devicecodename);
                    cAppend("Mode: " + state);
                    cAppendDebloat("Device: Online! - FASTBOOT");
                    cAppendDebloat("Device Codename: " + LoadDeviceServer.devicecodename);
                    cAppendDebloat("Mode: " + state);
                });
            }
            ADB.SelectDevice();
            Fastboot.SelectDevice();
        }