+40
−0
Loading
Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more
The AppSnapshotController is response for transition analysis, so TaskSnapshotController and ActivitySnapshotController does not need to do duplicate analysis. Also, it should be easier to do test by de-couple the "transition-analysiser" and "transition-handler". And for the basic implementation of Activity snapshot controller: 1. Record and/or remove an activity snapshot when an activity transition happen. 2. Delete and/or load an activity snapshot from disk to cache when a task transition happen. 3. Only keep one snapshot for the visible task in the cache. 4. This feature is disabled on Low Ram device. 5. Persisted snapshot file will be removed when activity removed. 6. All persisted files for a user will be removed while first access. 7. Purge persisted files on disk when persited file exceed a maximum count. 8. Works on multi-user environment. Bug: 259497289 Test: atest TransitionTests ActivitySnapshotControllerTests\ AppSnapshotControllerTests TaskSnapshotControllerTest Change-Id: I4fc0ca96c748c6123ffabcab9c6b03b7057ac840