mirror of
https://github.com/FossifyOrg/Gallery.git
synced 2024-11-30 08:18:00 +01:00
fix saving rotated images on the internal storage
This commit is contained in:
parent
28e1d77f1b
commit
4efdb1a47a
1 changed files with 2 additions and 1 deletions
|
@ -541,7 +541,8 @@ class ViewPagerActivity : SimpleActivity(), ViewPager.OnPageChangeListener, View
|
|||
var inputStream: InputStream? = null
|
||||
var out: OutputStream? = null
|
||||
try {
|
||||
out = getFileOutputStreamSync(destination.absolutePath, source.getMimeType(), getFileDocument(destination.parent))
|
||||
val fileDocument = if (isPathOnSD(destination.absolutePath)) getFileDocument(destination.parent) else null
|
||||
out = getFileOutputStreamSync(destination.absolutePath, source.getMimeType(), fileDocument)
|
||||
inputStream = FileInputStream(source)
|
||||
inputStream.copyTo(out!!)
|
||||
} finally {
|
||||
|
|
Loading…
Reference in a new issue