forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
autoclick_controller_common_delegate.h
47 lines (34 loc) · 1.35 KB
/
autoclick_controller_common_delegate.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
// Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef ASH_AUTOCLICK_COMMON_AUTOCLICK_CONTROLLER_COMMON_DELEGATE_H
#define ASH_AUTOCLICK_COMMON_AUTOCLICK_CONTROLLER_COMMON_DELEGATE_H
#include "base/macros.h"
namespace views {
class Widget;
}
namespace gfx {
class Point;
}
namespace ash {
class AutoclickControllerCommonDelegate {
public:
AutoclickControllerCommonDelegate() {}
virtual ~AutoclickControllerCommonDelegate() {}
// Creates a ring widget at |event_location|.
// AutoclickControllerCommonDelegate still has ownership of the widget they
// created.
virtual views::Widget* CreateAutoclickRingWidget(
const gfx::Point& event_location) = 0;
// Moves |widget| to |event_location|.
virtual void UpdateAutoclickRingWidget(views::Widget* widget,
const gfx::Point& event_location) = 0;
// Generates a click with |mouse_event_flags| at |event_location|.
virtual void DoAutoclick(const gfx::Point& event_location,
const int mouse_event_flags) = 0;
virtual void OnAutoclickCanceled() = 0;
private:
DISALLOW_COPY_AND_ASSIGN(AutoclickControllerCommonDelegate);
};
} // namespace ash
#endif // ASH_AUTOCLICK_COMMON_AUTOCLICK_CONTROLLER_COMMON_DELEGATE_H