Reputation: 75
I was wondering if it's possible in android to embed an application into in another application. In this way you can have control of the embed application and you can add some other functionalities thanks to the parent application.
EDIT : To be more accurate, I would like to have an application (parent application ) which can overlay the content of another application (embed application) without losing control of the parent application.
Thank you,
Upvotes: 1
Views: 1982
Reputation: 29724
You can not specifically embed one app in another. And unless there is a specific inter-application API you have available to you, you cannot control the one app from your parent app either.
However if you just want to be able to view your parent app as some kind of overlay over another app, there are techniques that you might find useful.
It is possible to create an overlay view that can be seen when other apps are in the foreground. This is used by some chat clients, video playback, and task launchers. You can find some info on this method by looking at my answer here:
It is important to realise that in "the old days", a technique like this could be used to steal data from someone's phone. It was possible to receive taps & drags, and then pass them on to the other app.
This was a security hole, and has been fixed. So these days, you can choose if your overlay view should receive the taps or not i.e. if it is interactive, or just shows info.
Because of this, you will not want to cover up any of the "embedded" app with your own UI.
It is not possible any more to receive taps in your app, and pass them through to the other app.
Upvotes: 1
Reputation: 1006819
This is not possible in general. The only thing that comes close is "embedding" an app widget in a home screen.
Upvotes: 1