From: csagan5 <32685696+csagan5@users.noreply.github.com>
Date: Mon, 12 Feb 2018 21:28:53 +0100
Subject: ungoogled-chromium: Disable translate integration

---
 components/translate/core/browser/translate_manager.cc | 5 +++--
 components/translate/core/browser/translate_script.cc  | 3 +--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/components/translate/core/browser/translate_manager.cc b/components/translate/core/browser/translate_manager.cc
--- a/components/translate/core/browser/translate_manager.cc
+++ b/components/translate/core/browser/translate_manager.cc
@@ -704,8 +704,9 @@ void TranslateManager::FilterIsTranslatePossible(
         TranslateBrowserMetrics::INITIATION_STATUS_NO_NETWORK);
   }
 
-  if (!ignore_missing_key_for_testing_ &&
-      !::google_apis::HasAPIKeyConfigured()) {
+//  if (!ignore_missing_key_for_testing_ &&
+//      !::google_apis::HasAPIKeyConfigured()) {
+    if (true) {
     // Without an API key, translate won't work, so don't offer to translate in
     // the first place. Leave prefs::kOfferTranslateEnabled on, though, because
     // that settings syncs and we don't want to turn off translate everywhere
diff --git a/components/translate/core/browser/translate_script.cc b/components/translate/core/browser/translate_script.cc
--- a/components/translate/core/browser/translate_script.cc
+++ b/components/translate/core/browser/translate_script.cc
@@ -151,9 +151,8 @@ void TranslateScript::OnScriptFetchComplete(bool success,
     base::StringAppendF(&data_, "var serverParams = '%s';\n",
                         server_params.c_str());
 
-    GURL security_origin = translate::GetTranslateSecurityOrigin();
     base::StringAppendF(
-        &data_, "var securityOrigin = '%s';", security_origin.spec().c_str());
+        &data_, "var securityOrigin = '';");
 
     // Load embedded translate.js.
     base::StringPiece str =
-- 
2.11.0

