I have a main activity in my app. This activity creates two other activities (at different times). One is a settings activity and the other is a custom activity.
Now my problem is when i am in the settings activity and i press the back button, it returns to the main activity. Great just like it should. But now when i am in my custom activity and i press the back button the entire app closes?? It does not return to the main activity like it should.
I am not sure why this is, as the way i instantiate the two classes is the same and the manifest file is the same for both activities.
Code to call the activities:
Intent intent = new Intent(this, SettingsActivity.class);
startActivity(intent);
and
Intent intent = new Intent(this, PacketActivity.class);
startActivity(intent);
Manifest file:
<activity
android:name="com.example.tcptester.SettingsActivity"
android:label="@string/title_activity_settings" >
</activity>
<activity
android:name="com.example.tcptester.PacketActivity"
android:label="@string/title_activity_packet">
</activity>
Why could this be so?