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

Side by Side Diff: chrome/browser/prefs/pref_service_syncable_builder.cc

Issue 15984016: Call scoped_refptr<T>::get() rather than relying on implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/prefs/pref_service_syncable_builder.h" 5 #include "chrome/browser/prefs/pref_service_syncable_builder.h"
6 6
7 #include "base/debug/trace_event.h" 7 #include "base/debug/trace_event.h"
8 #include "base/prefs/default_pref_store.h" 8 #include "base/prefs/default_pref_store.h"
9 #include "base/prefs/pref_notifier_impl.h" 9 #include "base/prefs/pref_notifier_impl.h"
10 #include "base/prefs/pref_value_store.h" 10 #include "base/prefs/pref_value_store.h"
(...skipping 30 matching lines...) Expand all
41 WithCommandLinePrefs(new CommandLinePrefStore(command_line)); 41 WithCommandLinePrefs(new CommandLinePrefStore(command_line));
42 return *this; 42 return *this;
43 } 43 }
44 44
45 PrefServiceSyncable* PrefServiceSyncableBuilder::CreateSyncable( 45 PrefServiceSyncable* PrefServiceSyncableBuilder::CreateSyncable(
46 user_prefs::PrefRegistrySyncable* pref_registry) { 46 user_prefs::PrefRegistrySyncable* pref_registry) {
47 TRACE_EVENT0("browser", "PrefServiceSyncableBuilder::CreateSyncable"); 47 TRACE_EVENT0("browser", "PrefServiceSyncableBuilder::CreateSyncable");
48 PrefNotifierImpl* pref_notifier = new PrefNotifierImpl(); 48 PrefNotifierImpl* pref_notifier = new PrefNotifierImpl();
49 PrefServiceSyncable* pref_service = new PrefServiceSyncable( 49 PrefServiceSyncable* pref_service = new PrefServiceSyncable(
50 pref_notifier, 50 pref_notifier,
51 new PrefValueStore( 51 new PrefValueStore(managed_prefs_.get(),
52 managed_prefs_.get(), 52 extension_prefs_.get(),
53 extension_prefs_.get(), 53 command_line_prefs_.get(),
54 command_line_prefs_.get(), 54 user_prefs_.get(),
55 user_prefs_.get(), 55 recommended_prefs_.get(),
56 recommended_prefs_.get(), 56 pref_registry->defaults().get(),
57 pref_registry->defaults(), 57 pref_notifier),
58 pref_notifier),
59 user_prefs_.get(), 58 user_prefs_.get(),
60 pref_registry, 59 pref_registry,
61 read_error_callback_, 60 read_error_callback_,
62 async_); 61 async_);
63 ResetDefaultState(); 62 ResetDefaultState();
64 return pref_service; 63 return pref_service;
65 } 64 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698