summaryrefslogtreecommitdiffstats
path: root/tests/manual/qtabletevent/event_compression/mousestatwidget.h
blob: f204a753a3178a21b70acba173968735351a99cb (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
// Copyright (C) 2016 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only

#ifndef MOUSESTATWIDGET_H
#define MOUSESTATWIDGET_H

#include <QWidget>

class QTabletEvent;
class QMouseEvent;
class QTimerEvent;
class QPaintEvent;

class MouseStatWidget : public QWidget
{
public:
    MouseStatWidget(bool acceptTabletEvent = true);
protected:
    void tabletEvent(QTabletEvent *);
    void mouseMoveEvent(QMouseEvent *);
    void timerEvent(QTimerEvent *);
    void paintEvent(QPaintEvent *);
private:
    const bool acceptTabletEvent;
    int receivedMouseEventCount;
    int receivedMouseEventCountToPaint;
    int receivedTabletEventCount;
    int receivedTabletEventCountToPaint;
};

#endif // MOUSESTATWIDGET_H