| Index: base/prefs/pref_member.h
|
| diff --git a/base/prefs/pref_member.h b/base/prefs/pref_member.h
|
| index fc277930a5f9be686fe62a5a4f6c7a0fba8d7c6c..78dd3af1b68c92fdf123eacda3710a678c048a7a 100644
|
| --- a/base/prefs/pref_member.h
|
| +++ b/base/prefs/pref_member.h
|
| @@ -65,7 +65,7 @@ class BASE_PREFS_EXPORT PrefMemberBase : public PrefObserver {
|
| bool is_user_modifiable,
|
| const base::Closure& callback) const;
|
|
|
| - void MoveToThread(
|
| + void UseAlternateTaskRunner(
|
| const scoped_refptr<base::SingleThreadTaskRunner>& task_runner);
|
|
|
| // See PrefMember<> for description.
|
| @@ -92,7 +92,7 @@ class BASE_PREFS_EXPORT PrefMemberBase : public PrefObserver {
|
|
|
| bool IsOnCorrectThread() const;
|
|
|
| - scoped_refptr<base::SingleThreadTaskRunner> thread_loop_;
|
| + scoped_refptr<base::SingleThreadTaskRunner> task_runner_;
|
| mutable bool is_managed_;
|
| mutable bool is_user_modifiable_;
|
|
|
| @@ -112,7 +112,7 @@ class BASE_PREFS_EXPORT PrefMemberBase : public PrefObserver {
|
| // See PrefMember<> for description.
|
| void Destroy();
|
|
|
| - void MoveToThread(
|
| + void UseAlternateTaskRunner(
|
| const scoped_refptr<base::SingleThreadTaskRunner>& task_runner);
|
|
|
| // PrefObserver
|
| @@ -185,9 +185,9 @@ class PrefMember : public subtle::PrefMemberBase {
|
|
|
| // Unsubscribes the PrefMember from the PrefService. After calling this
|
| // function, the PrefMember may not be used any more on the UI thread.
|
| - // Assuming |MoveToThread| was previously called, |GetValue|, |IsManaged|,
|
| - // and |IsUserModifiable| can still be called from the other thread but
|
| - // the results will no longer update from the PrefService.
|
| + // Assuming |UseAlternateTaskRunner| was previously called, |GetValue|,
|
| + // |IsManaged|, and |IsUserModifiable| can still be called from the other
|
| + // thread but the results will no longer update from the PrefService.
|
| // This method should only be called on the UI thread.
|
| void Destroy() {
|
| subtle::PrefMemberBase::Destroy();
|
| @@ -198,16 +198,16 @@ class PrefMember : public subtle::PrefMemberBase {
|
| // via PostTask.
|
| // This method should only be used from the thread the PrefMember is currently
|
| // on, which is the UI thread by default.
|
| - void MoveToThread(
|
| + void UseAlternateTaskRunner(
|
| const scoped_refptr<base::SingleThreadTaskRunner>& task_runner) {
|
| - subtle::PrefMemberBase::MoveToThread(task_runner);
|
| + subtle::PrefMemberBase::UseAlternateTaskRunner(task_runner);
|
| }
|
|
|
| // Check whether the pref is managed, i.e. controlled externally through
|
| // enterprise configuration management (e.g. windows group policy). Returns
|
| // false for unknown prefs.
|
| // This method should only be used from the thread the PrefMember is currently
|
| - // on, which is the UI thread unless changed by |MoveToThread|.
|
| + // on, which is the UI thread unless changed by |UseAlternateTaskRunner|.
|
| bool IsManaged() const {
|
| VerifyPref();
|
| return internal_->IsManaged();
|
| @@ -217,7 +217,7 @@ class PrefMember : public subtle::PrefMemberBase {
|
| // when the pref is managed by a policy or an extension, and when a command
|
| // line flag overrides the pref.
|
| // This method should only be used from the thread the PrefMember is currently
|
| - // on, which is the UI thread unless changed by |MoveToThread|.
|
| + // on, which is the UI thread unless changed by |UseAlternateTaskRunner|.
|
| bool IsUserModifiable() const {
|
| VerifyPref();
|
| return internal_->IsUserModifiable();
|
| @@ -225,7 +225,7 @@ class PrefMember : public subtle::PrefMemberBase {
|
|
|
| // Retrieve the value of the member variable.
|
| // This method should only be used from the thread the PrefMember is currently
|
| - // on, which is the UI thread unless changed by |MoveToThread|.
|
| + // on, which is the UI thread unless changed by |UseAlternateTaskRunner|.
|
| ValueType GetValue() const {
|
| VerifyPref();
|
| return internal_->value();
|
|
|