Unsolved Use qt/qml widget as android.view.View
-
I need to return android.view.View in java code, that will be contain Qt/qml item, so i thought that i will return QtActivity, but it extends android.app.Activity and not extends android.view.View.
So, how can i create android.view.View with Qt/qml widget?
Links:
https://developer.android.com/reference/android/view/View.html
https://developer.android.com/reference/android/app/Activity.html -
I stil have hope that someone will help me.
But i've found theoretically working way to do that(show qt/qml as android.view.View):
implement onDraw(): that will get bitmap from cpp code.
in cpp code get bitmap from application window grabWindow().
So it will show qt/qml window as it is.But there is need to send touch events to it.
-
may be to implement touch events in this case i need to use https://doc.qt.io/qt-5/qtest-qtoucheventsequence.html to convert android touch events to qt touch events, but hope that already done by qt extras and i just didn't find it.
-
Wow, thanks for your links. Really helpful.
-
@Tusovshik are you trying to do the same thing?
-
have you already solve this ? i'm also looking how to do this .
I believe QuickItem is extended android.view.View
-
@jhayar please start a new thread instead of reviving 7 year old ones.