android - how to load an application into RAM, without launching that app -
i want load group of applications ram, without launching them. when loading applications ram, user should unaware of them.
i tried following code:
intent launchintent = mcontext.getpackagemanager().getlaunchintentforpackage(appname); launchintent.setflags(intent.flag_activity_new_task); launchintent.setflags(intent.flag_activity_multiple_task); mcontext.startactivity(launchintent);
above code starting application , brought application front. don't want application brought front.
you can via service
. please read on android
documentation.
service/activity/broadcastreceivers
launched intents
. activity
shown in foreground. service
run in background until stopped android os
or developer. broadcastreceiver
run max 10 seconds , stopped.
Comments
Post a Comment