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

Side by Side Diff: ash/wm/cursor_manager_chromeos.cc

Issue 2095193002: clang-format all of //ash (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 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/wm/cursor_manager_chromeos.h" 5 #include "ash/wm/cursor_manager_chromeos.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "ui/events/event.h" 10 #include "ui/events/event.h"
11 #include "ui/keyboard/keyboard_util.h" 11 #include "ui/keyboard/keyboard_util.h"
12 #include "ui/wm/core/cursor_manager.h" 12 #include "ui/wm/core/cursor_manager.h"
13 #include "ui/wm/core/native_cursor_manager.h" 13 #include "ui/wm/core/native_cursor_manager.h"
14 14
15 namespace ash { 15 namespace ash {
16 16
17 CursorManager::CursorManager( 17 CursorManager::CursorManager(
18 std::unique_ptr<::wm::NativeCursorManager> delegate) 18 std::unique_ptr<::wm::NativeCursorManager> delegate)
19 : ::wm::CursorManager(std::move(delegate)) {} 19 : ::wm::CursorManager(std::move(delegate)) {}
20 20
21 CursorManager::~CursorManager() { 21 CursorManager::~CursorManager() {}
22 }
23 22
24 bool CursorManager::ShouldHideCursorOnKeyEvent( 23 bool CursorManager::ShouldHideCursorOnKeyEvent(
25 const ui::KeyEvent& event) const { 24 const ui::KeyEvent& event) const {
26 if (event.type() != ui::ET_KEY_PRESSED) 25 if (event.type() != ui::ET_KEY_PRESSED)
27 return false; 26 return false;
28 27
29 // Clicking on a key when the accessibility virtual keyboard is enabled should 28 // Clicking on a key when the accessibility virtual keyboard is enabled should
30 // not hide the cursor. 29 // not hide the cursor.
31 if (keyboard::GetAccessibilityKeyboardEnabled()) 30 if (keyboard::GetAccessibilityKeyboardEnabled())
32 return false; 31 return false;
(...skipping 18 matching lines...) Expand all
51 case ui::VKEY_BRIGHTNESS_DOWN: 50 case ui::VKEY_BRIGHTNESS_DOWN:
52 case ui::VKEY_BRIGHTNESS_UP: 51 case ui::VKEY_BRIGHTNESS_UP:
53 case ui::VKEY_KBD_BRIGHTNESS_UP: 52 case ui::VKEY_KBD_BRIGHTNESS_UP:
54 case ui::VKEY_KBD_BRIGHTNESS_DOWN: 53 case ui::VKEY_KBD_BRIGHTNESS_DOWN:
55 return false; 54 return false;
56 default: 55 default:
57 return true; 56 return true;
58 } 57 }
59 } 58 }
60 } // namespace ash 59 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/boot_splash_screen_chromeos.cc ('k') | ash/wm/dock/docked_window_layout_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698