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

Side by Side Diff: ui/keyboard/keyboard_ui.cc

Issue 2923493002: Add TRACE_EVENT markers to various keyboard functions (Closed)
Patch Set: Created 3 years, 6 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "ui/keyboard/keyboard_ui.h" 5 #include "ui/keyboard/keyboard_ui.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "ui/aura/window.h" 8 #include "ui/aura/window.h"
9 #include "ui/base/ime/input_method.h" 9 #include "ui/base/ime/input_method.h"
10 #include "ui/base/ime/text_input_client.h" 10 #include "ui/base/ime/text_input_client.h"
11 #include "ui/base/ui_base_switches.h" 11 #include "ui/base/ui_base_switches.h"
12 #include "ui/keyboard/keyboard_controller.h" 12 #include "ui/keyboard/keyboard_controller.h"
13 13
14 namespace keyboard { 14 namespace keyboard {
15 15
16 KeyboardUI::KeyboardUI() : keyboard_controller_(nullptr) {} 16 KeyboardUI::KeyboardUI() : keyboard_controller_(nullptr) {}
17 KeyboardUI::~KeyboardUI() {} 17 KeyboardUI::~KeyboardUI() {}
18 18
19 void KeyboardUI::ShowKeyboardContainer(aura::Window* container) { 19 void KeyboardUI::ShowKeyboardContainer(aura::Window* container) {
20 if (HasKeyboardWindow()) { 20 if (HasKeyboardWindow()) {
21 GetKeyboardWindow()->Show(); 21 {
22 container->Show(); 22 TRACE_EVENT0("vk", "ShowKeyboardContainerWindow");
23 GetKeyboardWindow()->Show();
24 }
25 {
26 TRACE_EVENT0("vk", "ShowKeyboardContainer");
27 container->Show();
28 }
23 } 29 }
24 } 30 }
25 31
26 void KeyboardUI::HideKeyboardContainer(aura::Window* container) { 32 void KeyboardUI::HideKeyboardContainer(aura::Window* container) {
27 if (HasKeyboardWindow()) { 33 if (HasKeyboardWindow()) {
28 container->Hide(); 34 container->Hide();
29 GetKeyboardWindow()->Hide(); 35 GetKeyboardWindow()->Hide();
30 } 36 }
31 } 37 }
32 38
(...skipping 19 matching lines...) Expand all
52 GetInputMethod()->GetTextInputClient()->EnsureCaretNotInRect( 58 GetInputMethod()->GetTextInputClient()->EnsureCaretNotInRect(
53 keyboard_bounds_in_screen); 59 keyboard_bounds_in_screen);
54 } 60 }
55 } 61 }
56 62
57 void KeyboardUI::SetController(KeyboardController* controller) { 63 void KeyboardUI::SetController(KeyboardController* controller) {
58 keyboard_controller_ = controller; 64 keyboard_controller_ = controller;
59 } 65 }
60 66
61 } // namespace keyboard 67 } // namespace keyboard
OLDNEW
« ui/keyboard/keyboard_controller.cc ('K') | « ui/keyboard/keyboard_layout_manager.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698