Android: Customizing recent apps thumbnail (screenshot by default) -
the app i'm working on shows sensitive information must not shown on "recent tasks" screen when stopping app pressing home button.
i'd blur sensitive data in screenshot or show app logo instead.
i aware of following approaches don't fit requirements:
- setting actvitie's
android:excludefromrecents
true in manifiest prevents app being shown @ in recent tasks. disrupt user experience. - using
flag_secure
results in blank card on recents tasks screen. (how prevent android taking screenshot when app goes background?) don't blank screen. however, i'll stick solution if there no workaround. - overriding
oncreatethumbnail
seems ideal solution but, unfortunately, doesn't work it's not invoked os :( (https://code.google.com/p/android/issues/detail?id=29370)
and there workarounds tried out didn't work hoped:
- start new activity shows app logo in
onpause
it's screenshot shown instead of actual activitie's one. new activity takes long open , disrupts user experience. - set activitie's content view image of app logo in
onpause
. seemed great solution me. unfortunately, screenshot recent tasks screen taken @ unspecified time. during testing app logo appears before app closed when pressing 'home' resulting screenshot shows activity short time before that. - removing sensitive data widgets (e.g.
textview.settext("")
) has same problem of screenshot timing mentioned.
any alternative ideas or solutions listed workarounds?
Comments
Post a Comment