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

Side by Side Diff: ash/autoclick/autoclick_controller.h

Issue 2016073004: Show a visual indicator for the progress of auto-click. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkgr
Patch Set: Moved ring rendering code to chrome/browser/chromeos/ui 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 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 ASH_AUTOCLICK_AUTOCLICK_CONTROLLER_H 5 #ifndef ASH_AUTOCLICK_AUTOCLICK_CONTROLLER_H
6 #define ASH_AUTOCLICK_AUTOCLICK_CONTROLLER_H 6 #define ASH_AUTOCLICK_AUTOCLICK_CONTROLLER_H
7 7
8 #include <memory>
9
8 #include "ash/ash_export.h" 10 #include "ash/ash_export.h"
11 #include "ash/autoclick/autoclickgesture_delegate.h"
9 12
10 namespace ash { 13 namespace ash {
11 14
12 // Controls the autoclick a11y feature in ash. 15 // Controls the autoclick a11y feature in ash.
13 // If enabled, we will automatically send a click event a short time after 16 // If enabled, we will automatically send a click event a short time after
14 // the mouse had been at rest. 17 // the mouse had been at rest.
15 class ASH_EXPORT AutoclickController { 18 class ASH_EXPORT AutoclickController {
16 public: 19 public:
17 virtual ~AutoclickController() {} 20 virtual ~AutoclickController() {}
18 21
22 // Set the delegate to work with.
23 virtual void SetAutoclickgestureDelegate(
24 std::unique_ptr<AutoclickgestureDelegate> autoclickgesture_delegate) = 0;
25
19 // Set whether autoclicking is enabled. 26 // Set whether autoclicking is enabled.
20 virtual void SetEnabled(bool enabled) = 0; 27 virtual void SetEnabled(bool enabled) = 0;
21 28
22 // Returns true if autoclicking is enabled. 29 // Returns true if autoclicking is enabled.
23 virtual bool IsEnabled() const = 0; 30 virtual bool IsEnabled() const = 0;
24 31
25 // Set the time to wait in milliseconds from when the mouse stops moving 32 // Set the time to wait in milliseconds from when the mouse stops moving
26 // to when the autoclick event is sent. 33 // to when the autoclick event is sent.
27 virtual void SetAutoclickDelay(int delay_ms) = 0; 34 virtual void SetAutoclickDelay(int delay_ms) = 0;
28 35
29 // Returns the autoclick delay in milliseconds. 36 // Returns the autoclick delay in milliseconds.
30 virtual int GetAutoclickDelay() const = 0; 37 virtual int GetAutoclickDelay() const = 0;
31 38
32 static AutoclickController* CreateInstance(); 39 static AutoclickController* CreateInstance();
33 40
34 // The default wait time between last mouse movement and sending 41 // The default wait time between last mouse movement and sending
35 // the autoclick. 42 // the autoclick.
36 static const int kDefaultAutoclickDelayMs; 43 static const int kDefaultAutoclickDelayMs;
37 44
38 protected: 45 protected:
39 AutoclickController() {} 46 AutoclickController() {}
40 }; 47 };
41 48
42 } // namespace ash 49 } // namespace ash
43 50
44 #endif // ASH_AUTOCLICK_AUTOCLICK_CONTROLLER_H 51 #endif // ASH_AUTOCLICK_AUTOCLICK_CONTROLLER_H
OLDNEW
« no previous file with comments | « no previous file | ash/autoclick/autoclick_controller.cc » ('j') | ash/autoclick/autoclick_controller.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698