summaryrefslogtreecommitdiffstats
path: root/chrome/browser/extensions/extension_input_method_api.cc
diff options
context:
space:
mode:
authoraa@chromium.org <aa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-21 22:53:17 +0000
committeraa@chromium.org <aa@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-11-21 22:53:17 +0000
commit026abdef028e0871a092da790a984fdd8df37e55 (patch)
treec253ac0fb8c15f045768985b29e102687b939ae3 /chrome/browser/extensions/extension_input_method_api.cc
parentae4987d641566c6036fc10e9a284df687d8db4ab (diff)
downloadchromium_src-026abdef028e0871a092da790a984fdd8df37e55.zip
chromium_src-026abdef028e0871a092da790a984fdd8df37e55.tar.gz
chromium_src-026abdef028e0871a092da790a984fdd8df37e55.tar.bz2
Move a bunch of ChromeOS APIs out of chrome/browser/extensions.
BUG=101244 Review URL: http://codereview.chromium.org/8609008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@111022 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/extension_input_method_api.cc')
-rw-r--r--chrome/browser/extensions/extension_input_method_api.cc43
1 files changed, 0 insertions, 43 deletions
diff --git a/chrome/browser/extensions/extension_input_method_api.cc b/chrome/browser/extensions/extension_input_method_api.cc
deleted file mode 100644
index cf2bbd2..0000000
--- a/chrome/browser/extensions/extension_input_method_api.cc
+++ /dev/null
@@ -1,43 +0,0 @@
-// Copyright (c) 2011 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 "chrome/browser/extensions/extension_input_method_api.h"
-
-#include "base/values.h"
-#include "chrome/browser/chromeos/input_method/input_method_manager.h"
-#include "chrome/browser/chromeos/extensions/input_method_event_router.h"
-#include "chrome/browser/extensions/extension_service.h"
-#include "chrome/browser/profiles/profile.h"
-
-namespace {
-
-const char kErrorInputMethodPrivateApi[] = "Input method API is private";
-
-} // namespace
-
-GetInputMethodFunction::GetInputMethodFunction() {
-}
-
-GetInputMethodFunction::~GetInputMethodFunction() {
-}
-
-bool GetInputMethodFunction::RunImpl() {
-#if !defined(OS_CHROMEOS)
- error_ = kErrorInputMethodPrivateApi;
- return false;
-#else
- chromeos::ExtensionInputMethodEventRouter* router =
- profile_->GetExtensionService()->input_method_event_router();
- if (!router->IsExtensionWhitelisted(extension_id())) {
- error_ = kErrorInputMethodPrivateApi;
- return false;
- }
- chromeos::input_method::InputMethodManager* manager =
- chromeos::input_method::InputMethodManager::GetInstance();
- const std::string input_method =
- router->GetInputMethodForXkb(manager->current_input_method().id());
- result_.reset(Value::CreateStringValue(input_method));
- return true;
-#endif
-}