mirror of
https://github.com/Lime3DS/Lime3DS.git
synced 2024-11-23 01:59:22 +01:00
Android: Update activity-ktx from 1.8.2 to 1.9.2
This commit is contained in:
parent
3f28efd8b2
commit
e6636469d8
@ -162,7 +162,7 @@ android {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation("androidx.activity:activity-ktx:1.8.2")
|
||||
implementation("androidx.activity:activity-ktx:1.9.2")
|
||||
implementation("androidx.appcompat:appcompat:1.7.0")
|
||||
implementation("androidx.core:core-splashscreen:1.0.1")
|
||||
implementation("androidx.documentfile:documentfile:1.0.1")
|
||||
|
@ -159,7 +159,7 @@ class HomeSettingsFragment : Fragment() {
|
||||
R.string.select_lime3ds_user_folder,
|
||||
R.string.select_lime3ds_user_folder_home_description,
|
||||
R.drawable.ic_home,
|
||||
{ mainActivity.openLime3DSDirectory.launch(null) },
|
||||
{ mainActivity?.openLime3DSDirectory?.launch(null) },
|
||||
details = homeViewModel.userDir
|
||||
),
|
||||
HomeSetting(
|
||||
|
@ -60,7 +60,7 @@ class Lime3DSDirectoryDialogFragment : DialogFragment() {
|
||||
}
|
||||
.setNegativeButton(android.R.string.cancel) { _: DialogInterface?, _: Int ->
|
||||
if (!PermissionsHandler.hasWriteAccess(requireContext())) {
|
||||
(requireActivity() as MainActivity).openLime3DSDirectory.launch(null)
|
||||
(requireActivity() as MainActivity)?.openLime3DSDirectory?.launch(null)
|
||||
}
|
||||
}
|
||||
.show()
|
||||
|
@ -26,7 +26,7 @@ class SelectUserDirectoryDialogFragment : DialogFragment() {
|
||||
.setTitle(R.string.select_lime3ds_user_folder)
|
||||
.setMessage(R.string.cannot_skip_directory_description)
|
||||
.setPositiveButton(android.R.string.ok) { _: DialogInterface, _: Int ->
|
||||
mainActivity.openLime3DSDirectory.launch(null)
|
||||
mainActivity?.openLime3DSDirectory?.launch(null)
|
||||
}
|
||||
.show()
|
||||
}
|
||||
|
@ -300,7 +300,7 @@ class MainActivity : AppCompatActivity(), ThemeProvider {
|
||||
windowInsets
|
||||
}
|
||||
|
||||
val openLime3DSDirectory = registerForActivityResult<Uri, Uri>(
|
||||
val openLime3DSDirectory = registerForActivityResult(
|
||||
ActivityResultContracts.OpenDocumentTree()
|
||||
) { result: Uri? ->
|
||||
if (result == null) {
|
||||
|
Loading…
Reference in New Issue
Block a user