Some users want to set the delay to 0?

This commit is contained in:
Olof Larsson 2013-06-29 20:07:31 +02:00
parent b0f9eee41d
commit 94d2c1d46d

View File

@ -59,6 +59,10 @@ public abstract class ModuloRepeatTask implements Runnable
@Override @Override
public void run() public void run()
{ {
// So the delay millis is lower than one? (could for example be zero)
// This probably means the task should not be executed at all.
if (this.getDelayMillis() < 1) return;
long nowMillis = System.currentTimeMillis(); long nowMillis = System.currentTimeMillis();
long previousMillis = this.getPreviousMillis(); long previousMillis = this.getPreviousMillis();