Sends NetworkChangeNotifier connection type changes to Blink, to support NetInfo v3.
[chromium-blink-merge.git] / ash / autoclick / autoclick_controller.h
blob46b9ef48089678fab9e38bc0bebfbc1c67411b14
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
3 // found in the LICENSE file.
5 #ifndef ASH_AUTOCLICK_AUTOCLICK_CONTROLLER_H
6 #define ASH_AUTOCLICK_AUTOCLICK_CONTROLLER_H
8 #include "ash/ash_export.h"
10 namespace ash {
12 // Controls the autoclick a11y feature in ash.
13 // If enabled, we will automatically send a click event a short time after
14 // the mouse had been at rest.
15 class ASH_EXPORT AutoclickController {
16 public:
17 virtual ~AutoclickController() {}
19 // Set whether autoclicking is enabled.
20 virtual void SetEnabled(bool enabled) = 0;
22 // Returns true if autoclicking is enabled.
23 virtual bool IsEnabled() const = 0;
25 // Set the time to wait in milliseconds from when the mouse stops moving
26 // to when the autoclick event is sent.
27 virtual void SetAutoclickDelay(int delay_ms) = 0;
29 // Returns the autoclick delay in milliseconds.
30 virtual int GetAutoclickDelay() const = 0;
32 static AutoclickController* CreateInstance();
34 // The default wait time between last mouse movement and sending
35 // the autoclick.
36 static const int kDefaultAutoclickDelayMs;
38 protected:
39 AutoclickController() {}
42 } // namespace ash
44 #endif // ASH_AUTOCLICK_AUTOCLICK_CONTROLLER_H