diff options
| author | Calvin Morrison <calvin@pobox.com> | 2026-05-17 09:10:55 -0400 |
|---|---|---|
| committer | Calvin Morrison <calvin@pobox.com> | 2026-05-17 09:10:55 -0400 |
| commit | 5ccdfbc97811847611ee366848aa4b4b767bd656 (patch) | |
| tree | d02c6cb94e0e652da3f7adee3d2d60434be037f7 /src | |
| parent | 62ac7a360129aa741d898ea2e70c3ab958877305 (diff) | |
cleanup
Diffstat (limited to 'src')
| -rw-r--r-- | src/model/pulsedevice.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/model/pulsedevice.cpp b/src/model/pulsedevice.cpp index 8fb8d48..d79ee8e 100644 --- a/src/model/pulsedevice.cpp +++ b/src/model/pulsedevice.cpp @@ -241,12 +241,11 @@ void PulseDevice::setMuted( bool m ) if ( !m_context ) return; pa_threaded_mainloop_lock( m_mainloop ); pa_operation *op = 0; - int mute = m ? 1 : 0; switch ( m_category ) { - case Output: op = pa_context_set_sink_mute_by_index( m_context, m_paIndex, mute, 0, 0 ); break; - case Input: op = pa_context_set_source_mute_by_index( m_context, m_paIndex, mute, 0, 0 ); break; - case Playback: op = pa_context_set_sink_input_mute( m_context, m_paIndex, mute, 0, 0 ); break; - case Recording: op = pa_context_set_source_output_mute( m_context, m_paIndex, mute, 0, 0 ); break; + case Output: op = pa_context_set_sink_mute_by_index( m_context, m_paIndex, m, 0, 0 ); break; + case Input: op = pa_context_set_source_mute_by_index( m_context, m_paIndex, m, 0, 0 ); break; + case Playback: op = pa_context_set_sink_input_mute( m_context, m_paIndex, m, 0, 0 ); break; + case Recording: op = pa_context_set_source_output_mute( m_context, m_paIndex, m, 0, 0 ); break; } if ( op ) pa_operation_unref( op ); pa_threaded_mainloop_unlock( m_mainloop ); |
