1// Copyright (C) 2021 LG Electronics Inc.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
3
4#ifndef QWAYLANDPRESENTATIONTIME_P_H
5#define QWAYLANDPRESENTATIONTIME_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists purely as an
12// implementation detail. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include <QObject>
19#include <QtWaylandCompositor/qwaylandcompositorextension.h>
20#include <QtCore/private/qglobal_p.h>
21
22QT_BEGIN_NAMESPACE
23
24class QQuickWindow;
25class QWaylandPresentationTimePrivate;
26
27class Q_WAYLANDCOMPOSITOR_EXPORT QWaylandPresentationTime : public QWaylandCompositorExtensionTemplate<QWaylandPresentationTime>
28{
29 Q_OBJECT
30 Q_DECLARE_PRIVATE(QWaylandPresentationTime)
31public:
32 QWaylandPresentationTime();
33 QWaylandPresentationTime(QWaylandCompositor *compositor);
34
35 QWaylandCompositor *compositor() const;
36 void initialize() override;
37
38 Q_INVOKABLE void sendFeedback(QQuickWindow *window, quint64 sequence, quint64 tv_sec, quint32 tv_nsec);
39
40 static const struct wl_interface *interface();
41 static QByteArray interfaceName();
42
43signals:
44 void presented(quint64 sequence, quint64 tv_sec, quint32 tv_nsec, quint32 refresh_nsec);
45};
46
47QT_END_NAMESPACE
48
49#endif
50

source code of qtwayland/src/compositor/extensions/qwaylandpresentationtime_p.h