Added non-txt TLE file import (.tle) #15

This commit is contained in:
Arty Bishop committed 2020-09-09 21:13:24 +01:00
1 parent e97cc49e22
commit 15d414f8f8
4 files changed
+16 -16

No files matched your search

@@ -140,8 +140,8 @@ class MainActivity : AppCompatActivity(), TleSourcesDialogFragment.SourcesSubmit
})
viewModel.getUpdateStatus().observe(this, Observer { result ->
when (result) {
is Result.Success -> getString(R.string.update_tle_success).toast(this)
is Result.Error -> getString(R.string.update_failure).toast(this)
is Result.Success -> getString(R.string.import_data_success).toast(this)
is Result.Error -> getString(R.string.import_data_failure).toast(this)
}
})
}
@@ -154,7 +154,7 @@ class MainActivity : AppCompatActivity(), TleSourcesDialogFragment.SourcesSubmit
drawerBinding.drawerBtnTleFile.setOnClickListener {
val openFileIntent = Intent(Intent.ACTION_OPEN_DOCUMENT).apply {
addCategory(Intent.CATEGORY_OPENABLE)
type = "text/*"
type = "*/*"
}
startActivityForResult(openFileIntent, pickFileReqCode)
mainBinding.drawerLayout.closeDrawers()