Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qeglfskmsgbmdevice_p.h
Go to the documentation of this file.
1// Copyright (C) 2015 Pier Luigi Fiorini <pierluigi.fiorini@gmail.com>
2// Copyright (C) 2016 The Qt Company Ltd.
3// Copyright (C) 2016 Pelagicore AG
4// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
5// Qt-Security score:significant reason:default
6
7#ifndef QEGLFSKMSGBMDEVICE_H
8#define QEGLFSKMSGBMDEVICE_H
9
10//
11// W A R N I N G
12// -------------
13//
14// This file is not part of the Qt API. It exists purely as an
15// implementation detail. This header file may change from version to
16// version without notice, or even be removed.
17//
18// We mean it.
19//
20
22#include <private/qeglfskmsdevice_p.h>
23#include <private/qeglfskmseventreader_p.h>
24
25#include <gbm.h>
26
28
29class QEglFSKmsScreen;
30
31class Q_EGLFS_EXPORT QEglFSKmsGbmDevice: public QEglFSKmsDevice
32{
33public:
34 QEglFSKmsGbmDevice(QKmsScreenConfig *screenConfig, const QString &path);
35
36 bool open() override;
37 void close() override;
38
39 void *nativeDisplay() const override;
40 gbm_device *gbmDevice() const;
41
42 QPlatformCursor *globalCursor() const;
43 void destroyGlobalCursor();
44 void createGlobalCursor(QEglFSKmsGbmScreen *screen);
45
46 QPlatformScreen *createScreen(const QKmsOutput &output) override;
47 QPlatformScreen *createHeadlessScreen() override;
48 void registerScreenCloning(QPlatformScreen *screen,
49 QPlatformScreen *screenThisScreenClones,
50 const QList<QPlatformScreen *> &screensCloningThisScreen) override;
51 void registerScreen(QPlatformScreen *screen,
52 bool isPrimary,
53 const QPoint &virtualPos,
54 const QList<QPlatformScreen *> &virtualSiblings) override;
55 void unregisterScreen(QPlatformScreen *screen) override;
56
57 bool usesEventReader() const;
58 QEglFSKmsEventReader *eventReader() { return &m_eventReader; }
59
60private:
61 Q_DISABLE_COPY(QEglFSKmsGbmDevice)
62
63 gbm_device *m_gbm_device;
64 QEglFSKmsEventReader m_eventReader;
65 QEglFSKmsGbmCursor *m_globalCursor;
66};
67
68QT_END_NAMESPACE
69
70#endif // QEGLFSKMSGBMDEVICE_H
void pointerEvent(const QMouseEvent &event) override
This method is called by Qt whenever a QMouseEvent is generated by the underlying pointer input.
void changeCursor(QCursor *windowCursor, QWindow *window) override
This method is called by Qt whenever the cursor graphic should be changed.
void setPos(const QPoint &pos) override
QPoint pos() const override
QEglFSKmsGbmScreen * screen() const
Combined button and popup list for selecting options.
#define DRM_CAP_CURSOR_HEIGHT
#define DRM_CAP_CURSOR_WIDTH