blob: f42805e2c6b3d60ee2f6d6369572b766fb627065 (
plain)
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
|
/* SPDX-License-Identifier: GPL-2.0-or-later
* Copyright 2001-2002 NaN Holding BV. All rights reserved. */
/** \file
* \ingroup GHOST
* Declaration of GHOST_EventButton class.
*/
#pragma once
#include "GHOST_Event.h"
#include "GHOST_Window.h"
/**
* Mouse button event.
*/
class GHOST_EventButton : public GHOST_Event {
public:
/**
* Constructor.
* \param time: The time this event was generated.
* \param type: The type of this event.
* \param window: The window of this event.
* \param button: The state of the buttons were at the time of the event.
* \param tablet: The tablet data associated with this event.
*/
GHOST_EventButton(uint64_t time,
GHOST_TEventType type,
GHOST_IWindow *window,
GHOST_TButton button,
const GHOST_TabletData &tablet)
: GHOST_Event(time, type, window), m_buttonEventData({button, tablet})
{
m_data = &m_buttonEventData;
}
protected:
/** The button event data. */
GHOST_TEventButtonData m_buttonEventData;
};
|