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

Side by Side Diff: ash/system/chromeos/virtual_keyboard/virtual_keyboard_tray.cc

Issue 219503003: Make keyboard controller a singleton. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "ash/system/chromeos/virtual_keyboard/virtual_keyboard_tray.h" 5 #include "ash/system/chromeos/virtual_keyboard/virtual_keyboard_tray.h"
6 6
7 #include "ash/shell.h" 7 #include "ash/shell.h"
8 #include "ash/system/status_area_widget.h" 8 #include "ash/system/status_area_widget.h"
9 #include "ash/system/tray/system_tray_notifier.h" 9 #include "ash/system/tray/system_tray_notifier.h"
10 #include "ash/system/tray/tray_constants.h" 10 #include "ash/system/tray/tray_constants.h"
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 93
94 void VirtualKeyboardTray::HideBubbleWithView( 94 void VirtualKeyboardTray::HideBubbleWithView(
95 const views::TrayBubbleView* bubble_view) { 95 const views::TrayBubbleView* bubble_view) {
96 } 96 }
97 97
98 bool VirtualKeyboardTray::ClickedOutsideBubble() { 98 bool VirtualKeyboardTray::ClickedOutsideBubble() {
99 return false; 99 return false;
100 } 100 }
101 101
102 bool VirtualKeyboardTray::PerformAction(const ui::Event& event) { 102 bool VirtualKeyboardTray::PerformAction(const ui::Event& event) {
103 Shell::GetInstance()->keyboard_controller()->ShowAndLockKeyboard(); 103 keyboard::KeyboardController::GetInstance()->ShowAndLockKeyboard();
104 return true; 104 return true;
105 } 105 }
106 106
107 void VirtualKeyboardTray::ButtonPressed(views::Button* sender, 107 void VirtualKeyboardTray::ButtonPressed(views::Button* sender,
108 const ui::Event& event) { 108 const ui::Event& event) {
109 DCHECK_EQ(button_, sender); 109 DCHECK_EQ(button_, sender);
110 PerformAction(event); 110 PerformAction(event);
111 } 111 }
112 112
113 void VirtualKeyboardTray::OnAccessibilityModeChanged( 113 void VirtualKeyboardTray::OnAccessibilityModeChanged(
114 AccessibilityNotificationVisibility notify) { 114 AccessibilityNotificationVisibility notify) {
115 SetVisible(Shell::GetInstance()->accessibility_delegate()-> 115 SetVisible(Shell::GetInstance()->accessibility_delegate()->
116 IsVirtualKeyboardEnabled()); 116 IsVirtualKeyboardEnabled());
117 } 117 }
118 118
119 } // namespace internal 119 } // namespace internal
120 } // namespace ash 120 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698