I have 3 actionbar tabs at the top of my main activity, and a fragments for each tab. I have a few questions regarding such a design and how to open new activities from it.
I have a button in my first tab fragment that I need to open a new activity, but I want the tabs to remain. Here is an image to demonstrate:
If you are on fragment 1 and you press the button to open the new activity, the back button should simply return you to fragment 1. However, if you are on fragment 1, you press the button to go to the new activity and then navigate to a different tab, pressing the back button should do nothing. I hope this makes sense. What is the best way to achieve this?