summaryrefslogtreecommitdiffstats
path: root/chrome/browser/chromeos/input_method/input_method_engine.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/chromeos/input_method/input_method_engine.cc')
-rw-r--r--chrome/browser/chromeos/input_method/input_method_engine.cc19
1 files changed, 10 insertions, 9 deletions
diff --git a/chrome/browser/chromeos/input_method/input_method_engine.cc b/chrome/browser/chromeos/input_method/input_method_engine.cc
index ff298c6..b32a8a8 100644
--- a/chrome/browser/chromeos/input_method/input_method_engine.cc
+++ b/chrome/browser/chromeos/input_method/input_method_engine.cc
@@ -14,6 +14,8 @@
#undef RootWindow
#include <map>
+#include "ash/ime/input_method_menu_item.h"
+#include "ash/ime/input_method_menu_manager.h"
#include "ash/shell.h"
#include "base/logging.h"
#include "base/memory/scoped_ptr.h"
@@ -375,19 +377,17 @@ bool InputMethodEngine::UpdateMenuItems(
if (!active_)
return false;
- input_method::InputMethodPropertyList property_list;
+ ash::ime::InputMethodMenuItemList menu_item_list;
for (std::vector<MenuItem>::const_iterator item = items.begin();
item != items.end(); ++item) {
- input_method::InputMethodProperty property;
+ ash::ime::InputMethodMenuItem property;
MenuItemToProperty(*item, &property);
- property_list.push_back(property);
+ menu_item_list.push_back(property);
}
- input_method::InputMethodManager* manager =
- input_method::InputMethodManager::Get();
- if (manager)
- manager->SetCurrentInputMethodProperties(property_list);
-
+ ash::ime::InputMethodMenuManager::GetInstance()->
+ SetCurrentInputMethodMenuItemList(
+ menu_item_list);
return true;
}
@@ -595,9 +595,10 @@ void InputMethodEngine::SetSurroundingText(const std::string& text,
static_cast<int>(anchor_pos));
}
+// TODO(uekawa): rename this method to a more reasonable name.
void InputMethodEngine::MenuItemToProperty(
const MenuItem& item,
- input_method::InputMethodProperty* property) {
+ ash::ime::InputMethodMenuItem* property) {
property->key = item.id;
if (item.modified & MENU_ITEM_MODIFIED_LABEL) {