private void Window_Loaded(object sender, RoutedEventArgs e) { productLines = Properties.Settings.Default.ProductLines.Split(',').ToList(); initPage(); currenttime = new System.Windows.Threading.DispatcherTimer(); currenttime.Tick += new EventHandler(ShowCurrentTime); currenttime.Interval = new TimeSpan(0, 0, 0, 1); currenttime.Start(); timer = new System.Timers.Timer(); ((System.ComponentModel.ISupportInitialize)(this.timer)).BeginInit(); timer.Enabled = false; timer.Interval = BaseConfig.KanbanTimerInterval; timer.Elapsed += new System.Timers.ElapsedEventHandler(timer_Elapsed); ((System.ComponentModel.ISupportInitialize)(this.timer)).EndInit(); timer.Start(); LampUtil.TurnNormal(); if (Properties.Settings.Default.OnTest) { test_btn_Checked(null, null); } else { test_btn_Unchecked(null, null); } }
private void Window_KeyUp(object sender, KeyEventArgs e) { // test push devise if (e.Key.Equals(Key.X)) { LampUtil.TurnNormal(); } KeyLabel.Content = e.Key; }
private void Window_KeyUp(object sender, System.Windows.Input.KeyEventArgs e) { // test push devise if (e.Key.Equals(Key.X)) { //this.Dispatcher.Invoke(DispatcherPriority.Normal, (MethodInvoker)delegate() //{ LampUtil.TurnNormal(); locked = false; //}); AppService app = new AppService(); if (ids.Count > 0) { app.ConfirmPlans(ids); initPage(); } } // KeyLabel.Content = e.Key; }
private void TurnOff_Click(object sender, RoutedEventArgs e) { LampUtil.TurnNormal(); }