Skip to content
This repository has been archived by the owner on Jan 10, 2024. It is now read-only.

Commit

Permalink
removed okio and updated gradle zip
Browse files Browse the repository at this point in the history
  • Loading branch information
tobiasjungmann committed Oct 11, 2023
1 parent 095a9e7 commit 7bafe19
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 24 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,10 @@ abstract class ActivityForDownloadingExternal(layoutId: Int) : ProgressActivity<

showLoadingStart()
Flowable.fromCallable { method?.execute(forceDownload) }
.doOnError { errorHandler() }
.onErrorReturnItem(Unit)
.subscribeOn(Schedulers.io())
.toLiveData()
.observe(this, completionHandler)
.doOnError { errorHandler() }
.onErrorReturnItem(Unit)
.subscribeOn(Schedulers.io())
.toLiveData()
.observe(this, completionHandler)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,10 @@ abstract class FragmentForDownloadingExternal(

showLoadingStart()
Flowable.fromCallable { method?.execute(forceDownload) }
.doOnError { errorHandler() }
.onErrorReturnItem(Unit)
.subscribeOn(Schedulers.io())
.toLiveData()
.observe(this, completionHandler)
.doOnError { errorHandler() }
.onErrorReturnItem(Unit)
.subscribeOn(Schedulers.io())
.toLiveData()
.observe(this, completionHandler)
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -116,15 +116,15 @@ class StartupActivity : BaseActivity(R.layout.activity_startup) {

// Start download workers and listen for finalization
val downloadActions = Flowable
.fromCallable(this@StartupActivity::performAllWorkerActions)
.onErrorReturnItem(Unit)
.subscribeOn(Schedulers.io())
.fromCallable(this@StartupActivity::performAllWorkerActions)
.onErrorReturnItem(Unit)
.subscribeOn(Schedulers.io())

runOnUiThread {
downloadActions.toLiveData()
.observe(this@StartupActivity) {
openMainActivityIfInitializationFinished()
}
.observe(this@StartupActivity) {
openMainActivityIfInitializationFinished()
}
}

// Start background service and ensure cards are set
Expand Down Expand Up @@ -160,17 +160,17 @@ class StartupActivity : BaseActivity(R.layout.activity_startup) {
*/
private fun showLocationPermissionRationaleDialog() {
ThemedAlertDialogBuilder(this)
.setMessage(R.string.permission_location_explanation)
.setPositiveButton(R.string.ok) { _, _ ->
requestPermissions(this, PERMISSIONS_LOCATION, REQUEST_LOCATION)
}
.show()
.setMessage(R.string.permission_location_explanation)
.setPositiveButton(R.string.ok) { _, _ ->
requestPermissions(this, PERMISSIONS_LOCATION, REQUEST_LOCATION)
}
.show()
}

override fun onRequestPermissionsResult(
requestCode: Int,
permissions: Array<String>,
grantResults: IntArray
requestCode: Int,
permissions: Array<String>,
grantResults: IntArray
) {
super.onRequestPermissionsResult(requestCode, permissions, grantResults)
openMainActivityIfInitializationFinished()
Expand Down

0 comments on commit 7bafe19

Please sign in to comment.