user1175011
user1175011

Reputation:

How to avoid having my app shown in the list of recently used apps

On Ice Cream Sandwich the user can see a list of the recently used applications with a screenshot of the the last status of the UI. I'm working on an application that shows confidential information that should not be kept in memory in any way. Is there a way to disable that feature?

Upvotes: 9

Views: 2841

Answers (2)

Vinay Patil
Vinay Patil

Reputation: 189

You can disable it by adding android:excludeFromRecents="true" to all activities in your AndroidManifest.xml application manifest. Make sure to add it to all of them: if you only add it to one or some, your app won't always be excluded from the list of recently used apps.

Upvotes: 3

Jens
Jens

Reputation: 17087

Have you tried adding android:excludeFromRecents="true" to the activity in your AndroidManifest.xml?

    <activity
        android:label="@string/your_app_name_goes_here"
        android:excludeFromRecents="true"
        android:name=".SomeActivityNameGoesHere" >
        <intent-filter >
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

Upvotes: 12

Related Questions