OLD | NEW |
---|---|
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "chrome/browser/ui/ash/palette_delegate_chromeos.h" | 5 #include "chrome/browser/ui/ash/palette_delegate_chromeos.h" |
6 | 6 |
7 #include "ash/shell.h" | |
8 | |
7 namespace chromeos { | 9 namespace chromeos { |
8 | 10 |
9 PaletteDelegateChromeOS::PaletteDelegateChromeOS() {} | 11 PaletteDelegateChromeOS::PaletteDelegateChromeOS() { |
jdufault
2016/08/11 23:41:54
Revert
| |
12 LOG(ERROR) << "dude"; | |
13 } | |
10 | 14 |
11 PaletteDelegateChromeOS::~PaletteDelegateChromeOS() {} | 15 PaletteDelegateChromeOS::~PaletteDelegateChromeOS() {} |
12 | 16 |
17 void PaletteDelegateChromeOS::OnLaserModeEnabled() { | |
18 // We lock the cursor after we hide it because it is always being updated by | |
19 // compound_event_filter.cc to be shown on every mouse movement. | |
20 ash::Shell::GetInstance()->cursor_manager()->HideCursor(); | |
21 ash::Shell::GetInstance()->cursor_manager()->LockCursor(); | |
22 } | |
23 | |
24 void PaletteDelegateChromeOS::OnLaserModeDisabled() { | |
25 ash::Shell::GetInstance()->cursor_manager()->UnlockCursor(); | |
26 ash::Shell::GetInstance()->cursor_manager()->ShowCursor(); | |
27 } | |
13 } // namespace chromeos | 28 } // namespace chromeos |
OLD | NEW |