1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QOUTPUTMAPPING_P_H
5#define QOUTPUTMAPPING_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 <QString>
19#include <QHash>
20#include <private/qglobal_p.h>
21
22QT_BEGIN_NAMESPACE
23
24class QWindow;
25
26class QOutputMapping
27{
28public:
29 virtual ~QOutputMapping() {}
30
31 static QOutputMapping *get();
32 virtual bool load();
33 virtual QString screenNameForDeviceNode(const QString &deviceNode);
34
35#ifdef Q_OS_WEBOS
36 virtual QWindow *windowForDeviceNode(const QString &deviceNode);
37 static void set(QOutputMapping *mapping);
38#endif
39};
40
41class QDefaultOutputMapping : public QOutputMapping
42{
43public:
44 bool load() override;
45 QString screenNameForDeviceNode(const QString &deviceNode) override;
46
47private:
48 QHash<QString, QString> m_screenTable;
49};
50
51QT_END_NAMESPACE
52
53#endif // QOUTPUTMAPPING_P_H
54

source code of qtbase/src/platformsupport/input/shared/qoutputmapping_p.h