output/Control: rename "cond" to "wake_cond"
Prepare for adding another Cond attribute.
This commit is contained in:
parent
efb8a9bd2c
commit
1bca29f9e2
@ -128,7 +128,7 @@ AudioOutputControl::CommandAsync(Command cmd) noexcept
|
||||
assert(IsCommandFinished());
|
||||
|
||||
command = cmd;
|
||||
cond.signal();
|
||||
wake_cond.signal();
|
||||
}
|
||||
|
||||
void
|
||||
@ -298,7 +298,7 @@ AudioOutputControl::LockPlay() noexcept
|
||||
|
||||
if (IsOpen() && !in_playback_loop && !woken_for_play) {
|
||||
woken_for_play = true;
|
||||
cond.signal();
|
||||
wake_cond.signal();
|
||||
}
|
||||
}
|
||||
|
||||
@ -346,7 +346,7 @@ AudioOutputControl::LockAllowPlay() noexcept
|
||||
|
||||
allow_play = true;
|
||||
if (IsOpen())
|
||||
cond.signal();
|
||||
wake_cond.signal();
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -91,7 +91,7 @@ class AudioOutputControl {
|
||||
* This condition object wakes up the output thread after
|
||||
* #command has been set.
|
||||
*/
|
||||
Cond cond;
|
||||
Cond wake_cond;
|
||||
|
||||
/**
|
||||
* Additional data for #command. Protected by #mutex.
|
||||
|
@ -218,7 +218,7 @@ AudioOutputControl::WaitForDelay() noexcept
|
||||
if (delay <= std::chrono::steady_clock::duration::zero())
|
||||
return true;
|
||||
|
||||
(void)cond.timed_wait(mutex, delay);
|
||||
(void)wake_cond.timed_wait(mutex, delay);
|
||||
|
||||
if (command != Command::NONE)
|
||||
return false;
|
||||
@ -491,7 +491,7 @@ AudioOutputControl::Task() noexcept
|
||||
|
||||
if (command == Command::NONE) {
|
||||
woken_for_play = false;
|
||||
cond.wait(mutex);
|
||||
wake_cond.wait(mutex);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user