-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Doubled app after installing #4262
Comments
We have to try to handle which activities are going to be shown in the Recents Screen. To prevent this, We must use android:excludeFromRecents manually so that the system does not open activities in Recent automatically. To give more context: Normally, we let the system define how our tasks and activities are represented in the Recents screen. We don't need to modify this behavior. However, your app can determine how and when activities appear in the Recents screen. In our case, I don't see any behavior that directly handles the SplashActivity, which is the screen that remains open in Recent Apps. Following the documentation, the system is doing it internally. By default, a document task automatically exits from the Recents screen when its activity finishes. It is what is happening with SplashActivity. But this solution does not work when the application is installed from scratch. Since three screens appear in Recent Apps SplashScreen, FileDisplayActivity and LoginActivity. So at this point we also have to delete this task manually. Below I show you the following scenarios: 1. Without changes:
2. With SplashScreen exclude from Recents screen:
3. With SplashScreen exclude from Recents screen and FileDisplayActivity excludes too in SplashScreen:
The third option will be taken as a solution. |
We are facing a problem with task management in the Recents Screen. By adding This method did not work. Similarly, the The use of the Documentation: https://developer.android.com/guide/components/activities/recents |
Hi @hannesa2, we would like to know if you have any ideas regarding this issue? We were trying several stuff as you can see in previous comments, but we didn't get to a valid solution. Any suggestions are welcome 😄 |
Can you reproduce it ? I didn't investigated. With this https://github.com/owncloud/android/blob/master/owncloudApp/src/main/AndroidManifest.xml#L82 you see an icon in launcher, and having more then one, you would see more. |
Open the apk directly in Android Studio and look into the given manifest .... |
Hi @hannesa2, yes, we can reproduce it, just as you can see in the video of the first comment.
It's not that we have several icons for the app, the title of the issue may be misleading. The problem here is that when the app is opened (with the single icon we have for it), we have like 2 instances of the app because 2 different activities appear in the Recents screen, and we expect just 1. |
As clue, we think this one could be a solution: #3391, but it has more issues to take in account (MDM regards). |
Hi @hannesa2, as I commented, there is only a single icon on our side as well, so that is NOT the problem. The problem can be seen in the Recents screen (pressing the square button from the device's bottom bar in case of Pixels, as shown in the video in #4262 (comment)), where there are 2 different elements for ownCloud, when there should be just 1. |
I have try to implement |
Steps to reproduce
Actual behaviour
App is doubled:
Screen_recording_20231215_085238.mp4
only happens if there is no accounts
Expected behaviour
app only once
Pixel 2, Android 11
Reproducible in v4.1.1 and so on
The text was updated successfully, but these errors were encountered: