Skip to content

Commit

Permalink
Update libpdfviewer & Fix FFmpeg build & onBackPressed deprecation in…
Browse files Browse the repository at this point in the history
… AddVolumeActivity
  • Loading branch information
hardcore-sushi committed Oct 8, 2022
1 parent 545275d commit 25dbcca
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 9 deletions.
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ android {
minSdkVersion 21
//noinspection ExpiredTargetSdkVersion
targetSdkVersion 29
versionCode 28
versionName "2.0.0-alpha1"
versionCode 29
versionName "2.0.0-alpha2"

ndk {
abiFilters "x86", "x86_64", "armeabi-v7a", "arm64-v8a"
Expand Down
1 change: 1 addition & 0 deletions app/ffmpeg/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ else
--disable-sndio \
--disable-schannel \
--disable-securetransport \
--disable-vulkan \
--disable-xlib \
--disable-zlib \
--disable-cuvid \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package sushi.hardcore.droidfs.add_volume

import android.os.Bundle
import android.view.MenuItem
import androidx.activity.addCallback
import sushi.hardcore.droidfs.*
import sushi.hardcore.droidfs.content_providers.RestrictedFileProvider
import sushi.hardcore.droidfs.databinding.ActivityAddVolumeBinding
Expand Down Expand Up @@ -38,6 +39,12 @@ class AddVolumeActivity: BaseActivity() {
)
.commit()
}
onBackPressedDispatcher.addCallback(this) {
setResult(RESULT_USER_BACK)
shouldCloseVolume = false
isEnabled = false
onBackPressedDispatcher.onBackPressed()
}
}

override fun onOptionsItemSelected(item: MenuItem): Boolean {
Expand All @@ -53,12 +60,6 @@ class AddVolumeActivity: BaseActivity() {
return super.onOptionsItemSelected(item)
}

override fun onBackPressed() {
setResult(RESULT_USER_BACK)
shouldCloseVolume = false
super.onBackPressed()
}

fun onFragmentLoaded(selectPathFragment: Boolean) {
title = getString(
if (selectPathFragment) {
Expand Down
2 changes: 1 addition & 1 deletion libpdfviewer
Submodule libpdfviewer updated from 06e54d to 276600

0 comments on commit 25dbcca

Please sign in to comment.