Details
-
Epic
-
Resolution: Done
-
P1: Critical
-
6.0
-
AndroidExtras in Qt6
-
Description
QtAndroidExtras contains many important APIs to interact with the Android API with the JNI calls. To ensure the proper working of Qt apps on Android, things like permission handling and dealing with intent are very important, as well as permission handling which is needed by many examples/applications. In general, Qt doesn't need to implement everything that is OS-specific, but at least the tools to do that should be from the start. Other platforms, like iOS, allow using platform API with Qt, for Android that's only available through the JNI, thus it's important to have that ready by default whenever needed by the users. Since we're seeing more attention towards Qt for Android, this is not something that we should leave out.
We're not having Android Extras in Qt 6.0 however, in the subsequent releases (6.1, 6.2) we aim to include the fundamental most needed features from QtAndroidExtras into QtBase.
From the discussion and comments below, Qt Android Extras' the following parts can be moved/re-designed in upcoming releases of Qt namely Qt 6.1/6.2 outside of QtAndroidExtras:
- QAndroidJniObject is mandatory and most important, it has many convenient functions to interact with JNI calls.
- QAndroidJniEnvironment This could include a new function registerNatives() to facilitate registering native methods. Uses for this is to register natives, create class instances, use the JNIEnv* to process JNI objects like arrays.
- QAndroidService is a QGuiApplication alternative to run a service loop, while AndroidExtras have more service classes, this is mandatory for all services even when working with remote objects. Other classes to handle services, intents could be kept in extras.
The list below is for items that are still to be decided soon:
- QtAndroid namespace, mainly for handling permissions and activities/intents.
- activity() , androidContext(), sdkVersion() (could have "android" prefix)
- All permission handling functions.
- QAndroidIntent class for calling and receiving intents (exchange data).
Notes:
Also, since many other modules are now relying on either qtandroidextras or qtbase private jni headers, they should be all updated as soon as we have the intended JNI changes in place. The modules affected: qtsensors, qtmultimedia, qtconnectivity, qtlocation, qtgamepad, qtwebview, qtpurchasing.
Attachments
Issue Links
- depends on
-
QTBUG-90498 Permission handling API
- Closed
- is required for
-
QTBUG-82847 Qt Purchasing support (via example app) in Qt 6.x
- In Progress
-
QTBUG-62425 Changes planned for Qt 6
- Closed
-
QTBUG-89509 Module Migration for Qt 6.2
- Closed
-
QTBUG-73409 Android Permission Result wrong value
- Closed
-
QTBUG-83251 Clean up Q(Mac/Win/X11/Android)Extras
- Closed
-
QTBUG-92550 Port QtSensors backend on Android to new QJni API
- Closed
-
QTBUG-84776 Move QtPurchasing as an example
- Closed
- relates to
-
QTBUG-79244 Function QtAndroid::unbindService doesn't exist
- Reported
-
QTBUG-89284 Project ERROR: Unknown module(s) in QT: androidextras
- Closed
-
QTBUG-94597 QJniObject cannot find class in 6.2
- Closed
-
QTBUG-35642 Android: Define a public API in Java
- Open
-
QTBUG-80233 Qt 6 platform APIs revamp
- Closed
-
QTBUG-72086 Qt for Mobile - Improving the cross-platform usability
- Closed
-
QTBUG-58078 Transmit events to Android in transparent parts
- Reported
-
QTBUG-57216 Create a container to embed Quick items into a native Android/iOS application
- Closed
- mentioned in
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...