File tree Expand file tree Collapse file tree
app/src/main/java/app/morphe/manager/ui/screen Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -94,14 +94,16 @@ fun HomeScreen(
9494 }
9595
9696 // Initialize launchers
97+ // GetContent is used instead of OpenDocument so that third-party file managers
98+ // appear as available options in Android's picker
9799 val openApkPicker = rememberLauncherForActivityResult(
98- contract = ActivityResultContracts .OpenDocument ()
100+ contract = ActivityResultContracts .GetContent ()
99101 ) { uri ->
100102 uri?.let { homeViewModel.handleApkSelection(it) }
101103 }
102104
103105 val openBundlePicker = rememberLauncherForActivityResult(
104- contract = ActivityResultContracts .OpenDocument ()
106+ contract = ActivityResultContracts .GetContent ()
105107 ) { uri ->
106108 uri?.let {
107109 homeViewModel.selectedBundleUri = it
@@ -159,8 +161,8 @@ fun HomeScreen(
159161 // All dialogs
160162 HomeDialogs (
161163 homeViewModel = homeViewModel,
162- storagePickerLauncher = { openApkPicker.launch(APK_FILE_MIME_TYPES ) },
163- openBundlePicker = { openBundlePicker.launch(MPP_FILE_MIME_TYPES ) }
164+ storagePickerLauncher = { openApkPicker.launch(" */* " ) },
165+ openBundlePicker = { openBundlePicker.launch(" */* " ) }
164166 )
165167
166168 // Pre-patching installer selection dialog for root-capable devices.
You can’t perform that action at this time.
0 commit comments