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

Side by Side Diff: ui/keyboard/keyboard_controller.h

Issue 2666843003: Disable pinch-to-zoom gesture on virtual keyboard (Closed)
Patch Set: add a comment Created 3 years, 10 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 unified diff | Download patch
OLDNEW
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 <memory> 8 #include <memory>
9 9
10 #include "base/event_types.h" 10 #include "base/event_types.h"
11 #include "base/macros.h" 11 #include "base/macros.h"
12 #include "base/observer_list.h" 12 #include "base/observer_list.h"
13 #include "ui/aura/window_observer.h" 13 #include "ui/aura/window_observer.h"
14 #include "ui/base/ime/input_method_observer.h" 14 #include "ui/base/ime/input_method_observer.h"
15 #include "ui/base/ime/text_input_type.h" 15 #include "ui/base/ime/text_input_type.h"
16 #include "ui/gfx/geometry/rect.h" 16 #include "ui/gfx/geometry/rect.h"
17 #include "ui/keyboard/keyboard_event_filter.h"
17 #include "ui/keyboard/keyboard_export.h" 18 #include "ui/keyboard/keyboard_export.h"
18 #include "ui/keyboard/keyboard_layout_delegate.h" 19 #include "ui/keyboard/keyboard_layout_delegate.h"
19 20
20 namespace aura { 21 namespace aura {
21 class Window; 22 class Window;
22 } 23 }
23 namespace ui { 24 namespace ui {
24 class InputMethod; 25 class InputMethod;
25 class TextInputClient; 26 class TextInputClient;
26 } 27 }
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 // uses container_'s animator. 171 // uses container_'s animator.
171 std::unique_ptr<CallbackAnimationObserver> animation_observer_; 172 std::unique_ptr<CallbackAnimationObserver> animation_observer_;
172 173
173 ui::InputMethod* input_method_; 174 ui::InputMethod* input_method_;
174 bool keyboard_visible_; 175 bool keyboard_visible_;
175 bool show_on_resize_; 176 bool show_on_resize_;
176 // If true, the keyboard is always visible even if no window has input focus. 177 // If true, the keyboard is always visible even if no window has input focus.
177 bool keyboard_locked_; 178 bool keyboard_locked_;
178 KeyboardMode keyboard_mode_; 179 KeyboardMode keyboard_mode_;
179 ui::TextInputType type_; 180 ui::TextInputType type_;
181 KeyboardEventFilter event_filter_;
bshe 2017/01/31 16:39:25 nit: consider use a unique_ptr
oshima 2017/01/31 21:06:53 this is actually fine if the lifetime is same as o
180 182
181 base::ObserverList<KeyboardControllerObserver> observer_list_; 183 base::ObserverList<KeyboardControllerObserver> observer_list_;
182 184
183 // The currently used keyboard position. 185 // The currently used keyboard position.
184 gfx::Rect current_keyboard_bounds_; 186 gfx::Rect current_keyboard_bounds_;
185 187
186 static KeyboardController* instance_; 188 static KeyboardController* instance_;
187 189
188 base::WeakPtrFactory<KeyboardController> weak_factory_; 190 base::WeakPtrFactory<KeyboardController> weak_factory_;
189 191
190 DISALLOW_COPY_AND_ASSIGN(KeyboardController); 192 DISALLOW_COPY_AND_ASSIGN(KeyboardController);
191 }; 193 };
192 194
193 } // namespace keyboard 195 } // namespace keyboard
194 196
195 #endif // UI_KEYBOARD_KEYBOARD_CONTROLLER_H_ 197 #endif // UI_KEYBOARD_KEYBOARD_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698