Hi Nick, i'm developing an app which sends GPS coordinates over TCP protocol. the main idea is: after installing an app it must be active (autorun). Sorry for my GOOD English
There is no such thing as autorun or minimizing on Android afaik. All you can do is to have the user start it and then put your code into a service activity( that will not be suspended ) and then update your application when it is brought again into view :-)
This can't be right. He must have misunderstood the question OR the question must have been put forward with an awkard wording. Or possibly the answer must have been misunderstood.
Out of the box, Delphi has support for activities configured as applications. This doesn't mean you cannot create other types of activities, but that (currently) they are not officially supported, you would have a hard time debugging, and so on. Looking forward for someone posting a demo, though...
I don't think so, because there really isn't the concept in Android. Why do you feel the need to minimize your app?
ReplyDeleteHi Nick,
ReplyDeletei'm developing an app which sends GPS coordinates over TCP protocol. the main idea is: after installing an app it must be active (autorun). Sorry for my GOOD English
Hi!
ReplyDeleteThere is no such thing as autorun or minimizing on Android afaik.
All you can do is to have the user start it and then put your code into a service activity( that will not be suspended ) and then update your application when it is brought again into view :-)
We can't do services with delphi :-( or there's a workaround?
ReplyDeleteI was talking in Android terms. If services can't be made that is a massive limitation... are you sure?
ReplyDeleteThe preferred way is to run an intent service thread.
ReplyDeletehttp://developer.android.com/training/run-background-service/index.html
IMO, Delphi could use a template app, or at least a demo app, for that.
during italian presentation, answer by Marco Cantù to "service" was: "delphi is designed to create only visible application" :(
ReplyDeleteReally!?
ReplyDeleteThis can't be right. He must have misunderstood the question OR the question must have been put forward with an awkard wording. Or possibly the answer must have been misunderstood.
ReplyDeleteno, question was clear :( i hope maybe in the future they make us a surprise!! :)
ReplyDeleteHi Diego,
ReplyDeleteare you sure he meant something like this ... http://developer.android.com/guide/components/services.html ... is not possible?
I ask because there is a TJIntentService class in the Androidapi.JNI.App unit.
Does anybody know how to bind the event procedures? Is there something like this ... http://www.gtro.com/delphi/comevents_e.php ... in JNI?
I can't exclude a workaround , i hope i can ask directly to cantu' soon!
ReplyDeleteDiego Rigoni it will be great.
ReplyDeletePerhabs we can get Marco Cantù to have a look at this thread?
ReplyDeleteOut of the box, Delphi has support for activities configured as applications. This doesn't mean you cannot create other types of activities, but that (currently) they are not officially supported, you would have a hard time debugging, and so on. Looking forward for someone posting a demo, though...
ReplyDeleteGreat news. Thanks for posting. Looking forward to find some time to try this. Or to read about it on the blog of Brian Long :-)
ReplyDelete