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

Unified Diff: chrome/browser/ui/browser_window_state.cc

Issue 1865213004: Convert //chrome/browser/ui from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 8 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
« no previous file with comments | « chrome/browser/ui/browser_window_state.h ('k') | chrome/browser/ui/certificate_dialogs.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/browser_window_state.cc
diff --git a/chrome/browser/ui/browser_window_state.cc b/chrome/browser/ui/browser_window_state.cc
index 49f840820545072b488e3d41fa5a1d16b7b2f267..e40ef26542fcec503dc6bce047ffee699f1ab764 100644
--- a/chrome/browser/ui/browser_window_state.cc
+++ b/chrome/browser/ui/browser_window_state.cc
@@ -8,6 +8,7 @@
#include "base/command_line.h"
#include "base/macros.h"
+#include "base/memory/ptr_util.h"
#include "base/strings/string_number_conversions.h"
#include "chrome/browser/defaults.h"
#include "chrome/browser/profiles/profile.h"
@@ -79,16 +80,16 @@ std::string GetWindowName(const Browser* browser) {
return browser->app_name();
}
-scoped_ptr<DictionaryPrefUpdate> GetWindowPlacementDictionaryReadWrite(
+std::unique_ptr<DictionaryPrefUpdate> GetWindowPlacementDictionaryReadWrite(
const std::string& window_name,
PrefService* prefs) {
DCHECK(!window_name.empty());
// A normal DictionaryPrefUpdate will suffice for non-app windows.
if (prefs->FindPreference(window_name.c_str())) {
- return make_scoped_ptr(
+ return base::WrapUnique(
new DictionaryPrefUpdate(prefs, window_name.c_str()));
}
- return scoped_ptr<DictionaryPrefUpdate>(
+ return std::unique_ptr<DictionaryPrefUpdate>(
new WindowPlacementPrefUpdate(prefs, window_name));
}
« no previous file with comments | « chrome/browser/ui/browser_window_state.h ('k') | chrome/browser/ui/certificate_dialogs.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698