Commit cf143a51 authored by Thomas Guillem's avatar Thomas Guillem

qt: add device preferences for mmdevice

Like for other Windows aouts, this preference can be used to save the preferred
audio device that will be used across several instances of VLC.

CONFIG_AUDIO_DEVICE should also be used for others aouts (in order to forward
the device change to the aout module).
parent bd99dfc4
......@@ -490,6 +490,12 @@ SPrefsPanel::SPrefsPanel( intf_thread_t *_p_intf, QWidget *_parent,
#endif
#ifdef _WIN32
audioControl( MMDevice );
optionWidgets["mmdeviceL" ] = MMDeviceLabel;
optionWidgets["mmdeviceW" ] = MMDeviceDevice;
CONFIG_GENERIC_NO_UI( "mmdevice-audio-device", StringList,
MMDeviceLabel, MMDeviceDevice );
CONFIG_GENERIC( "mmdevice-passthrough", IntegerList,
ui.mmdevicePassthroughLabel, mmdevicePassthroughBox );
optionWidgets["mmdevicePassthroughL"] = ui.mmdevicePassthroughLabel;
......@@ -961,6 +967,8 @@ void SPrefsPanel::updateAudioOptions( int number)
const bool mmDeviceEnabled = value == "mmdevice" || value == "any";
optionWidgets["mmdevicePassthroughL"]->setVisible( mmDeviceEnabled );
optionWidgets["mmdevicePassthroughB"]->setVisible( mmDeviceEnabled );
optionWidgets["mmdeviceW"]->setVisible( mmDeviceEnabled );
optionWidgets["mmdeviceL"]->setVisible( mmDeviceEnabled );
optionWidgets["directxW"]->setVisible( ( value == "directsound" ) );
optionWidgets["directxL"]->setVisible( ( value == "directsound" ) );
......
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