summaryrefslogtreecommitdiff
path: root/indra/newview/llpanelvoicedevicesettings.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llpanelvoicedevicesettings.cpp')
-rw-r--r--indra/newview/llpanelvoicedevicesettings.cpp55
1 files changed, 15 insertions, 40 deletions
diff --git a/indra/newview/llpanelvoicedevicesettings.cpp b/indra/newview/llpanelvoicedevicesettings.cpp
index aef870d352..dc87bd0077 100644
--- a/indra/newview/llpanelvoicedevicesettings.cpp
+++ b/indra/newview/llpanelvoicedevicesettings.cpp
@@ -51,6 +51,7 @@ LLPanelVoiceDeviceSettings::LLPanelVoiceDeviceSettings()
mInputDevice = gSavedSettings.getString("VoiceInputAudioDevice");
mOutputDevice = gSavedSettings.getString("VoiceOutputAudioDevice");
mDevicesUpdated = FALSE;
+ mUseTuningMode = true;
// grab "live" mic volume level
mMicVolume = gSavedSettings.getF32("AudioLevelMic");
@@ -96,7 +97,7 @@ void LLPanelVoiceDeviceSettings::draw()
// let user know that volume indicator is not yet available
bool is_in_tuning_mode = LLVoiceClient::getInstance()->inTuningMode();
- getChildView("wait_text")->setVisible( !is_in_tuning_mode);
+ getChildView("wait_text")->setVisible( !is_in_tuning_mode && mUseTuningMode);
LLPanel::draw();
@@ -220,23 +221,7 @@ void LLPanelVoiceDeviceSettings::refresh()
iter != LLVoiceClient::getInstance()->getCaptureDevices().end();
iter++)
{
- // Lets try to localize some system device names. EXT-8375
- std::string device_name = *iter;
- LLStringUtil::toLower(device_name); //compare in low case
- if ("default system device" == device_name)
- {
- device_name = getString(device_name);
- }
- else if ("no device" == device_name)
- {
- device_name = getString(device_name);
- }
- else
- {
- // restore original value
- device_name = *iter;
- }
- mCtrlInputDevices->add(device_name, ADD_BOTTOM );
+ mCtrlInputDevices->add( *iter, ADD_BOTTOM );
}
if(!mCtrlInputDevices->setSimple(mInputDevice))
@@ -253,23 +238,7 @@ void LLPanelVoiceDeviceSettings::refresh()
for(iter= LLVoiceClient::getInstance()->getRenderDevices().begin();
iter != LLVoiceClient::getInstance()->getRenderDevices().end(); iter++)
{
- // Lets try to localize some system device names. EXT-8375
- std::string device_name = *iter;
- LLStringUtil::toLower(device_name); //compare in low case
- if ("default system device" == device_name)
- {
- device_name = getString(device_name);
- }
- else if ("no device" == device_name)
- {
- device_name = getString(device_name);
- }
- else
- {
- // restore original value
- device_name = *iter;
- }
- mCtrlOutputDevices->add(device_name, ADD_BOTTOM );
+ mCtrlOutputDevices->add( *iter, ADD_BOTTOM );
}
if(!mCtrlOutputDevices->setSimple(mOutputDevice))
@@ -292,14 +261,20 @@ void LLPanelVoiceDeviceSettings::initialize()
LLVoiceClient::getInstance()->refreshDeviceLists();
// put voice client in "tuning" mode
- LLVoiceClient::getInstance()->tuningStart();
- LLVoiceChannel::suspend();
+ if (mUseTuningMode)
+ {
+ LLVoiceClient::getInstance()->tuningStart();
+ LLVoiceChannel::suspend();
+ }
}
void LLPanelVoiceDeviceSettings::cleanup()
{
- LLVoiceClient::getInstance()->tuningStop();
- LLVoiceChannel::resume();
+ if (mUseTuningMode)
+ {
+ LLVoiceClient::getInstance()->tuningStop();
+ LLVoiceChannel::resume();
+ }
}
void LLPanelVoiceDeviceSettings::onCommitInputDevice()
@@ -316,6 +291,6 @@ void LLPanelVoiceDeviceSettings::onCommitOutputDevice()
if(LLVoiceClient::getInstance())
{
LLVoiceClient::getInstance()->setRenderDevice(
- getChild<LLComboBox>("voice_input_device")->getValue().asString());
+ getChild<LLComboBox>("voice_output_device")->getValue().asString());
}
}