Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(993)

Unified Diff: chromeos/audio/audio_devices_pref_handler_impl.cc

Issue 1349783006: Cleanup: Pass std::string as const reference if possible (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Revert third_party changes Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chromeos/audio/audio_devices_pref_handler_impl.cc
diff --git a/chromeos/audio/audio_devices_pref_handler_impl.cc b/chromeos/audio/audio_devices_pref_handler_impl.cc
index 4e72de6c1ca6ac4bf2e597d3330e5a502170583e..17b5681ebce457ca4feffe8a9f1479fa95ee4832 100644
--- a/chromeos/audio/audio_devices_pref_handler_impl.cc
+++ b/chromeos/audio/audio_devices_pref_handler_impl.cc
@@ -187,14 +187,14 @@ void AudioDevicesPrefHandlerImpl::SaveDevicesVolumePref() {
}
void AudioDevicesPrefHandlerImpl::MigrateDeviceMuteSettings(
- std::string active_device) {
+ const std::string& active_device) {
int old_mute = local_state_->GetInteger(prefs::kAudioMute);
device_mute_settings_->SetInteger(active_device, old_mute);
SaveDevicesMutePref();
}
void AudioDevicesPrefHandlerImpl::MigrateDeviceVolumeSettings(
- std::string active_device) {
+ const std::string& active_device) {
double old_volume = local_state_->GetDouble(prefs::kAudioVolumePercent);
device_volume_settings_->SetDouble(active_device, old_volume);
SaveDevicesVolumePref();

Powered by Google App Engine
This is Rietveld 408576698