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_configuration.h" | 5 #include "chrome/browser/chromeos/input_method/input_method_configuration.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "chrome/browser/chromeos/input_method/accessibility.h" | 10 #include "chrome/browser/chromeos/input_method/accessibility.h" |
11 #include "chrome/browser/chromeos/input_method/browser_state_monitor.h" | 11 #include "chrome/browser/chromeos/input_method/browser_state_monitor.h" |
12 #include "chrome/browser/chromeos/input_method/input_method_delegate_impl.h" | 12 #include "chrome/browser/chromeos/input_method/input_method_delegate_impl.h" |
13 #include "chrome/browser/chromeos/input_method/input_method_manager_impl.h" | 13 #include "chrome/browser/chromeos/input_method/input_method_manager_impl.h" |
14 #include "chrome/browser/chromeos/input_method/input_method_persistence.h" | 14 #include "chrome/browser/chromeos/input_method/input_method_persistence.h" |
15 #include "ui/base/ime/chromeos/ime_bridge.h" | 15 #include "ui/base/ime/chromeos/ime_bridge.h" |
16 | 16 |
17 namespace chromeos { | 17 namespace chromeos { |
18 namespace input_method { | 18 namespace input_method { |
19 | 19 |
20 namespace { | 20 namespace { |
21 void OnSessionStateChange(InputMethodManagerImpl* input_method_manager_impl, | 21 void OnSessionStateChange(InputMethodManagerImpl* input_method_manager_impl, |
22 InputMethodPersistence* input_method_persistence, | 22 InputMethodPersistence* input_method_persistence, |
23 InputMethodManager::State new_state) { | 23 InputMethodManager::UISessionState new_ui_session) { |
24 input_method_persistence->OnSessionStateChange(new_state); | 24 input_method_persistence->OnSessionStateChange(new_ui_session); |
25 input_method_manager_impl->SetState(new_state); | 25 input_method_manager_impl->SetUISessionState(new_ui_session); |
26 } | 26 } |
27 | 27 |
28 class InputMethodConfiguration { | 28 class InputMethodConfiguration { |
29 public: | 29 public: |
30 InputMethodConfiguration() {} | 30 InputMethodConfiguration() {} |
31 virtual ~InputMethodConfiguration() {} | 31 virtual ~InputMethodConfiguration() {} |
32 | 32 |
33 void Initialize() { | 33 void Initialize() { |
34 IMEBridge::Initialize(); | 34 IMEBridge::Initialize(); |
35 | 35 |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 if (!g_input_method_configuration) | 92 if (!g_input_method_configuration) |
93 return; | 93 return; |
94 | 94 |
95 g_input_method_configuration->Shutdown(); | 95 g_input_method_configuration->Shutdown(); |
96 delete g_input_method_configuration; | 96 delete g_input_method_configuration; |
97 g_input_method_configuration = NULL; | 97 g_input_method_configuration = NULL; |
98 } | 98 } |
99 | 99 |
100 } // namespace input_method | 100 } // namespace input_method |
101 } // namespace chromeos | 101 } // namespace chromeos |
OLD | NEW |