Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(333)

Issue 2655223002: Revert of Don't offer to translate between Simplified and Traditional Chinese (Closed)

Created:
3 years, 11 months ago by kjellander_chromium
Modified:
3 years, 11 months ago
Reviewers:
groby-ooo-7-16, riesa
CC:
chromium-reviews, Anton Bakalov
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Revert of Don't offer to translate between Simplified and Traditional Chinese (patchset #5 id:80001 of https://codereview.chromium.org/2650003004/ ) Reason for revert: Introduces static initializers; failing the sizes step in https://build.chromium.org/p/chromium/builders/Linux%20x64/builds/31922 Original issue's description: > Don't offer to translate between Simplified and Traditional Chinese. > > BUG=683164 > > Review-Url: https://codereview.chromium.org/2650003004 > Cr-Commit-Position: refs/heads/master@{#446213} > Committed: https://chromium.googlesource.com/chromium/src/+/889fb1a6efab0b3e425b81575bbd7a62ed0c4eb1 TBR=groby@chromium.org,riesa@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=683164

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+2 lines, -63 lines) Patch
M components/translate/core/browser/translate_manager.cc View 2 chunks +2 lines, -5 lines 0 comments Download
M components/translate/core/browser/translate_manager_unittest.cc View 1 chunk +0 lines, -58 lines 0 comments Download

Messages

Total messages: 7 (3 generated)
kjellander_chromium
Created Revert of Don't offer to translate between Simplified and Traditional Chinese
3 years, 11 months ago (2017-01-26 05:30:50 UTC) #2
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2655223002/1
3 years, 11 months ago (2017-01-26 05:31:07 UTC) #3
commit-bot: I haz the power
Failed to apply patch for components/translate/core/browser/translate_manager.cc: While running git apply --index -p1; error: patch failed: ...
3 years, 11 months ago (2017-01-26 05:31:43 UTC) #5
kjellander_chromium
3 years, 11 months ago (2017-01-26 05:35:42 UTC) #6
On 2017/01/26 05:31:43, commit-bot: I haz the power wrote:
> Failed to apply patch for
> components/translate/core/browser/translate_manager.cc:
> While running git apply --index -p1;
>   error: patch failed:
components/translate/core/browser/translate_manager.cc:4
>   error: components/translate/core/browser/translate_manager.cc: patch does
not
> apply
> 
> Patch:       components/translate/core/browser/translate_manager.cc
> Index: components/translate/core/browser/translate_manager.cc
> diff --git a/components/translate/core/browser/translate_manager.cc
> b/components/translate/core/browser/translate_manager.cc
> index
>
1c9183a27fb6df6deb62b1b12702caf4fe32e061..33d3c514a5d011646e21b4c5aedfbff7679a21f6
> 100644
> --- a/components/translate/core/browser/translate_manager.cc
> +++ b/components/translate/core/browser/translate_manager.cc
> @@ -4,7 +4,6 @@
>  
>  #include "components/translate/core/browser/translate_manager.h"
>  
> -#include <iostream>
>  #include <map>
>  
>  #include "base/bind.h"
> @@ -225,14 +224,12 @@
>    InitTranslateEvent(language_code, target_lang, *translate_prefs);
>  
>    // Don't translate similar languages (ex: en-US to en).
> -  // Also do not offer to translate between Simplified and Traditional
Chinese.
> -  if (language_code == target_lang ||
> -      (language_code == "zh-CN" && target_lang == "zh-TW") ||
> -      (language_code == "zh-TW" && target_lang == "zh-CN")) {
> +  if (language_code == target_lang) {
>      TranslateBrowserMetrics::ReportInitiationStatus(
>          TranslateBrowserMetrics::INITIATION_STATUS_SIMILAR_LANGUAGES);
>      return;
>    }
> +
>    // Nothing to do if either the language Chrome is in or the language of the
>    // page is not supported by the translation server.
>    if (target_lang.empty() ||

dbeam@ beat me to it with
https://chromium.googlesource.com/chromium/src/+/fc1f65c1189b644cd27c8a5fa478...
Closing this CL.

Powered by Google App Engine
This is Rietveld 408576698