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

Unified Diff: chrome/browser/chromeos/input_method/input_method_manager_impl.cc

Issue 2925683002: Revert of chromeos: Remove some IME methods from ash::SystemTrayDelegate (Closed)
Patch Set: Created 3 years, 6 months 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: chrome/browser/chromeos/input_method/input_method_manager_impl.cc
diff --git a/chrome/browser/chromeos/input_method/input_method_manager_impl.cc b/chrome/browser/chromeos/input_method/input_method_manager_impl.cc
index 769f569f2ac83970e29e52fe8bd4e79d76eb193d..f8e8ed1439d3ea171cb39f24803240f34ee9f12c 100644
--- a/chrome/browser/chromeos/input_method/input_method_manager_impl.cc
+++ b/chrome/browser/chromeos/input_method/input_method_manager_impl.cc
@@ -25,6 +25,7 @@
#include "chrome/browser/chromeos/ash_config.h"
#include "chrome/browser/chromeos/input_method/candidate_window_controller.h"
#include "chrome/browser/chromeos/input_method/component_extension_ime_manager_impl.h"
+#include "chrome/browser/chromeos/input_method/input_method_switch_recorder.h"
#include "chrome/browser/chromeos/language_preferences.h"
#include "chrome/browser/chromeos/login/session/user_session_manager.h"
#include "chrome/browser/chromeos/profiles/profile_helper.h"
@@ -741,6 +742,7 @@
// Find the next input method and switch to it.
SwitchToNextInputMethodInternal(active_input_method_ids,
current_input_method.id());
+ InputMethodSwitchRecorder::Get()->RecordSwitch(false /* by_tray_menu*/);
}
void InputMethodManagerImpl::StateImpl::SwitchToPreviousInputMethod() {
@@ -764,6 +766,7 @@
return;
}
ChangeInputMethod(*iter, true);
+ InputMethodSwitchRecorder::Get()->RecordSwitch(false /* by_tray_menu*/);
}
bool InputMethodManagerImpl::StateImpl::CanSwitchInputMethod(
@@ -781,8 +784,10 @@
std::vector<std::string> candidate_ids;
GetCandidateInputMethodsForAccelerator(accelerator, &candidate_ids);
DCHECK(!candidate_ids.empty());
- if (!candidate_ids.empty())
+ if (!candidate_ids.empty()) {
SwitchToNextInputMethodInternal(candidate_ids, current_input_method.id());
+ InputMethodSwitchRecorder::Get()->RecordSwitch(false /* by_tray_menu*/);
+ }
}
void InputMethodManagerImpl::StateImpl::SwitchToNextInputMethodInternal(
« no previous file with comments | « chrome/browser/chromeos/BUILD.gn ('k') | chrome/browser/chromeos/input_method/input_method_switch_recorder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698