- Use white colored status symbol if account's registration has not been activated.

- Added info about accounts' status symbols to About page.
This commit is contained in:
Juha Heinanen
2020-02-21 02:58:49 +02:00
parent b1344642c7
commit 293c7ec0f0
5 changed files with 13 additions and 4 deletions
@@ -298,7 +298,7 @@ class AccountActivity : AppCompatActivity() {
} else {
if (acc.regint != 0) {
Api.ua_unregister(ua.uap)
UserAgent.updateStatus(ua, R.drawable.dot_yellow)
UserAgent.updateStatus(ua, R.drawable.dot_white)
newRegint = 0
}
}
@@ -51,7 +51,7 @@ class AccountsActivity : AppCompatActivity() {
newAorView.setText("")
newAorView.hint = getString(R.string.user_domain)
newAorView.clearFocus()
UserAgent.add(ua, R.drawable.dot_yellow)
UserAgent.add(ua, R.drawable.dot_white)
generateAccounts()
alAdapter.notifyDataSetChanged()
saveAccounts()
@@ -464,7 +464,10 @@ class BaresipService: Service() {
status.add(R.drawable.dot_green)
} else {
Log.d(LOG_TAG, "Ua ${ua.account.aor} is NOT registered")
status.add(R.drawable.dot_yellow)
if (ua.account.regint == 0)
status.add(R.drawable.dot_white)
else
status.add(R.drawable.dot_yellow)
}
val intent = Intent("service event")
intent.putExtra("event", "ua added")
@@ -494,7 +497,7 @@ class BaresipService: Service() {
}
"registered" -> {
if (ua.account.regint == 0)
status[account_index] = R.drawable.dot_yellow
status[account_index] = R.drawable.dot_white
else
status[account_index] = R.drawable.dot_green
ua.registrationFailed = false