Beispiel #1
0
 void ITimer.StartTimer()
 {
     if (!_isRunning)
     {
         _timer = new XamarinDeviceTimerWrapper(Timer_Elapsed, _interval, isRecurring: true);
         _timer.Start();
         _isRunning = true;
     }
 }
Beispiel #2
0
 void Restart()
 {
     if (_isRunning)
     {
         _timer.Stop();
         _isRunning = false;
     }
     _timer = new XamarinDeviceTimerWrapper(Timer_Elapsed, _interval, isRecurring: true);
     _timer.Start();
     _isRunning = true;
 }