xlab/android-go

Android Service

ohenepee opened this issue · 6 comments

Is there anyway by which one can build and interact with an Android Service or IntentService? So long-running background apps can be built without the Android Runtime killing and restarting at will.

xlab commented

@ohenepee

Sorry, I completely missed this issue. I was working on JNI bindings to the Android SDK, but was burdened with other work.

You can see an example of interacting with Android services using Binder there:
https://github.com/xlab/android-go/blob/master/android/jni_util.go#L13

It has all required helpers and methods, but I cannot share additional info as didn't try such thing by myself. There are some SO answers available though http://stackoverflow.com/a/14277133

cool.

this is exactly why i also came here. I want to run thing sin golang as a background services, but then have apps (written in golang and QT) communicating over android IPC which is called AIDL.

The example you linked too triggers the virtual keyboard. Exactly what we need for opengl / vulkan based apps :)
Nice...

For the iOS project have you found a way also to do it ?
A iOS friend told me its the responder interface to make it work btw but have not had a chance to try.

Also whilst on the topic of text we are going to need cut and paste functionality too. Have not looked into how / if we can invoke the native cut and paste GUI controls yet...

Would be happy to help try...

xlab commented

Unfortunately all the iOS interaction goes through C shims for obj-c logic. I would like to find or make a C API project for some minimal set of iOS features such as clipboard access or keyboard toggling, then generate bindings for it.

glad you said that. Thats exactly what i want to do too.
I was thinking about it. Its likly that the QT code uses allot of those same IOS API's since they are opengl based too. Might have a look into it.

i really think that this is huge, and love the work your doing..