| 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 "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 650 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 661 return false; | 661 return false; |
| 662 } | 662 } |
| 663 return true; | 663 return true; |
| 664 } | 664 } |
| 665 | 665 |
| 666 void InputMethodManagerImpl::MaybeInitializeCandidateWindowController() { | 666 void InputMethodManagerImpl::MaybeInitializeCandidateWindowController() { |
| 667 if (candidate_window_controller_.get()) | 667 if (candidate_window_controller_.get()) |
| 668 return; | 668 return; |
| 669 | 669 |
| 670 candidate_window_controller_.reset( | 670 candidate_window_controller_.reset( |
| 671 CandidateWindowController::CreateCandidateWindowController()); | 671 CandidateWindowController::CreateCandidateWindowController( |
| 672 ibus_controller_.get())); |
| 672 if (candidate_window_controller_->Init()) | 673 if (candidate_window_controller_->Init()) |
| 673 candidate_window_controller_->AddObserver(this); | 674 candidate_window_controller_->AddObserver(this); |
| 674 else | 675 else |
| 675 DVLOG(1) << "Failed to initialize the candidate window controller"; | 676 DVLOG(1) << "Failed to initialize the candidate window controller"; |
| 676 } | 677 } |
| 677 | 678 |
| 678 // static | 679 // static |
| 679 InputMethodManagerImpl* InputMethodManagerImpl::GetInstanceForTesting() { | 680 InputMethodManagerImpl* InputMethodManagerImpl::GetInstanceForTesting() { |
| 680 return new InputMethodManagerImpl; | 681 return new InputMethodManagerImpl; |
| 681 } | 682 } |
| 682 | 683 |
| 683 } // namespace input_method | 684 } // namespace input_method |
| 684 } // namespace chromeos | 685 } // namespace chromeos |
| OLD | NEW |