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

Unified Diff: components/translate/content/renderer/static_renderer_cld_data_provider.cc

Issue 461633002: Refactor language detection logic to allow non-static CLD data sources. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Make some of the harness factory methods private Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/translate/content/renderer/static_renderer_cld_data_provider.cc
diff --git a/components/translate/content/renderer/static_renderer_cld_data_provider.cc b/components/translate/content/renderer/static_renderer_cld_data_provider.cc
deleted file mode 100644
index bb2ccf1cc8d8ce4e930e5892dc9101396d095ae1..0000000000000000000000000000000000000000
--- a/components/translate/content/renderer/static_renderer_cld_data_provider.cc
+++ /dev/null
@@ -1,45 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "static_renderer_cld_data_provider.h"
-
-#include "content/public/renderer/render_view_observer.h"
-#include "ipc/ipc_message.h"
-
-namespace translate {
-// Implementation of the static factory method from RendererCldDataProvider,
-// hooking up this specific implementation for all of Chromium.
-RendererCldDataProvider* CreateRendererCldDataProviderFor(
- content::RenderViewObserver* render_view_observer) {
- return new StaticRendererCldDataProvider();
-}
-
-StaticRendererCldDataProvider::StaticRendererCldDataProvider() {
-}
-
-StaticRendererCldDataProvider::~StaticRendererCldDataProvider() {
-}
-
-bool StaticRendererCldDataProvider::OnMessageReceived(
- const IPC::Message& message) {
- // No-op: data is statically linked
- return false;
-}
-
-void StaticRendererCldDataProvider::SendCldDataRequest() {
- // No-op: data is statically linked
-}
-
-bool StaticRendererCldDataProvider::IsCldDataAvailable() {
- // No-op: data is statically linked
- return true;
-}
-
-void StaticRendererCldDataProvider::SetCldAvailableCallback(
- base::Callback<void(void)> callback) {
- // Data is statically linked, so just call immediately.
- callback.Run();
-}
-
-} // namespace translate

Powered by Google App Engine
This is Rietveld 408576698