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
qandroidnativeinterface.cpp
Go to the documentation of this file.
1// Copyright (C) 2020 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// Qt-Security score:significant reason:default
4
5#include <qpa/qplatformoffscreensurface.h>
6#include <qpa/qplatformintegration.h>
7
8#include <QtGui/qoffscreensurface_platform.h>
9#include <QtGui/private/qguiapplication_p.h>
10
11#include <QtGui/qpa/qplatformscreen_p.h>
12
13QT_BEGIN_NAMESPACE
14
15using namespace QNativeInterface::Private;
16
17/*!
18 \class QNativeInterface::QAndroidOffscreenSurface
19 \since 6.0
20 \brief Native interface to a offscreen surface on Android.
21
22 Accessed through QOffscreenSurface::nativeInterface().
23
24 \inmodule QtGui
25 \inheaderfile QOffscreenSurface
26 \ingroup native-interfaces
27 \ingroup native-interfaces-qoffscreensurface
28*/
29
32
33QOffscreenSurface *QNativeInterface::QAndroidOffscreenSurface::fromNative(ANativeWindow *nativeSurface)
34{
35 return QGuiApplicationPrivate::platformIntegration()->call<
36 &QAndroidOffScreenIntegration::createOffscreenSurface>(nativeSurface);
37}
38
39/*!
40 \class QNativeInterface::QAndroidScreen
41 \since 6.7
42 \brief Native interface to a screen.
43
44 Accessed through QScreen::nativeInterface().
45 \inmodule QtGui
46 \ingroup native-interfaces
47 \ingroup native-interfaces-qscreen
48*/
49/*!
50 \fn int QNativeInterface::QAndroidScreen::displayId() const;
51 \return the id of the underlying Android display.
52*/
54
55QT_END_NAMESPACE
QT_DEFINE_NATIVE_INTERFACE(QAndroidScreen)
QT_DEFINE_PRIVATE_NATIVE_INTERFACE(QAndroidOffScreenIntegration)
QT_DEFINE_NATIVE_INTERFACE(QAndroidOffscreenSurface)