public void InputMain(Mainwindow mainwindow) { var bootwindow = mainwindow.bootwindow; bootwindow.ToRightButton.Visibility = Visibility.Hidden; bootwindow.ToLeftButton.Visibility = Visibility.Hidden; var listdv = mainwindow.TADB.GetDevices(); if (listdv.Count() >= 1) { //select the working device mainwindow.TADB.SetDevice(listdv[0]); bootwindow.NaviSetion2(); } else { DeviceChange deviceChange = null; deviceChange = (e, s) => { mainwindow.TADB.SetDevice(s); bootwindow.NaviSetion2(); mainwindow.TADB.OndeivceConnect -= deviceChange; }; mainwindow.TADB.OndeivceConnect += deviceChange; } }
public void InputMain(Mainwindow mainwindow) { this.mainwindow = mainwindow; this.dBTask = mainwindow.TADB; this.socketworker = mainwindow.socketworker; SetCardMirrorHeight(); SetupMirror(); SetUpAdbEvent(); }
public void InputMain(Mainwindow mainwindow) { this.mainwindow = mainwindow; this.bootWindow = mainwindow.bootwindow; list = mainwindow.TADB.GetDevices(); listdevice.ItemsSource = list; listdevice.DisplayMemberPath = "IPAddress"; int indexdevice = list.IndexOf(list.Find(s => { return(s.IPAddress.Contains(mainwindow.TADB.GetDeivce().IPAddress)); })); listdevice.SelectedIndex = indexdevice; bootWindow.ToRightButton.Visibility = Visibility.Visible; bootWindow.ToLeftButton.Visibility = Visibility.Hidden; }
public void InputMain(Mainwindow mainwindow) { this.mainwindow = mainwindow; this.bootwindow = mainwindow.bootwindow; bootwindow.ToRightButton.Visibility = Visibility.Hidden; bootwindow.ToLeftButton.Visibility = Visibility.Hidden; var tadb = mainwindow.TADB; //tạo port reverser cho kết nối tadb.CreateForwardTcp(Neter.DATATRANFER_PORT, Neter.DATATRANFER_PORT); tadb.CreateForwardTcp(Neter.MOUSEUSER_PORT, Neter.MOUSEUSER_PORT); //thực hiện nghe ở cổng Bindingconnect(); mainwindow.socketworker.Ontalkstart += Socketworker_Ontalkstart; mainwindow.socketworker.Ontalkstop += Socketworker_Ontalkstop; mainwindow.socketworker.OnTakeData += Socketworker_OnTakeData; }
public void InputMain(Mainwindow mainwindow) { DowaitJob(); }