| OLD | NEW |
| 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 #include "chrome/browser/translate/translate_manager.h" | 5 #include "chrome/browser/translate/translate_manager.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/memory/singleton.h" | 9 #include "base/memory/singleton.h" |
| 10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 #include "content/public/browser/notification_service.h" | 46 #include "content/public/browser/notification_service.h" |
| 47 #include "content/public/browser/notification_source.h" | 47 #include "content/public/browser/notification_source.h" |
| 48 #include "content/public/browser/notification_types.h" | 48 #include "content/public/browser/notification_types.h" |
| 49 #include "content/public/browser/render_process_host.h" | 49 #include "content/public/browser/render_process_host.h" |
| 50 #include "content/public/browser/render_view_host.h" | 50 #include "content/public/browser/render_view_host.h" |
| 51 #include "content/public/browser/web_contents.h" | 51 #include "content/public/browser/web_contents.h" |
| 52 #include "net/base/url_util.h" | 52 #include "net/base/url_util.h" |
| 53 #include "net/http/http_status_code.h" | 53 #include "net/http/http_status_code.h" |
| 54 | 54 |
| 55 #ifdef FILE_MANAGER_EXTENSION | 55 #ifdef FILE_MANAGER_EXTENSION |
| 56 #include "chrome/browser/chromeos/extensions/file_manager/app_id.h" | 56 #include "chrome/browser/chromeos/file_manager/app_id.h" |
| 57 #include "extensions/common/constants.h" | 57 #include "extensions/common/constants.h" |
| 58 #endif | 58 #endif |
| 59 | 59 |
| 60 using content::NavigationController; | 60 using content::NavigationController; |
| 61 using content::NavigationEntry; | 61 using content::NavigationEntry; |
| 62 using content::WebContents; | 62 using content::WebContents; |
| 63 | 63 |
| 64 namespace { | 64 namespace { |
| 65 | 65 |
| 66 const char kReportLanguageDetectionErrorURL[] = | 66 const char kReportLanguageDetectionErrorURL[] = |
| (...skipping 645 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 712 // so we are more aggressive about showing the shortcut to never translate. | 712 // so we are more aggressive about showing the shortcut to never translate. |
| 713 #if defined(OS_ANDROID) | 713 #if defined(OS_ANDROID) |
| 714 config.never_translate_min_count = 1; | 714 config.never_translate_min_count = 1; |
| 715 #else | 715 #else |
| 716 config.never_translate_min_count = 3; | 716 config.never_translate_min_count = 3; |
| 717 #endif // defined(OS_ANDROID) | 717 #endif // defined(OS_ANDROID) |
| 718 | 718 |
| 719 config.always_translate_min_count = 3; | 719 config.always_translate_min_count = 3; |
| 720 return config; | 720 return config; |
| 721 } | 721 } |
| OLD | NEW |