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

Unified Diff: base/prefs/scoped_user_pref_update.h

Issue 753603002: Change preference APIs to take std::string instead of const char*. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed all calls to c_str() in prefs. Created 6 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
« no previous file with comments | « base/prefs/pref_value_store_unittest.cc ('k') | base/prefs/scoped_user_pref_update.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/prefs/scoped_user_pref_update.h
diff --git a/base/prefs/scoped_user_pref_update.h b/base/prefs/scoped_user_pref_update.h
index 82d6739dd32c4c6fb5d50d484ec76d566419b6a0..f8bebfe435ca2a4eedc79e1043767895c12052cb 100644
--- a/base/prefs/scoped_user_pref_update.h
+++ b/base/prefs/scoped_user_pref_update.h
@@ -33,7 +33,7 @@ namespace subtle {
// PrefService::ReportUserPrefChanged.
class BASE_PREFS_EXPORT ScopedUserPrefUpdateBase : public base::NonThreadSafe {
protected:
- ScopedUserPrefUpdateBase(PrefService* service, const char* path);
+ ScopedUserPrefUpdateBase(PrefService* service, const std::string& path);
// Calls Notify().
~ScopedUserPrefUpdateBase();
@@ -66,7 +66,7 @@ class BASE_PREFS_EXPORT ScopedUserPrefUpdateBase : public base::NonThreadSafe {
template <typename T, base::Value::Type type_enum_value>
class ScopedUserPrefUpdate : public subtle::ScopedUserPrefUpdateBase {
public:
- ScopedUserPrefUpdate(PrefService* service, const char* path)
+ ScopedUserPrefUpdate(PrefService* service, const std::string& path)
: ScopedUserPrefUpdateBase(service, path) {}
// Triggers an update notification if Get() was called.
« no previous file with comments | « base/prefs/pref_value_store_unittest.cc ('k') | base/prefs/scoped_user_pref_update.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698