[Interest] qt6: any QtAndroid::androidActivity replacement?

2021-09-18 Thread Alexander Dyagilev
Hello, I'm trying to port my Android application from Qt5 to Qt6. Documentation seems to be very poorly organized. I can't find anywhere a section about new Qt Android classes. Can someone please give me the link (if any)? ___ Interest mailing list

Re: [Interest] qt6: any QtAndroid::androidActivity replacement?

2021-09-18 Thread Alexander Dyagilev
I did find this (using Google): https://doc-snapshots.qt.io/qt6-dev/qtandroidprivate.html But I can't use it: #include does not work - it says: fatal error: 'QtAndroid' file not found. Qt 6.2 RC... On 9/18/2021 3:53 PM, Alexander Dyagilev wrote: Hello, I'm trying to port my Android applic

Re: [Interest] qt6: any QtAndroid::androidActivity replacement?

2021-09-18 Thread Alexander Dyagilev
I've also found this: https://doc-snapshots.qt.io/qt6-dev/qnativeinterface-qandroidapplication.html#details It says it can be accessed through QCoreApplication::nativeInterface(). I've tried: QCoreApplication::nativeInterface()->context(). It does not compile: mysterious error : call to non-st

Re: [Interest] qt6: any QtAndroid::androidActivity replacement?

2021-09-18 Thread Alexander Dyagilev
This does not work too: QCoreApplication::instance()->nativeInterface()->context(); C:\Users\alexa\Documents\Qt Creator\untitled3\main.cpp:14: error: no matching member function for call to 'nativeInterface' ..\untitled3\main.cpp:14:35: error: no matching member function for call to 'nativeInt

Re: [Interest] qt6: any QtAndroid::androidActivity replacement?

2021-09-18 Thread Alexander Dyagilev
So, I've managed to find a right one: auto meow = app.nativeInterface(); meow->context(); On 9/18/2021 4:11 PM, Alexander Dyagilev wrote: This does not work too: QCoreApplication::instance()->nativeInterface()->context(); C:\Users\alexa\Documents\Qt Creator\untitled3\main.cpp:14: error: no

Re: [Interest] qt6: any QtAndroid::androidActivity replacement?

2021-09-18 Thread Alexander Dyagilev
For those who can be interested. Here is my current qt5androidcompat.h file to ease the support of both Qt5 and Qt6. Here you can find how to use new Qt6 API: #pragma once #include #ifdef Q_OS_ANDROID #if QT_VERSION < QT_VERSION_CHECK(6, 0, 0) #include #include using QtJniObject = QAndr

Re: [Interest] qt6: any QtAndroid::androidActivity replacement?

2021-09-20 Thread Ivan Solovev
4331 B From: Interest on behalf of Alexander Dyagilev Sent: Saturday, September 18, 2021 5:13 PM To: Qt Interest Subject: Re: [Interest] qt6: any QtAndroid::androidActivity replacement? For those who can be interested. Here is my current qt5androidcompat.h file to ease the support of bo