Updated on 2026-08-14

This commit is contained in:
Tangem 2019-09-18 11:17:40 +03:00
parent d9fa49579e
commit e22d7bd9d7
17 changed files with 229 additions and 183 deletions

View file

@ -333,30 +333,30 @@ class VerifyCardFragment : BaseFragment(), NavigationResultListener, NfcAdapter.
var features = ""
features += if (ctx.card!!.allowSwapPIN()!! && ctx.card!!.allowSwapPIN2()!!) {
"Allows change PIN1 and PIN2\n"
getString(R.string.details_both_pins_can_be_changed)
} else if (ctx.card!!.allowSwapPIN()!!) {
"Allows change PIN1\n"
getString(R.string.details_pin1_can_be_changed)
} else if (ctx.card!!.allowSwapPIN2()!!) {
"Allows change PIN2\n"
getString(R.string.details_pin2_can_be_changed)
} else {
"Fixed PIN1 and PIN2\n"
getString(R.string.details_both_pins_fixed)
}
if (ctx.card!!.needCVC()!!)
features += "Requires CVC\n"
features += getString(R.string.details_required_cvc)
if (ctx.card!!.supportDynamicNDEF()!!) {
features += "Dynamic NDEF for iOS\n"
features += getString(R.string.details_dynamic_ndef)
} else if (ctx.card!!.supportNDEF()!!)
features += "NDEF\n"
features += getString(R.string.details_ndef)
if (ctx.card!!.supportBlock()!!)
features += "Blockable\n"
features += getString(R.string.details_blockable)
if (ctx.card!!.supportOnlyOneCommandAtTime()!!)
features += "Atomic command mode"
features += getString(R.string.details_atomic_commmands)
if (features.endsWith("\n"))
features = features.substring(0, features.length - 1)

View file

@ -627,9 +627,9 @@ class LoadedWalletFragment : BaseFragment(), NavigationResultListener, NfcAdapte
val validator = BalanceValidator()
// TODO why attest=false?
validator.check(ctx, false)
context?.let { ContextCompat.getColor(it, validator.color) }?.let { tvBalanceLine1.setTextColor(it) }
tvBalanceLine1.text = validator.firstLine
tvBalanceLine2.text = validator.getSecondLine(false)
context?.let { ContextCompat.getColor(it, validator.color) }?.let { tvBalanceLine1?.setTextColor(it) }
tvBalanceLine1?.text = getString(validator.firstLine)
tvBalanceLine2?.text = getString(validator.getSecondLine(false))
}
val engine = CoinEngineFactory.create(ctx)