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

Side by Side Diff: chrome/browser/search_engines/default_search_manager.h

Issue 229763005: Store default search provider data in dictionary pref. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Make DSE Manager use TemplateURLData Created 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_SEARCH_ENGINES_DEFAULT_SEARCH_MANAGER_H_
6 #define CHROME_BROWSER_SEARCH_ENGINES_DEFAULT_SEARCH_MANAGER_H_
7
8 #include "base/basictypes.h"
9
10 class PrefService;
11 class Profile;
12 struct TemplateURLData;
13
14 class DefaultSearchManager {
15 public:
16 DefaultSearchManager();
erikwright (departed) 2014/04/23 14:18:01 I think this constructor should take a PrefService
Cait (Slow) 2014/04/23 19:10:05 Done.
17
18 // Sets |default_search_provider_| and updates Prefs.
19 void SetUserSelectedDefaultSearchProvider(PrefService* prefs,
20 TemplateURLData* url);
erikwright (departed) 2014/04/23 14:18:01 const ref TUData?
Cait (Slow) 2014/04/23 19:10:05 Done.
21
22 // Returns the default search provider.
23 TemplateURLData* GetDefaultSearchProvider();
erikwright (departed) 2014/04/23 14:18:01 return const-ref?
Cait (Slow) 2014/04/23 19:10:05 Done.
24
25 // Sets |default_search_provider_|.
26 void SetDefaultSearchProvider(TemplateURLData* url);
erikwright (departed) 2014/04/23 14:18:01 const-ref?
Cait (Slow) 2014/04/23 19:10:05 Done.
27
28 // Read default search provider data from the pref service provided.
29 bool ReadFromPrefService(PrefService* prefs, TemplateURLData* url);
erikwright (departed) 2014/04/23 14:18:01 With the existing implementation there is a concep
erikwright (departed) 2014/04/23 14:18:01 I don't think there's a good reason to have separa
Cait (Slow) 2014/04/23 17:26:30 Hmm.. I'm not sure what the best way to handle the
30
31 // Write default search provider data to the pref service provided.
32 void SaveToPrefService(PrefService* prefs, const TemplateURLData* data);
erikwright (departed) 2014/04/23 14:18:01 const-ref?
Cait (Slow) 2014/04/23 19:10:05 Done.
33
34 private:
35 TemplateURLData* default_search_provider_;
erikwright (departed) 2014/04/23 14:18:01 scoped_ptr?
Cait (Slow) 2014/04/23 19:10:05 Removing this altogether until there is an explici
36
37 DISALLOW_COPY_AND_ASSIGN(DefaultSearchManager);
38 };
39
40 #endif // CHROME_BROWSER_SEARCH_ENGINES_DEFAULT_SEARCH_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698