| Index: chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchRequest.java
|
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchRequest.java b/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchRequest.java
|
| index 4264d9e750dc2afba9ea216dac53af9de6ee5af0..277d1219d00dd5ee553b9748f7ff334c2ed8eb69 100644
|
| --- a/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchRequest.java
|
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchRequest.java
|
| @@ -161,6 +161,15 @@ class ContextualSearchRequest {
|
| }
|
|
|
| /**
|
| + * Adds translation parameters that will trigger auto-detection of the source language.
|
| + * @param targetLanguage The language the that the user prefers.
|
| + */
|
| + void forceAutoDetectTranslation(String targetLanguage) {
|
| + // Use the empty string for the source language in order to trigger auto-detect.
|
| + forceTranslation("", targetLanguage);
|
| + }
|
| +
|
| + /**
|
| * @return Whether translation was forced for this request.
|
| */
|
| @VisibleForTesting
|
|
|