Commit b838bf31 authored by Max Kellermann's avatar Max Kellermann

output/pipewire: un-inline StateChanged()

parent 4d1ce702
......@@ -87,13 +87,7 @@ private:
}
void StateChanged(enum pw_stream_state state,
[[maybe_unused]] const char *error) noexcept {
const bool was_disconnected = disconnected;
disconnected = state == PW_STREAM_STATE_ERROR ||
state == PW_STREAM_STATE_UNCONNECTED;
if (!was_disconnected && disconnected)
pw_thread_loop_signal(thread_loop, false);
}
const char *error) noexcept;
static void StateChanged(void *data,
[[maybe_unused]] enum pw_stream_state old,
......@@ -345,6 +339,17 @@ PipeWireOutput::Close() noexcept
}
inline void
PipeWireOutput::StateChanged(enum pw_stream_state state,
[[maybe_unused]] const char *error) noexcept
{
const bool was_disconnected = disconnected;
disconnected = state == PW_STREAM_STATE_ERROR ||
state == PW_STREAM_STATE_UNCONNECTED;
if (!was_disconnected && disconnected)
pw_thread_loop_signal(thread_loop, false);
}
inline void
PipeWireOutput::Process() noexcept
{
auto *b = pw_stream_dequeue_buffer(stream);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment