Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
qandroidplatformintegration.cpp
Go to the documentation of this file.
1// Copyright (C) 2012 BogDan Vatra <bogdan@kde.org>
2// Copyright (C) 2021 The Qt Company Ltd.
3// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
4
6
8#include "androidjnimain.h"
23
24#include <QGuiApplication>
25#include <QOffscreenSurface>
26#include <QOpenGLContext>
27#include <QThread>
28#include <QtCore/QJniObject>
29#include <QtGui/private/qeglpbuffer_p.h>
30#include <QtGui/private/qguiapplication_p.h>
31#include <QtGui/private/qoffscreensurface_p.h>
32#include <qpa/qplatformoffscreensurface.h>
33#include <qpa/qplatformwindow.h>
34#include <qpa/qwindowsysteminterface.h>
35
36#include <jni.h>
37
38#if QT_CONFIG(vulkan)
41#endif
42
43#include <QtGui/qpa/qplatforminputcontextfactory_p.h>
44
46
47using namespace Qt::StringLiterals;
48
49Q_CONSTINIT QSize QAndroidPlatformIntegration::m_defaultScreenSize = QSize(320, 455);
50Q_CONSTINIT QRect QAndroidPlatformIntegration::m_defaultAvailableGeometry = QRect(0, 0, 320, 455);
51Q_CONSTINIT QSize QAndroidPlatformIntegration::m_defaultPhysicalSize = QSize(50, 71);
52
53Qt::ScreenOrientation QAndroidPlatformIntegration::m_orientation = Qt::PrimaryOrientation;
54Qt::ScreenOrientation QAndroidPlatformIntegration::m_nativeOrientation = Qt::PrimaryOrientation;
55
56bool QAndroidPlatformIntegration::m_showPasswordEnabled = false;
57static bool m_running = false;
58
59Q_DECLARE_JNI_CLASS(QtNative, "org/qtproject/qt/android/QtNative")
61
62Q_DECLARE_JNI_TYPE(List, "Ljava/util/List;")
63
64namespace {
65
66QAndroidPlatformScreen* createScreenForDisplayId(int displayId)
67{
68 const QJniObject display = QJniObject::callStaticObjectMethod<QtJniTypes::Display>(
69 QtJniTypes::className<QtJniTypes::QtNative>(),
70 "getDisplay",
71 displayId);
72 if (!display.isValid())
73 return nullptr;
75}
76
77} // anonymous namespace
78
80{
81 if (resource=="JavaVM")
82 return QtAndroid::javaVM();
83 if (resource == "QtActivity")
84 return QtAndroid::activity();
85 if (resource == "QtService")
86 return QtAndroid::service();
87 if (resource == "AndroidStyleData") {
88 if (m_androidStyle) {
89 if (m_androidStyle->m_styleData.isEmpty())
91 return &m_androidStyle->m_styleData;
92 }
93 else
94 return nullptr;
95 }
96 if (resource == "AndroidStandardPalette") {
98 return &m_androidStyle->m_standardPalette;
99
100 return nullptr;
101 }
102 if (resource == "AndroidQWidgetFonts") {
103 if (m_androidStyle)
104 return &m_androidStyle->m_QWidgetsFonts;
105
106 return nullptr;
107 }
108 if (resource == "AndroidDeviceName") {
109 static QString deviceName = QtAndroid::deviceName();
110 return &deviceName;
111 }
112 return 0;
113}
114
116{
117#if QT_CONFIG(vulkan)
118 if (resource == "vkSurface") {
119 if (window->surfaceType() == QSurface::VulkanSurface) {
121 // return a pointer to the VkSurfaceKHR, not the value
122 return w ? w->vkSurface() : nullptr;
123 }
124 }
125#else
126 Q_UNUSED(resource);
128#endif
129 return nullptr;
130}
131
133{
134 if (QEGLPlatformContext *platformContext = static_cast<QEGLPlatformContext *>(context->handle())) {
135 if (resource == "eglcontext")
136 return platformContext->eglContext();
137 else if (resource == "eglconfig")
138 return platformContext->eglConfig();
139 else if (resource == "egldisplay")
140 return platformContext->eglDisplay();
141 }
142 return nullptr;
143}
144
146{
147 if (event->type() != QEvent::User)
148 return;
149
153
154#if QT_CONFIG(accessibility)
155 // Android accessibility activation event might have been already received
156 api->accessibility()->setActive(QtAndroidAccessibility::isActive());
157#endif // QT_CONFIG(accessibility)
158
159 if (!m_running) {
160 m_running = true;
162 }
163 api->flushPendingUpdates();
164}
165
167 : m_touchDevice(nullptr)
168#if QT_CONFIG(accessibility)
169 , m_accessibility(nullptr)
170#endif
171{
172 Q_UNUSED(paramList);
173 m_androidPlatformNativeInterface = new QAndroidPlatformNativeInterface();
174
175 m_eglDisplay = eglGetDisplay(EGL_DEFAULT_DISPLAY);
176 if (Q_UNLIKELY(m_eglDisplay == EGL_NO_DISPLAY))
177 qFatal("Could not open egl display");
178
179 EGLint major, minor;
180 if (Q_UNLIKELY(!eglInitialize(m_eglDisplay, &major, &minor)))
181 qFatal("Could not initialize egl display");
182
183 if (Q_UNLIKELY(!eglBindAPI(EGL_OPENGL_ES_API)))
184 qFatal("Could not bind GL_ES API");
185
186 m_primaryDisplayId = QJniObject::getStaticField<jint>(
187 QtJniTypes::className<QtJniTypes::Display>(), "DEFAULT_DISPLAY");
188
189 const QJniObject nativeDisplaysList = QJniObject::callStaticObjectMethod<QtJniTypes::List>(
190 QtJniTypes::className<QtJniTypes::QtNative>(),
191 "getAvailableDisplays");
192
193 const int numberOfAvailableDisplays = nativeDisplaysList.callMethod<jint>("size");
194 for (int i = 0; i < numberOfAvailableDisplays; ++i) {
195 const QJniObject display =
196 nativeDisplaysList.callObjectMethod<jobject, jint>("get", jint(i));
197 const int displayId = display.callMethod<jint>("getDisplayId");
198 const bool isPrimary = (m_primaryDisplayId == displayId);
200
201 if (isPrimary)
202 m_primaryScreen = screen;
203
205 m_screens[displayId] = screen;
206 }
207
208 if (numberOfAvailableDisplays == 0) {
209 // If no displays are found, add a dummy display
211 m_primaryScreen = defaultScreen;
213 }
214
215 m_mainThread = QThread::currentThread();
216
217 m_androidFDB = new QAndroidPlatformFontDatabase();
218 m_androidPlatformServices = new QAndroidPlatformServices();
219
220#ifndef QT_NO_CLIPBOARD
221 m_androidPlatformClipboard = new QAndroidPlatformClipboard();
222#endif
223
224 m_androidSystemLocale = new QAndroidSystemLocale;
225
226#if QT_CONFIG(accessibility)
227 m_accessibility = new QAndroidPlatformAccessibility();
228#endif // QT_CONFIG(accessibility)
229
230 QJniObject javaActivity(QtAndroid::activity());
231 if (!javaActivity.isValid())
232 javaActivity = QtAndroid::service();
233
234 if (javaActivity.isValid()) {
235 QJniObject resources = javaActivity.callObjectMethod("getResources", "()Landroid/content/res/Resources;");
236 QJniObject configuration = resources.callObjectMethod("getConfiguration", "()Landroid/content/res/Configuration;");
237
238 int touchScreen = configuration.getField<jint>("touchscreen");
239 if (touchScreen == QJniObject::getStaticField<jint>("android/content/res/Configuration", "TOUCHSCREEN_FINGER")
240 || touchScreen == QJniObject::getStaticField<jint>("android/content/res/Configuration", "TOUCHSCREEN_STYLUS"))
241 {
242 QJniObject pm = javaActivity.callObjectMethod("getPackageManager", "()Landroid/content/pm/PackageManager;");
243 Q_ASSERT(pm.isValid());
244 int maxTouchPoints = 1;
245 if (pm.callMethod<jboolean>("hasSystemFeature","(Ljava/lang/String;)Z",
246 QJniObject::getStaticObjectField("android/content/pm/PackageManager",
247 "FEATURE_TOUCHSCREEN_MULTITOUCH_JAZZHAND",
248 "Ljava/lang/String;").object())) {
249 maxTouchPoints = 10;
250 } else if (pm.callMethod<jboolean>("hasSystemFeature","(Ljava/lang/String;)Z",
251 QJniObject::getStaticObjectField("android/content/pm/PackageManager",
252 "FEATURE_TOUCHSCREEN_MULTITOUCH_DISTINCT",
253 "Ljava/lang/String;").object())) {
254 maxTouchPoints = 4;
255 } else if (pm.callMethod<jboolean>("hasSystemFeature","(Ljava/lang/String;)Z",
256 QJniObject::getStaticObjectField("android/content/pm/PackageManager",
257 "FEATURE_TOUCHSCREEN_MULTITOUCH",
258 "Ljava/lang/String;").object())) {
259 maxTouchPoints = 2;
260 }
261
262 m_touchDevice = new QPointingDevice("Android touchscreen", 1,
269 maxTouchPoints,
270 0);
272 }
273
274 auto contentResolver = javaActivity.callObjectMethod("getContentResolver", "()Landroid/content/ContentResolver;");
275 Q_ASSERT(contentResolver.isValid());
276 QJniObject txtShowPassValue = QJniObject::callStaticObjectMethod(
277 "android/provider/Settings$System",
278 "getString",
279 "(Landroid/content/ContentResolver;Ljava/lang/String;)Ljava/lang/String;",
280 contentResolver.object(),
281 QJniObject::getStaticObjectField("android/provider/Settings$System",
282 "TEXT_SHOW_PASSWORD",
283 "Ljava/lang/String;").object());
284 if (txtShowPassValue.isValid()) {
285 bool ok = false;
286 const int txtShowPass = txtShowPassValue.toString().toInt(&ok);
287 m_showPasswordEnabled = ok ? (txtShowPass == 1) : false;
288 }
289 }
290
291 // We can't safely notify the jni bridge that we're up and running just yet, so let's postpone
292 // it for now.
293 QCoreApplication::postEvent(m_androidPlatformNativeInterface, new QEvent(QEvent::User));
294}
295
297{
298 static bool needsWorkaround =
299 QtAndroid::deviceName().compare("samsung SM-T211"_L1, Qt::CaseInsensitive) == 0
300 || QtAndroid::deviceName().compare("samsung SM-T210"_L1, Qt::CaseInsensitive) == 0
301 || QtAndroid::deviceName().compare("samsung SM-T215"_L1, Qt::CaseInsensitive) == 0;
302 return needsWorkaround;
303}
304
306{
308 if (icStr.isNull())
309 m_inputContext.reset(new QAndroidInputContext);
310 else
311 m_inputContext.reset(QPlatformInputContextFactory::create(icStr));
312}
313
315{
316 switch (cap) {
317 case ApplicationState: return true;
318 case ThreadedPixmaps: return true;
319 case NativeWidgets: return QtAndroid::activity();
320 case OpenGL: return QtAndroid::activity();
321 case ForeignWindows: return QtAndroid::activity();
324 case TopStackedNativeChildWindows: return false;
325 case MaximizeUsingFullscreenGeometry: return true;
326 default:
328 }
329}
330
332{
333 if (!QtAndroid::activity())
334 return nullptr;
335
337}
338
340{
341 if (!QtAndroid::activity())
342 return nullptr;
343 QSurfaceFormat format(context->format());
344 format.setAlphaBufferSize(8);
345 format.setRedBufferSize(8);
346 format.setGreenBufferSize(8);
347 format.setBlueBufferSize(8);
348 auto ctx = new QAndroidPlatformOpenGLContext(format, context->shareHandle(), m_eglDisplay);
349 return ctx;
350}
351
353{
354 return QEGLPlatformContext::createFrom<QAndroidPlatformOpenGLContext>(context, display, m_eglDisplay, shareContext);
355}
356
358{
359 if (!QtAndroid::activity())
360 return nullptr;
361
363 format.setAlphaBufferSize(8);
364 format.setRedBufferSize(8);
365 format.setGreenBufferSize(8);
366 format.setBlueBufferSize(8);
367
368 return new QEGLPbuffer(m_eglDisplay, format, surface);
369}
370
372{
373 if (!QtAndroid::activity() || !nativeSurface)
374 return nullptr;
375
376 auto *surface = new QOffscreenSurface;
377 auto *surfacePrivate = QOffscreenSurfacePrivate::get(surface);
378 surfacePrivate->platformOffscreenSurface = new QAndroidPlatformOffscreenSurface(nativeSurface, m_eglDisplay, surface);
379 return surface;
380}
381
383{
384 if (!QtAndroid::activity())
385 return nullptr;
386
387#if QT_CONFIG(vulkan)
388 if (window->surfaceType() == QSurface::VulkanSurface)
390#endif
391
392 return new QAndroidPlatformOpenGLWindow(window, m_eglDisplay);
393}
394
396{
397 return new QAndroidPlatformForeignWindow(window, nativeHandle);
398}
399
401{
402 return new QAndroidEventDispatcher;
403}
404
406{
407 if (m_eglDisplay != EGL_NO_DISPLAY)
408 eglTerminate(m_eglDisplay);
409
410 delete m_androidPlatformNativeInterface;
411 delete m_androidFDB;
412 delete m_androidSystemLocale;
413
414#ifndef QT_NO_CLIPBOARD
415 delete m_androidPlatformClipboard;
416#endif
417
419}
420
422{
423 return m_androidFDB;
424}
425
426#ifndef QT_NO_CLIPBOARD
428{
429 return m_androidPlatformClipboard;
430}
431#endif
432
434{
435 return m_inputContext.data();
436}
437
439{
440 return m_androidPlatformNativeInterface;
441}
442
444{
445 return m_androidPlatformServices;
446}
447
449{
450 switch (hint) {
452 // this number is from a hard-coded value in Android code (cf. PasswordTransformationMethod)
453 return m_showPasswordEnabled ? 1500 : 0;
454 case ShowIsMaximized:
455 return true;
456 default:
458 }
459}
460
462{
463 // Don't maximize dialogs on Android
464 if (flags & Qt::Dialog & ~Qt::Window)
465 return Qt::WindowNoState;
466
468}
469
470static const auto androidThemeName = "android"_L1;
472{
474}
475
477{
478 if (androidThemeName == name)
479 return QAndroidPlatformTheme::instance(m_androidPlatformNativeInterface);
480
481 return 0;
482}
483
484void QAndroidPlatformIntegration::setDefaultDisplayMetrics(int availableLeft, int availableTop,
485 int availableWidth, int availableHeight,
486 int physicalWidth, int physicalHeight,
487 int screenWidth, int screenHeight)
488{
489 m_defaultAvailableGeometry = QRect(availableLeft, availableTop,
490 availableWidth, availableHeight);
491 m_defaultPhysicalSize = QSize(physicalWidth, physicalHeight);
492 m_defaultScreenSize = QSize(screenWidth, screenHeight);
493}
494
496 Qt::ScreenOrientation nativeOrientation)
497{
498 m_orientation = currentOrientation;
499 m_nativeOrientation = nativeOrientation;
500}
501
503{
504 if (m_primaryScreen) {
505 m_primaryScreen->setSizeParameters(m_defaultPhysicalSize, m_defaultScreenSize,
506 m_defaultAvailableGeometry);
507 }
508}
509
510#if QT_CONFIG(accessibility)
511QPlatformAccessibility *QAndroidPlatformIntegration::accessibility() const
512{
513 return m_accessibility;
514}
515#endif
516
518{
519 if (m_primaryScreen)
520 QMetaObject::invokeMethod(m_primaryScreen, "setAvailableGeometry", Qt::AutoConnection, Q_ARG(QRect, availableGeometry));
521}
522
524{
525 if (m_primaryScreen)
526 QMetaObject::invokeMethod(m_primaryScreen, "setPhysicalSize", Qt::AutoConnection, Q_ARG(QSize, QSize(width, height)));
527}
528
530{
531 if (m_primaryScreen)
532 QMetaObject::invokeMethod(m_primaryScreen, "setSize", Qt::AutoConnection, Q_ARG(QSize, QSize(width, height)));
533}
534
535Qt::ColorScheme QAndroidPlatformIntegration::m_colorScheme = Qt::ColorScheme::Light;
536
538{
539 if (m_colorScheme == colorScheme)
540 return;
541 m_colorScheme = colorScheme;
542
545}
546
548 const QSize &screenSize,
549 const QRect &availableGeometry)
550{
551 if (m_primaryScreen) {
552 QMetaObject::invokeMethod(m_primaryScreen, "setSizeParameters", Qt::AutoConnection,
553 Q_ARG(QSize, physicalSize), Q_ARG(QSize, screenSize),
554 Q_ARG(QRect, availableGeometry));
555 }
556}
557
559{
560 if (m_primaryScreen)
561 QMetaObject::invokeMethod(m_primaryScreen, "setRefreshRate", Qt::AutoConnection,
562 Q_ARG(qreal, refreshRate));
563}
564
566{
567 auto result = m_screens.insert(displayId, nullptr);
568 if (result.first->second == nullptr) {
569 auto it = result.first;
570 it->second = createScreenForDisplayId(displayId);
571 if (it->second == nullptr)
572 return;
573 const bool isPrimary = (m_primaryDisplayId == displayId);
574 if (isPrimary)
575 m_primaryScreen = it->second;
577 } else {
578 qWarning() << "Display with id" << displayId << "already exists.";
579 }
580}
581
583{
584 auto it = m_screens.find(displayId);
585 if (it == m_screens.end() || it->second == nullptr) {
586 handleScreenAdded(displayId);
587 }
588 // We do not do anything more here as handling of change of
589 // rotation and refresh rate is done in QtActivityDelegate java class
590 // which calls QAndroidPlatformIntegration::setOrientation, and
591 // QAndroidPlatformIntegration::setRefreshRate accordingly.
592}
593
595{
596 auto it = m_screens.find(displayId);
597
598 if (it == m_screens.end())
599 return;
600
601 if (it->second != nullptr)
603
604 m_screens.erase(it);
605}
606
607#if QT_CONFIG(vulkan)
608
609QPlatformVulkanInstance *QAndroidPlatformIntegration::createPlatformVulkanInstance(QVulkanInstance *instance) const
610{
611 return new QAndroidPlatformVulkanInstance(instance);
612}
613
614#endif // QT_CONFIG(vulkan)
615
QPlatformFontDatabase * fontDatabase() const override
Accessor for the platform integration's fontdatabase.
QPlatformWindow * createForeignWindow(QWindow *window, WId nativeHandle) const override
static void setDefaultDisplayMetrics(int availableLeft, int availableTop, int availableWidth, int availableHeight, int physicalWidth, int physicalHeight, int screenWidth, int screenHeight)
void initialize() override
Performs initialization steps that depend on having an event dispatcher available.
QPlatformInputContext * inputContext() const override
Returns the platforms input context.
QStringList themeNames() const override
QPlatformNativeInterface * nativeInterface() const override
QPlatformTheme * createPlatformTheme(const QString &name) const override
QPlatformBackingStore * createPlatformBackingStore(QWindow *window) const override
Factory function for QPlatformBackingStore.
void setAvailableGeometry(const QRect &availableGeometry)
QOffscreenSurface * createOffscreenSurface(ANativeWindow *nativeSurface) const override
void setScreenSize(int width, int height)
QPlatformOffscreenSurface * createPlatformOffscreenSurface(QOffscreenSurface *surface) const override
Factory function for QOffscreenSurface.
QPlatformOpenGLContext * createPlatformOpenGLContext(QOpenGLContext *context) const override
Factory function for QPlatformOpenGLContext.
void setPhysicalSize(int width, int height)
bool hasCapability(QPlatformIntegration::Capability cap) const override
void setScreenSizeParameters(const QSize &physicalSize, const QSize &screenSize, const QRect &availableGeometry)
QPlatformWindow * createPlatformWindow(QWindow *window) const override
Factory function for QPlatformWindow.
QPlatformClipboard * clipboard() const override
Accessor for the platform integration's clipboard.
QOpenGLContext * createOpenGLContext(EGLContext context, EGLDisplay display, QOpenGLContext *shareContext) const override
Qt::WindowState defaultWindowState(Qt::WindowFlags flags) const override
QAndroidPlatformIntegration(const QStringList &paramList)
QAbstractEventDispatcher * createEventDispatcher() const override
Factory function for the GUI event dispatcher.
QVariant styleHint(StyleHint hint) const override
static void setScreenOrientation(Qt::ScreenOrientation currentOrientation, Qt::ScreenOrientation nativeOrientation)
QPlatformServices * services() const override
static void setColorScheme(Qt::ColorScheme colorScheme)
void customEvent(QEvent *event) override
This event handler can be reimplemented in a subclass to receive custom events.
void * nativeResourceForContext(const QByteArray &resource, QOpenGLContext *context) override
void * nativeResourceForWindow(const QByteArray &resource, QWindow *window) override
void * nativeResourceForIntegration(const QByteArray &resource) override
std::shared_ptr< AndroidStyle > m_androidStyle
void setSizeParameters(const QSize &physicalSize, const QSize &size, const QRect &availableGeometry)
static QAndroidPlatformTheme * instance(QAndroidPlatformNativeInterface *androidPlatformNativeInterface=nullptr)
\inmodule QtCore
Definition qbytearray.h:57
static void postEvent(QObject *receiver, QEvent *event, int priority=Qt::NormalEventPriority)
A pbuffer-based implementation of QPlatformOffscreenSurface for EGL.
An EGL context implementation.
\inmodule QtCore
Definition qcoreevent.h:45
iterator end()
Definition qflatmap_p.h:773
iterator erase(iterator it)
Definition qflatmap_p.h:608
iterator find(const Key &key)
Definition qflatmap_p.h:816
std::pair< iterator, bool > insert(const Key &key, const T &value)
Definition qflatmap_p.h:678
static QPlatformIntegration * platformIntegration()
\inmodule QtCore
\inmodule QtCore
Definition qmutex.h:317
static QOffscreenSurfacePrivate * get(QOffscreenSurface *surface)
\inmodule QtGui
QSurfaceFormat requestedFormat() const
Returns the requested surfaceformat of this offscreen surface.
\inmodule QtGui
The QPlatformBackingStore class provides the drawing area for top-level windows.
The QPlatformClipboard class provides an abstraction for the system clipboard.
The QPlatformFontDatabase class makes it possible to customize how fonts are discovered and how they ...
static QPlatformInputContext * create()
The QPlatformInputContext class abstracts the input method dependent data and composing state.
virtual QVariant styleHint(StyleHint hint) const
virtual Qt::WindowState defaultWindowState(Qt::WindowFlags) const
virtual bool hasCapability(Capability cap) const
Capability
Capabilities are used to determine specific features of a platform integration.
The QPlatformNativeInterface class provides an abstraction for retrieving native resource handles.
The QPlatformOpenGLContext class provides an abstraction for native GL contexts.
The QPlatformServices provides the backend for desktop-related functionality.
The QPlatformTheme class allows customizing the UI based on themes.
The QPlatformVulkanInstance class provides an abstraction for Vulkan instances.
The QPlatformWindow class provides an abstraction for top-level windows.
The QPointingDevice class describes a device from which mouse, touch or tablet events originate.
\inmodule QtCore\reentrant
Definition qrect.h:30
T * data() const noexcept
Returns the value of the pointer referenced by this object.
void reset(T *other=nullptr) noexcept(noexcept(Cleanup::cleanup(std::declval< T * >())))
Deletes the existing object it is pointing to (if any), and sets its pointer to other.
\inmodule QtCore
Definition qsize.h:25
\inmodule QtCore
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition qstring.h:127
bool isNull() const
Returns true if this string is null; otherwise returns false.
Definition qstring.h:898
int compare(const QString &s, Qt::CaseSensitivity cs=Qt::CaseSensitive) const noexcept
Definition qstring.cpp:6498
The QSurfaceFormat class represents the format of a QSurface. \inmodule QtGui.
@ VulkanSurface
Definition qsurface.h:35
static QThread * currentThread()
Definition qthread.cpp:966
\inmodule QtCore
Definition qvariant.h:64
The QVulkanInstance class represents a native Vulkan instance, enabling Vulkan rendering onto a QSurf...
static void registerInputDevice(const QInputDevice *device)
static void handleScreenAdded(QPlatformScreen *screen, bool isPrimary=false)
Should be called by the implementation whenever a new screen is added.
static void handleScreenRemoved(QPlatformScreen *screen)
Should be called by the implementation whenever a screen is removed.
\inmodule QtGui
Definition qwindow.h:63
EGLContext ctx
QSet< QString >::iterator it
struct wl_display * display
Definition linuxdmabuf.h:41
Combined button and popup list for selecting options.
void setAndroidPlatformIntegration(QAndroidPlatformIntegration *androidPlatformIntegration)
QBasicMutex * platformInterfaceMutex()
QString deviceName()
JavaVM * javaVM()
void notifyQtAndroidPluginRunning(bool running)
QtJniTypes::Activity activity()
QtJniTypes::Service service()
WindowState
Definition qnamespace.h:250
@ WindowNoState
Definition qnamespace.h:251
ColorScheme
Definition qnamespace.h:49
ScreenOrientation
Definition qnamespace.h:270
@ PrimaryOrientation
Definition qnamespace.h:271
@ CaseInsensitive
@ AutoConnection
@ Window
Definition qnamespace.h:206
@ Dialog
Definition qnamespace.h:207
static void * context
static const auto androidThemeName
static bool needsBasicRenderloopWorkaround()
static bool m_running
#define Q_UNLIKELY(x)
typedef EGLDisplay(EGLAPIENTRYP PFNEGLGETPLATFORMDISPLAYEXTPROC)(EGLenum platform
#define qGuiApp
#define qWarning
Definition qlogging.h:162
#define qFatal
Definition qlogging.h:164
#define Q_ARG(Type, data)
Definition qobjectdefs.h:62
GLfloat GLfloat GLfloat w
[0]
GLint GLsizei GLsizei height
GLint GLsizei width
GLbitfield flags
GLuint name
GLint GLsizei GLsizei GLenum format
struct _cl_event * event
GLuint64EXT * result
[6]
GLenum cap
static int defaultScreen
#define Q_ASSERT(cond)
Definition qrandom.cpp:47
QT_BEGIN_NAMESPACE Q_DECLARE_JNI_CLASS(Environment, "android/os/Environment")
Q_DECLARE_JNI_TYPE(File, "Ljava/io/File;")
static QT_BEGIN_NAMESPACE QVariant hint(QPlatformIntegration::StyleHint h)
#define QT_CONFIG(feature)
#define Q_UNUSED(x)
struct _XDisplay Display
double qreal
Definition qtypes.h:92
if(qFloatDistance(a, b)<(1<< 7))
[0]
QObject::connect nullptr
QReadWriteLock lock
[0]
aWidget window() -> setWindowTitle("New Window Title")
[2]
QQuickView * view
[0]
static QJsonObject loadStyleData()
static bool invokeMethod(QObject *obj, const char *member, Qt::ConnectionType, QGenericReturnArgument ret, QGenericArgument val0=QGenericArgument(nullptr), QGenericArgument val1=QGenericArgument(), QGenericArgument val2=QGenericArgument(), QGenericArgument val3=QGenericArgument(), QGenericArgument val4=QGenericArgument(), QGenericArgument val5=QGenericArgument(), QGenericArgument val6=QGenericArgument(), QGenericArgument val7=QGenericArgument(), QGenericArgument val8=QGenericArgument(), QGenericArgument val9=QGenericArgument())
\threadsafe This is an overloaded member function, provided for convenience. It differs from the abov...