| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 COMPONENTS_TRANSLATE_IOS_BROWSER_JS_LANGUAGE_DETECTION_MANAGER_H_ | 5 #ifndef COMPONENTS_TRANSLATE_IOS_BROWSER_JS_LANGUAGE_DETECTION_MANAGER_H_ |
| 6 #define COMPONENTS_TRANSLATE_IOS_BROWSER_JS_LANGUAGE_DETECTION_MANAGER_H_ | 6 #define COMPONENTS_TRANSLATE_IOS_BROWSER_JS_LANGUAGE_DETECTION_MANAGER_H_ |
| 7 | 7 |
| 8 #import <Foundation/Foundation.h> | 8 #import <Foundation/Foundation.h> |
| 9 #include <stddef.h> |
| 9 | 10 |
| 10 #include "base/callback_forward.h" | 11 #include "base/callback_forward.h" |
| 11 #include "base/strings/string16.h" | 12 #include "base/strings/string16.h" |
| 12 #import "ios/web/public/web_state/js/crw_js_injection_manager.h" | 13 #import "ios/web/public/web_state/js/crw_js_injection_manager.h" |
| 13 | 14 |
| 14 namespace language_detection { | 15 namespace language_detection { |
| 15 | 16 |
| 16 // Maximum length of the extracted text returned by |-extractTextContent|. | 17 // Maximum length of the extracted text returned by |-extractTextContent|. |
| 17 // Matches desktop implementation. | 18 // Matches desktop implementation. |
| 18 extern const size_t kMaxIndexChars; | 19 extern const size_t kMaxIndexChars; |
| (...skipping 11 matching lines...) Expand all Loading... |
| 30 // after this call. |callback| must be non null. | 31 // after this call. |callback| must be non null. |
| 31 - (void)retrieveBufferedTextContent: | 32 - (void)retrieveBufferedTextContent: |
| 32 (const language_detection::BufferedTextCallback&)callback; | 33 (const language_detection::BufferedTextCallback&)callback; |
| 33 | 34 |
| 34 // Starts detecting the language of the page. | 35 // Starts detecting the language of the page. |
| 35 - (void)startLanguageDetection; | 36 - (void)startLanguageDetection; |
| 36 | 37 |
| 37 @end | 38 @end |
| 38 | 39 |
| 39 #endif // COMPONENTS_TRANSLATE_IOS_BROWSER_JS_LANGUAGE_DETECTION_MANAGER_H_ | 40 #endif // COMPONENTS_TRANSLATE_IOS_BROWSER_JS_LANGUAGE_DETECTION_MANAGER_H_ |
| OLD | NEW |