mirror of
https://github.com/SimpleMobileTools/Simple-Camera.git
synced 2025-02-16 19:30:40 +01:00
update commons to 3.13.9
This commit is contained in:
parent
d02f391ed6
commit
c023445b3b
@ -45,7 +45,7 @@ ext {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation 'com.simplemobiletools:commons:3.8.2'
|
||||
implementation 'com.simplemobiletools:commons:3.13.9'
|
||||
|
||||
debugImplementation "com.squareup.leakcanary:leakcanary-android:$leakCanaryVersion"
|
||||
releaseImplementation "com.squareup.leakcanary:leakcanary-android-no-op:$leakCanaryVersion"
|
||||
|
@ -245,7 +245,8 @@ class MainActivity : SimpleActivity(), PreviewListener, PhotoProcessor.MediaSave
|
||||
|
||||
private fun showLastMediaPreview() {
|
||||
if (mPreviewUri != null) {
|
||||
openFile(mPreviewUri!!, false, BuildConfig.APPLICATION_ID)
|
||||
val path = applicationContext.getRealPathFromURI(mPreviewUri!!) ?: mPreviewUri!!.toString()
|
||||
openPathIntent(path, false, BuildConfig.APPLICATION_ID)
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -155,7 +155,7 @@ class SettingsActivity : SimpleActivity() {
|
||||
settings_save_photos.text = getLastPart(config.savePhotosFolder)
|
||||
settings_save_photos_holder.setOnClickListener {
|
||||
FilePickerDialog(this, config.savePhotosFolder, false, showFAB = true) {
|
||||
handleSAFDialog(File(it)) {
|
||||
handleSAFDialog(it) {
|
||||
config.savePhotosFolder = it
|
||||
settings_save_photos.text = getLastPart(config.savePhotosFolder)
|
||||
}
|
||||
|
@ -48,7 +48,8 @@ class PhotoProcessor(val activity: MainActivity, val uri: Uri?, val currCameraId
|
||||
activity.config.savePhotosFolder = Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DCIM).toString()
|
||||
return ""
|
||||
}
|
||||
var document = activity.getFileDocument(path)
|
||||
|
||||
var document = activity.getDocumentFile(path)
|
||||
document = document?.createFile("", path.substring(path.lastIndexOf('/') + 1))
|
||||
fos = activity.contentResolver.openOutputStream(document?.uri)
|
||||
} else {
|
||||
|
@ -680,7 +680,7 @@ class Preview : ViewGroup, SurfaceHolder.Callback, MediaScannerConnection.OnScan
|
||||
}
|
||||
|
||||
try {
|
||||
var document = mActivity!!.getFileDocument(mCurrVideoPath)
|
||||
var document = mActivity!!.getDocumentFile(mCurrVideoPath)
|
||||
if (document == null) {
|
||||
mActivity!!.toast(R.string.unknown_error_occurred)
|
||||
return false
|
||||
|
Loading…
x
Reference in New Issue
Block a user