Continuing to explore the new pre-builds of Android 12 for developers, enthusiasts from the XDA-Developers portal discovered a previously unknown feature – a full-fledged system-wide shopping cart, which is available to all applications (if their developers want it) and is displayed to the user in the settings. It’s surprising that Google decided to implement this option just now, since many other operating systems have it for a long time – for example, Microsoft implemented it in Windows 95.
With the release of Android 11, the developers introduced Scoped Storage, an approach that allocates an isolated piece of storage to each application. Some special applications that need full access to the file system can still request the appropriate permission (for example, file managers), but starting with this version of the operating system, the vast majority of ordinary programs are forced to use alternative APIs to add, open, edit and delete files in the store. One of these is the MediaStore API. In fact, this interface was available before, but in Android 11 it got a delete function with the ability to recover (move files to the trash).
Now the developers are working to bring the system-wide recycle bin to Android 12 – at the moment, files temporarily deleted by applications are stored in the same directories where they were located, only with the prefix “.” (this prefix makes files hidden to standard file managers). Enthusiasts with XDA-Developers managed to activate the system-wide basket – it is displayed in the Android settings, in the storage section, and shows how much space is occupied by deleted files that can be restored. At the moment, the user can only empty the trash, but with the release of Android 12, perhaps the functionality will expand.
Dobra Corporation has been testing a similar option in its proprietary Files by Google file manager for a long time, and in the application, the Recycle Bin section allows not only viewing deleted files, but also selectively interacting with them: permanently delete or restore. It is logical to assume that something similar will appear in Android 12. However, by the time the update is released, the function may not appear if Google has any problems with its implementation.
One catch is that applications must use the MediaStore API to access the system-wide recycle bin. If the developers of specific programs do not want to work with this interface, their utilities will either permanently delete files right away, or use their own recycle bins.