Login and getting file from Google Drive or DropBox by using Qt/QML in Android and iOS
I am developing app for Android and iOS by using QML/Qt 5.9.1. We want to login the Google Drive and download and upload some file. Of course, we must can select file from my App. Hence, I am trying to use the 3rd part library. Hence, my first thing is to find the sample code for login by using Qt. I follow the below line with two article.
I can get login page from browser when I process the QOAuth2AuthorizationCodeFlow part in my Qt code. I think it want to use REST to get message from Google's api as below link.
I develop app for mobile phone but I must login Google Drive by using the "browser". I think it is weird. By the way, in the above link, there no other code for getting file list from Google Drive. I got stuck here.
Hence, I trying to study using the native code to implement this by using mobile api without web's api. The idea is to implement the whole thing in native code.
And using JNI or other method to passing message from the native code to Qt. But it seem pretty complex and I find I can't run the Google's sample code successfully in my red-mi note 4. I can't login Google Drive and I alway in the select account page on the sample code as below link.
I am study how to use DropBox now. I can get workable sample code from below link.
I can login, upload, download and remove from the sample code. But the problem is it still using "browser" to login account. And I must copy the pin code and paste the pin code to my app for finished the OAuth. It is not friendly and it is hard to copy the pin code from my mobile phone. By the way, I must paste the pin code for login every time when I open the app.
Does it possible to login in my app without the "browser" by using REST?
Does it possible not re-paste the pin code to my app every time?