public CreateUsers(BCSandGSSVM vm) { this.vm = vm; InitializeComponent(); users = vm.GetUsers(); users = users.Where(u => u.Level == 2).ToList(); }
public Login(BCSandGSSVM vm) { this.vm = vm; users = vm.GetUsers(); InitializeComponent(); Loaded += Login_Loaded; }
private void MainWindow_Loaded(object sender, RoutedEventArgs e) { vm = new BCSandGSSVM(true); this.Title = "On the Spot BCS"; label1.Visibility = Visibility.Visible; led1.Visibility = Visibility.Visible; vm.bControllerOn = false; logger.Info("BCS start"); PhigTimer = new DispatcherTimer(); PhigTimer.Interval = TimeSpan.FromSeconds(5); PhigTimer.Tick += new EventHandler(timer_Tick); PhigTimer.Start(); batchTimer.Interval = TimeSpan.FromSeconds(30); batchTimer.Tick += BatchTimer_Tick; ifKit = new InterfaceKit(); //Hook the basica event handlers ifKit.Attach += new AttachEventHandler(PhidgitController_Attach); oldcursor = this.Cursor; this.Cursor = Cursors.Wait; //Open the object for device connections ifKit.open(); DataContext = vm; }
public RegisterItem() { InitializeComponent(); vm = ((App)Application.Current).vm as BCSandGSSVM; DataContext = ((App)Application.Current).vm; timer2 = new DispatcherTimer(); timer2.Interval = TimeSpan.FromSeconds(1); timer2.Tick += new EventHandler(timer2_Tick); vm.bReceivedAlready = false; Loaded += new RoutedEventHandler(RegisterItem_Loaded); }
public GetNote(BCSandGSSVM vm) { InitializeComponent(); this.vm = vm; }