Start work in fragment

I want to start working in a fragment, and the action will be like any other installed applications. eg. Email address.

I get the intent of this application from the PackageManager, now I want to start this activity in my separate fragment. Whenever I use startActivityFromFragment , the application runs in full screen, but I want to start this activity, limited only by this fragment.

What should I do?

+4
source share
1 answer

Drop the idea, because it makes no sense, and I don’t see that it can be done anyway.

For example, if you have a layout with two panels and you want to call the Contacts application in the right fragment, which itself uses a layout with two panels, and also using the application panel, how do you expect it to look? This is a contact application that makes a call to setContentView and decides how the layout itself, and not your application. If I am mistaken in what you mean, and this is your activity, then, of course, you can create a fragment from it and load it into the desired representation.

+3
source

All Articles