DelayActionHelper
Ecng.Xaml
Provides a simple timer-based helper to invoke an action after a delay.
Properties
Interval
public double Interval { get; set; }
value = delayActionHelper.Interval
delayActionHelper.Interval = value
Gets or sets the delay interval in milliseconds. Changing the value restarts the timer.
Methods
Restart
public void Restart()
delayActionHelper.Restart()
Restarts the timer, resetting the delay countdown.
Start
public void Start(Action action)
delayActionHelper.Start(action)
Starts the helper and schedules the specified to run after the current Interval.
- action
- The action to execute when the delay elapses.
Stop
public void Stop()
delayActionHelper.Stop()
Stops the timer and prevents the pending action from executing.