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

Unified Diff: chrome/browser/extensions/api/commands/command_service.cc

Issue 1549233002: Convert Pass()→std::move() in //chrome/browser/extensions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years 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: chrome/browser/extensions/api/commands/command_service.cc
diff --git a/chrome/browser/extensions/api/commands/command_service.cc b/chrome/browser/extensions/api/commands/command_service.cc
index 1dd125bdd4d34cffb2a2b1e753922ceed67ad3a3..dc308219302c616a002ebe392534f65fde3e929c 100644
--- a/chrome/browser/extensions/api/commands/command_service.cc
+++ b/chrome/browser/extensions/api/commands/command_service.cc
@@ -4,6 +4,7 @@
#include "chrome/browser/extensions/api/commands/command_service.h"
+#include <utility>
#include <vector>
#include "base/lazy_instance.h"
@@ -288,9 +289,8 @@ bool CommandService::AddKeybindingPref(
scoped_ptr<base::DictionaryValue> suggested_key_prefs(
new base::DictionaryValue);
suggested_key_prefs->Set(command_name, command_keys.release());
- MergeSuggestedKeyPrefs(extension_id,
- ExtensionPrefs::Get(profile_),
- suggested_key_prefs.Pass());
+ MergeSuggestedKeyPrefs(extension_id, ExtensionPrefs::Get(profile_),
+ std::move(suggested_key_prefs));
// Fetch the newly-updated command, and notify the observers.
FOR_EACH_OBSERVER(
@@ -675,9 +675,8 @@ void CommandService::UpdateExtensionSuggestedCommandPrefs(
}
// Merge into current prefs, if present.
- MergeSuggestedKeyPrefs(extension->id(),
- ExtensionPrefs::Get(profile_),
- suggested_key_prefs.Pass());
+ MergeSuggestedKeyPrefs(extension->id(), ExtensionPrefs::Get(profile_),
+ std::move(suggested_key_prefs));
}
void CommandService::RemoveDefunctExtensionSuggestedCommandPrefs(

Powered by Google App Engine
This is Rietveld 408576698