public static void StartTimer() { if (_dispatcherTimer != null) { return; } _dispatcherTimer = new DispatcherTimer(TimeSpan.FromSeconds(1), DispatcherPriority.Normal, (sender, e) => { VirtualRoot.Elapsed(); }, Dispatcher.CurrentDispatcher); }
public static void StartTimer() { if (_dispatcherTimer != null) { return; } _dispatcherTimer = new DispatcherTimer(TimeSpan.FromSeconds(1), DispatcherPriority.Normal, (sender, e) => { VirtualRoot.Elapsed(); }, Dispatcher.CurrentDispatcher); }