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

Side by Side Diff: chrome/browser/net/net_pref_observer.h

Issue 10828345: Extract PrefServiceBase into chrome/browser/api. Use in api and autofill. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge to head Created 8 years, 4 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
« no previous file with comments | « chrome/browser/net/chrome_network_delegate.cc ('k') | chrome/browser/plugin_prefs.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #ifndef CHROME_BROWSER_NET_NET_PREF_OBSERVER_H_ 5 #ifndef CHROME_BROWSER_NET_NET_PREF_OBSERVER_H_
6 #define CHROME_BROWSER_NET_NET_PREF_OBSERVER_H_ 6 #define CHROME_BROWSER_NET_NET_PREF_OBSERVER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
11 #include "chrome/browser/api/prefs/pref_member.h" 11 #include "chrome/browser/api/prefs/pref_member.h"
12 #include "content/public/browser/notification_observer.h" 12 #include "content/public/browser/notification_observer.h"
13 13
14 namespace chrome_browser_net { 14 namespace chrome_browser_net {
15 class Predictor; 15 class Predictor;
16 } 16 }
17 17
18 namespace prerender { 18 namespace prerender {
19 class PrerenderManager; 19 class PrerenderManager;
20 } 20 }
21 21
22 class PrefService;
23
22 // Monitors network-related preferences for changes and applies them. 24 // Monitors network-related preferences for changes and applies them.
23 // The supplied PrefService must outlive this NetPrefObserver. 25 // The supplied PrefService must outlive this NetPrefObserver.
24 // Must be used only on the UI thread. 26 // Must be used only on the UI thread.
25 class NetPrefObserver : public content::NotificationObserver { 27 class NetPrefObserver : public content::NotificationObserver {
26 public: 28 public:
27 // |prefs| must be non-NULL and |*prefs| must outlive this. 29 // |prefs| must be non-NULL and |*prefs| must outlive this.
28 // |prerender_manager| may be NULL. If not, |*prerender_manager| must 30 // |prerender_manager| may be NULL. If not, |*prerender_manager| must
29 // outlive this. 31 // outlive this.
30 NetPrefObserver(PrefService* prefs, 32 NetPrefObserver(PrefService* prefs,
31 prerender::PrerenderManager* prerender_manager, 33 prerender::PrerenderManager* prerender_manager,
(...skipping 13 matching lines...) Expand all
45 47
46 BooleanPrefMember network_prediction_enabled_; 48 BooleanPrefMember network_prediction_enabled_;
47 BooleanPrefMember spdy_disabled_; 49 BooleanPrefMember spdy_disabled_;
48 prerender::PrerenderManager* prerender_manager_; 50 prerender::PrerenderManager* prerender_manager_;
49 chrome_browser_net::Predictor* predictor_; 51 chrome_browser_net::Predictor* predictor_;
50 52
51 DISALLOW_COPY_AND_ASSIGN(NetPrefObserver); 53 DISALLOW_COPY_AND_ASSIGN(NetPrefObserver);
52 }; 54 };
53 55
54 #endif // CHROME_BROWSER_NET_NET_PREF_OBSERVER_H_ 56 #endif // CHROME_BROWSER_NET_NET_PREF_OBSERVER_H_
OLDNEW
« no previous file with comments | « chrome/browser/net/chrome_network_delegate.cc ('k') | chrome/browser/plugin_prefs.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698