WAI
Status Update
Comments
ad...@google.com <ad...@google.com> #2
We have passed this to the development team and will update this issue with more information as it becomes available.
ha...@google.com <ha...@google.com> #3
Foreground services can't be allowed to start activities. Because we have Context.startForegroundService(), an app can at any point start a foreground service, at which point it could then start an activity, basically removing the restriction on starting activities.
Also having a foreground service is not enough for the user to be aware it could start an activity -- normally they may (hopefully) see an icon for it in the status bar, but an app only needs to have a foreground service running long enough for it to call startActivity(), so it would be easy to construct something that the user would basically never see.
Also having a foreground service is not enough for the user to be aware it could start an activity -- normally they may (hopefully) see an icon for it in the status bar, but an app only needs to have a foreground service running long enough for it to call startActivity(), so it would be easy to construct something that the user would basically never see.
lb...@gmail.com <lb...@gmail.com> #4
@3 Guys there are ways to overcome this without ruining apps.
If an app started an Activity via a foreground service, you can set rules about this behavior, without breaking the app.
For example, you can force the service to keep showing a notification (or show a notification of the OS) for as long as the Activity is shown.
There is no need to have a full list of special cases.
As long as the user know which app did it, why not allow it?
If an app started an Activity via a foreground service, you can set rules about this behavior, without breaking the app.
For example, you can force the service to keep showing a notification (or show a notification of the OS) for as long as the Activity is shown.
There is no need to have a full list of special cases.
As long as the user know which app did it, why not allow it?
Description
I see it mentions that foreground services won't be able to start an Activity.
I think they should, and that's because it's very visible to the user which app has done it, compared to other cases on the list, which the user will have no idea which app has done it.
I request that foreground services will be allowed, so that legitimate usages will not be harmed.
For example, if you know WhatsApp, you can see that it had a feature on the settings, under "Notifications", called "popup notification".
On older Android versions, it was possible that each time someone sends you a message, you will get a dialog shown to you, making it easy for users to read it all and reply right away.
If you try to enable it on Q beta 5, you will notice it says it's not available anymore.
Please, together with my suggestion that makes the OS more clear about which app showed the Activity, this could work fine:
So users will always be able to detect which app has shown the Activity, and legitimate apps won't be harmed by this change either.
As for why WhatsApp has this feature, it's probably for helping users from IOS adjust to how it works on Android.
Attached video of how Whatsapp behaves before and from Q beta 5.