|
|
@@ -129,7 +129,9 @@ void Sleeper::operator()() { |
|
|
|
// a natural spiral. |
|
|
|
/////////////////////////////////////////////////////////////////////////////// |
|
|
|
|
|
|
|
PollTimer::PollTimer(int Nom, int Max) { // Construction requires a |
|
|
|
PollTimer::PollTimer(int Nom, int Max) :
|
|
|
|
NominalPollTime(MinimumSleeperTime),
|
|
|
|
MaximumPollTime(MinimumSleeperTime) { // Construction requires a |
|
|
|
setNominalPollTime(Nom); // nominal delay to use and |
|
|
|
setMaximumPollTime(Max); // a maximum delay to allow. |
|
|
|
} |
|
|
@@ -142,7 +144,7 @@ int PollTimer::setNominalPollTime(int Nom) { |
|
|
|
NominalPollTime = Nom; // remember it. |
|
|
|
|
|
|
|
if(MaximumPollTime < NominalPollTime) // Make sure the Maximum poll |
|
|
|
MaximumPollTime = NominalPollTime; // time is > the Nominal time. |
|
|
|
MaximumPollTime = NominalPollTime; // time is >= the Nominal time. |
|
|
|
|
|
|
|
reset(); // Reset due to the change. |
|
|
|
return NominalPollTime; // Return the new value. |