File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed
presentation/src/main/java/org/cryptomator/presentation/presenter Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -555,16 +555,15 @@ class BrowseFilesPresenter @Inject constructor( //
555555 val cryptomatorApp = activity().application as CryptomatorApp
556556 cryptomatorApp.suspendLock()
557557 }
558- view?.showProgress(ProgressModel .COMPLETED )
559- if (viewFileIntent.resolveActivity(context().packageManager) != null ) {
558+ try {
560559 requestActivityResult(ActivityResultCallbacks .openFileFinished(openFileType), viewFileIntent)
561- } else {
560+ } catch (e : ActivityNotFoundException ) {
562561 view?.showFileTypeNotSupportedDialog(cloudFile)
563562 }
564563 }
565564
566- override fun onError ( e : Throwable ) {
567- super .onError(e )
565+ override fun onFinished ( ) {
566+ view?.showProgress( ProgressModel . COMPLETED )
568567 }
569568 })
570569 }
You can’t perform that action at this time.
0 commit comments