Simple showcase for Android FileProvider use.
As of Android 7.0 ,due to the File System permission changes
attempts to pass a file:// URI trigger a FileUriExposedException.
Quote from Changes in nougat
- Server
- Save bimap to sd card (please grant storage permission)
- Generate Uri with FileProvider
- Send it to another App via Intent(startActivityForResult)
- Client
- Grab the Intent and read bitmap from contentProvider
- Client set bitmap to imageView