mirror of
https://github.com/meshtastic/Meshtastic-Android.git
synced 2026-04-20 22:23:37 +00:00
Simplified some logic
This commit is contained in:
parent
40b0cbad06
commit
cc295d0fb3
1 changed files with 11 additions and 9 deletions
|
|
@ -622,17 +622,19 @@ class MapFragment : ScreenFragment("Map"), Logging {
|
|||
// Save URI
|
||||
userStyleURI = uri.text.toString()
|
||||
uri.setText("") // clear text
|
||||
|
||||
downloadOfflineRegion(userStyleURI!!)
|
||||
dialog.dismiss()
|
||||
} else {
|
||||
Toast.makeText(
|
||||
requireContext(),
|
||||
"Style URI cannot be empty",
|
||||
Toast.LENGTH_SHORT
|
||||
).show()
|
||||
}
|
||||
}
|
||||
if (uri.isVisible && (this.userStyleURI != null)) {
|
||||
downloadOfflineRegion(userStyleURI!!)
|
||||
dialog.dismiss()
|
||||
} else {
|
||||
Toast.makeText(
|
||||
requireContext(),
|
||||
"Style URI cannot be empty",
|
||||
Toast.LENGTH_SHORT
|
||||
).show()
|
||||
downloadOfflineRegion()
|
||||
dialog.dismiss()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue