OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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_GOOGLE_CHROME_GOOGLE_URL_TRACKER_CLIENT_H_ | 5 #ifndef CHROME_BROWSER_GOOGLE_CHROME_GOOGLE_URL_TRACKER_CLIENT_H_ |
6 #define CHROME_BROWSER_GOOGLE_CHROME_GOOGLE_URL_TRACKER_CLIENT_H_ | 6 #define CHROME_BROWSER_GOOGLE_CHROME_GOOGLE_URL_TRACKER_CLIENT_H_ |
7 | 7 |
8 #include "components/google/core/browser/google_url_tracker_client.h" | 8 #include "components/google/core/browser/google_url_tracker_client.h" |
9 #include "content/public/browser/notification_observer.h" | 9 #include "content/public/browser/notification_observer.h" |
10 #include "content/public/browser/notification_registrar.h" | 10 #include "content/public/browser/notification_registrar.h" |
11 | 11 |
12 class Profile; | 12 class Profile; |
13 | 13 |
14 class ChromeGoogleURLTrackerClient : public GoogleURLTrackerClient, | 14 class ChromeGoogleURLTrackerClient : public GoogleURLTrackerClient, |
15 public content::NotificationObserver { | 15 public content::NotificationObserver { |
16 public: | 16 public: |
17 explicit ChromeGoogleURLTrackerClient(Profile* profile); | 17 explicit ChromeGoogleURLTrackerClient(Profile* profile); |
18 virtual ~ChromeGoogleURLTrackerClient(); | 18 virtual ~ChromeGoogleURLTrackerClient(); |
19 | 19 |
20 // GoogleURLTrackerClient: | 20 // GoogleURLTrackerClient: |
21 virtual void SetListeningForNavigationStart(bool listen) OVERRIDE; | 21 virtual void SetListeningForNavigationStart(bool listen) OVERRIDE; |
22 virtual bool IsListeningForNavigationStart() OVERRIDE; | 22 virtual bool IsListeningForNavigationStart() OVERRIDE; |
23 virtual bool IsBackgroundNetworkingEnabled() OVERRIDE; | 23 virtual bool IsBackgroundNetworkingEnabled() OVERRIDE; |
24 virtual PrefService* GetPrefs() OVERRIDE; | 24 virtual PrefService* GetPrefs() OVERRIDE; |
25 virtual net::URLRequestContextGetter* GetRequestContext() OVERRIDE; | 25 virtual net::URLRequestContextGetter* GetRequestContext() OVERRIDE; |
| 26 virtual bool IsGoogleDomainURL(const GURL& url) OVERRIDE; |
| 27 virtual GURL AppendGoogleLocaleParam(const GURL& url) OVERRIDE; |
26 | 28 |
27 private: | 29 private: |
28 // content::NotificationObserver: | 30 // content::NotificationObserver: |
29 virtual void Observe(int type, | 31 virtual void Observe(int type, |
30 const content::NotificationSource& source, | 32 const content::NotificationSource& source, |
31 const content::NotificationDetails& details) OVERRIDE; | 33 const content::NotificationDetails& details) OVERRIDE; |
32 | 34 |
33 Profile* profile_; | 35 Profile* profile_; |
34 | 36 |
35 content::NotificationRegistrar registrar_; | 37 content::NotificationRegistrar registrar_; |
36 | 38 |
37 DISALLOW_COPY_AND_ASSIGN(ChromeGoogleURLTrackerClient); | 39 DISALLOW_COPY_AND_ASSIGN(ChromeGoogleURLTrackerClient); |
38 }; | 40 }; |
39 | 41 |
40 #endif // CHROME_BROWSER_GOOGLE_CHROME_GOOGLE_URL_TRACKER_CLIENT_H_ | 42 #endif // CHROME_BROWSER_GOOGLE_CHROME_GOOGLE_URL_TRACKER_CLIENT_H_ |
OLD | NEW |