| 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_TRANSLATE_CHROME_TRANSLATE_CLIENT_H_ | 5 #ifndef CHROME_BROWSER_TRANSLATE_CHROME_TRANSLATE_CLIENT_H_ |
| 6 #define CHROME_BROWSER_TRANSLATE_CHROME_TRANSLATE_CLIENT_H_ | 6 #define CHROME_BROWSER_TRANSLATE_CHROME_TRANSLATE_CLIENT_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 namespace content { | 31 namespace content { |
| 32 class BrowserContext; | 32 class BrowserContext; |
| 33 class WebContents; | 33 class WebContents; |
| 34 } // namespace content | 34 } // namespace content |
| 35 | 35 |
| 36 namespace test { | 36 namespace test { |
| 37 class ScopedCLDDynamicDataHarness; | 37 class ScopedCLDDynamicDataHarness; |
| 38 } // namespace test | 38 } // namespace test |
| 39 | 39 |
| 40 struct LanguageDetectionDetails; | 40 struct LanguageDetectionDetails; |
| 41 class LanguageState; |
| 41 class PrefService; | 42 class PrefService; |
| 42 class TranslateAcceptLanguages; | 43 class TranslateAcceptLanguages; |
| 43 class TranslatePrefs; | 44 class TranslatePrefs; |
| 44 class TranslateManager; | 45 class TranslateManager; |
| 45 | 46 |
| 46 class ChromeTranslateClient | 47 class ChromeTranslateClient |
| 47 : public TranslateClient, | 48 : public TranslateClient, |
| 48 public content::WebContentsObserver, | 49 public content::WebContentsObserver, |
| 49 public content::WebContentsUserData<ChromeTranslateClient> { | 50 public content::WebContentsUserData<ChromeTranslateClient> { |
| 50 public: | 51 public: |
| (...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 174 | 175 |
| 175 // Necessary for binding the callback to HandleCLDDataRequest on the blocking | 176 // Necessary for binding the callback to HandleCLDDataRequest on the blocking |
| 176 // pool and for delaying translation initialization until the page has | 177 // pool and for delaying translation initialization until the page has |
| 177 // finished loading on a reload. | 178 // finished loading on a reload. |
| 178 base::WeakPtrFactory<ChromeTranslateClient> weak_pointer_factory_; | 179 base::WeakPtrFactory<ChromeTranslateClient> weak_pointer_factory_; |
| 179 | 180 |
| 180 DISALLOW_COPY_AND_ASSIGN(ChromeTranslateClient); | 181 DISALLOW_COPY_AND_ASSIGN(ChromeTranslateClient); |
| 181 }; | 182 }; |
| 182 | 183 |
| 183 #endif // CHROME_BROWSER_TRANSLATE_CHROME_TRANSLATE_CLIENT_H_ | 184 #endif // CHROME_BROWSER_TRANSLATE_CHROME_TRANSLATE_CLIENT_H_ |
| OLD | NEW |