| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 #ifndef UI_KEYBOARD_KEYBOARD_CONTROLLER_H_ | 5 #ifndef UI_KEYBOARD_KEYBOARD_CONTROLLER_H_ |
| 6 #define UI_KEYBOARD_KEYBOARD_CONTROLLER_H_ | 6 #define UI_KEYBOARD_KEYBOARD_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <set> |
| 9 |
| 8 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 9 #include "base/event_types.h" | 11 #include "base/event_types.h" |
| 10 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
| 11 #include "base/observer_list.h" | 13 #include "base/observer_list.h" |
| 12 #include "ui/aura/window_observer.h" | 14 #include "ui/aura/window_observer.h" |
| 13 #include "ui/base/ime/input_method_observer.h" | 15 #include "ui/base/ime/input_method_observer.h" |
| 14 #include "ui/base/ime/text_input_type.h" | 16 #include "ui/base/ime/text_input_type.h" |
| 15 #include "ui/gfx/rect.h" | 17 #include "ui/gfx/rect.h" |
| 16 #include "ui/keyboard/keyboard_export.h" | 18 #include "ui/keyboard/keyboard_export.h" |
| 17 #include "url/gurl.h" | 19 #include "url/gurl.h" |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 void RemoveBoundsChangedObserver(aura::Window* window); | 148 void RemoveBoundsChangedObserver(aura::Window* window); |
| 147 | 149 |
| 148 scoped_ptr<KeyboardControllerProxy> proxy_; | 150 scoped_ptr<KeyboardControllerProxy> proxy_; |
| 149 scoped_ptr<aura::Window> container_; | 151 scoped_ptr<aura::Window> container_; |
| 150 // CallbackAnimationObserver should destructed before container_ because it | 152 // CallbackAnimationObserver should destructed before container_ because it |
| 151 // uses container_'s animator. | 153 // uses container_'s animator. |
| 152 scoped_ptr<CallbackAnimationObserver> animation_observer_; | 154 scoped_ptr<CallbackAnimationObserver> animation_observer_; |
| 153 | 155 |
| 154 scoped_ptr<WindowBoundsChangeObserver> window_bounds_observer_; | 156 scoped_ptr<WindowBoundsChangeObserver> window_bounds_observer_; |
| 155 | 157 |
| 158 std::set<aura::Window*> observed_windows_; |
| 159 |
| 156 ui::InputMethod* input_method_; | 160 ui::InputMethod* input_method_; |
| 157 bool keyboard_visible_; | 161 bool keyboard_visible_; |
| 158 bool show_on_resize_; | 162 bool show_on_resize_; |
| 159 bool lock_keyboard_; | 163 bool lock_keyboard_; |
| 160 ui::TextInputType type_; | 164 ui::TextInputType type_; |
| 161 | 165 |
| 162 ObserverList<KeyboardControllerObserver> observer_list_; | 166 ObserverList<KeyboardControllerObserver> observer_list_; |
| 163 | 167 |
| 164 base::WeakPtrFactory<KeyboardController> weak_factory_; | 168 base::WeakPtrFactory<KeyboardController> weak_factory_; |
| 165 | 169 |
| 166 // The currently used keyboard position. | 170 // The currently used keyboard position. |
| 167 gfx::Rect current_keyboard_bounds_; | 171 gfx::Rect current_keyboard_bounds_; |
| 168 | 172 |
| 169 static KeyboardController* instance_; | 173 static KeyboardController* instance_; |
| 170 | 174 |
| 171 DISALLOW_COPY_AND_ASSIGN(KeyboardController); | 175 DISALLOW_COPY_AND_ASSIGN(KeyboardController); |
| 172 }; | 176 }; |
| 173 | 177 |
| 174 } // namespace keyboard | 178 } // namespace keyboard |
| 175 | 179 |
| 176 #endif // UI_KEYBOARD_KEYBOARD_CONTROLLER_H_ | 180 #endif // UI_KEYBOARD_KEYBOARD_CONTROLLER_H_ |
| OLD | NEW |