Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/chromeos/input_method/input_method_manager_impl.h" | 5 #include "chrome/browser/chromeos/input_method/input_method_manager_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> // std::find | 7 #include <algorithm> // std::find |
| 8 | 8 |
| 9 #include "ash/ime/input_method_menu_item.h" | 9 #include "ash/ime/input_method_menu_item.h" |
| 10 #include "ash/ime/input_method_menu_manager.h" | 10 #include "ash/ime/input_method_menu_manager.h" |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 53 | 53 |
| 54 bool InputMethodManagerImpl::MigrateXkbInputMethods( | 54 bool InputMethodManagerImpl::MigrateXkbInputMethods( |
| 55 std::vector<std::string>* input_method_ids) { | 55 std::vector<std::string>* input_method_ids) { |
| 56 return util_.MigrateXkbInputMethods(input_method_ids); | 56 return util_.MigrateXkbInputMethods(input_method_ids); |
| 57 } | 57 } |
| 58 | 58 |
| 59 InputMethodManagerImpl::InputMethodManagerImpl( | 59 InputMethodManagerImpl::InputMethodManagerImpl( |
| 60 scoped_ptr<InputMethodDelegate> delegate) | 60 scoped_ptr<InputMethodDelegate> delegate) |
| 61 : delegate_(delegate.Pass()), | 61 : delegate_(delegate.Pass()), |
| 62 state_(STATE_LOGIN_SCREEN), | 62 state_(STATE_LOGIN_SCREEN), |
| 63 util_(delegate_.get(), GetSupportedInputMethods()), | 63 util_(delegate_.get(), whitelist_.GetSupportedInputMethods()), |
|
Seigo Nonaka
2014/05/29 06:53:39
nit: please write why InputMethodManagerImpl::GetS
Shu Chen
2014/05/29 07:15:27
Because InputMethodManagerImpl::GetSupportedInputM
| |
| 64 component_extension_ime_manager_(new ComponentExtensionIMEManager()), | 64 component_extension_ime_manager_(new ComponentExtensionIMEManager()), |
| 65 weak_ptr_factory_(this) { | 65 weak_ptr_factory_(this) { |
| 66 } | 66 } |
| 67 | 67 |
| 68 InputMethodManagerImpl::~InputMethodManagerImpl() { | 68 InputMethodManagerImpl::~InputMethodManagerImpl() { |
| 69 if (candidate_window_controller_.get()) | 69 if (candidate_window_controller_.get()) |
| 70 candidate_window_controller_->RemoveObserver(this); | 70 candidate_window_controller_->RemoveObserver(this); |
| 71 } | 71 } |
| 72 | 72 |
| 73 void InputMethodManagerImpl::AddObserver( | 73 void InputMethodManagerImpl::AddObserver( |
| (...skipping 780 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 854 CandidateWindowController::CreateCandidateWindowController()); | 854 CandidateWindowController::CreateCandidateWindowController()); |
| 855 candidate_window_controller_->AddObserver(this); | 855 candidate_window_controller_->AddObserver(this); |
| 856 } | 856 } |
| 857 | 857 |
| 858 Profile* InputMethodManagerImpl::GetProfile() const { | 858 Profile* InputMethodManagerImpl::GetProfile() const { |
| 859 return ProfileManager::GetActiveUserProfile(); | 859 return ProfileManager::GetActiveUserProfile(); |
| 860 } | 860 } |
| 861 | 861 |
| 862 } // namespace input_method | 862 } // namespace input_method |
| 863 } // namespace chromeos | 863 } // namespace chromeos |
| OLD | NEW |