private void Runbootwindow()
 {
     //boot window
     bootwindow = new Bootwindow();
     bootwindow.InputMain(this);
     bootwindow.Show();
     //ân của sổ chính
     this.Hide();
 }
Exemplo n.º 2
0
        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;
        }
Exemplo n.º 3
0
        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;
        }