show help texts when account activity headings are clicked
This commit is contained in:
@@ -92,7 +92,7 @@ class AccountActivity : AppCompatActivity() {
|
||||
mediaEnc = acc.mediaenc
|
||||
val mediaEncSpinner = findViewById(R.id.mediaEncSpinner) as Spinner
|
||||
val mediaEncKeys = arrayListOf("zrtp", "dtls_srtp", "srtp", "srtp-mand", "")
|
||||
val mediaEncVals = arrayListOf("ZRTP", "DTLS SRTP", "SRTP", "Madatory SRTP", "")
|
||||
val mediaEncVals = arrayListOf("ZRTP", "DTLS SRTP", "SRTP", "Mandatory SRTP", "")
|
||||
val keyIx = mediaEncKeys.indexOf(acc.mediaenc)
|
||||
val keyVal = mediaEncVals.elementAt(keyIx)
|
||||
mediaEncKeys.removeAt(keyIx)
|
||||
@@ -282,6 +282,36 @@ class AccountActivity : AppCompatActivity() {
|
||||
} else return super.onOptionsItemSelected(item)
|
||||
}
|
||||
|
||||
fun onClick(v: View) {
|
||||
Log.d("Baresip", "Account click on $v")
|
||||
when (v) {
|
||||
findViewById(R.id.DisplayNameTitle) -> {
|
||||
Utils.alertView(this, "Display Name", getString(R.string.dispName))
|
||||
}
|
||||
findViewById(R.id.AuthUserTitle) -> {
|
||||
Utils.alertView(this, "Authentication Username",
|
||||
getString(R.string.authUser))
|
||||
}
|
||||
findViewById(R.id.AuthPassTitle) -> {
|
||||
Utils.alertView(this, "Authentication Password",
|
||||
getString(R.string.authPass))
|
||||
}
|
||||
findViewById(R.id.OutboundProxyTitle) -> {
|
||||
Utils.alertView(this, "Outbound Proxies",
|
||||
getString(R.string.obProxies))
|
||||
}
|
||||
findViewById(R.id.RegIntTitle) -> {
|
||||
Utils.alertView(this, "Registration Interval", getString(R.string.regInt))
|
||||
}
|
||||
findViewById(R.id.AudioCodecsTitle) -> {
|
||||
Utils.alertView(this, "Audio Codecs", getString(R.string.auCodecs))
|
||||
}
|
||||
findViewById(R.id.MediaEncTitle) -> {
|
||||
Utils.alertView(this, "Media Encryption", getString(R.string.mediaEnc))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private fun checkDisplayName(dn: String): Boolean {
|
||||
if (dn == "") return true
|
||||
val dnRegex = Regex("^[a-zA-Z]([ ._-]|[a-zA-Z0-9]){1,63}\$")
|
||||
|
||||
Reference in New Issue
Block a user