Skip to content

Commit

Permalink
Added pending step
Browse files Browse the repository at this point in the history
  • Loading branch information
Dirk Jäckel committed Aug 31, 2023
1 parent 8d2866e commit 9fa370a
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,9 @@ class TxConfirmationsView @JvmOverloads constructor(
TransactionStatus.FAILED -> {
addExecutionStep(TxExecutionStep.Type.FAILED)
}
TransactionStatus.PENDING -> {
addExecutionStep(TxExecutionStep.Type.PENDING)
}
}
}

Expand Down Expand Up @@ -241,7 +244,8 @@ class TxConfirmationsView @JvmOverloads constructor(
EXECUTE_WAITING,
EXECUTE_READY,
EXECUTE_DONE,
REJECTION_CREATED
REJECTION_CREATED,
PENDING
}

private val binding by lazy { ViewTxConfirmationsExecutionStepBinding.inflate(LayoutInflater.from(context), this) }
Expand Down Expand Up @@ -297,6 +301,11 @@ class TxConfirmationsView @JvmOverloads constructor(
stepTitle.text = resources.getString(R.string.tx_confirmations_rejection_created)
stepTitle.setTextColor(ContextCompat.getColor(context, R.color.error))
}
Type.PENDING -> {
stepIcon.setImageResource(R.drawable.ic_tx_confirmations_execute_ready_16dp)
stepTitle.text = resources.getString(R.string.tx_confirmations_pending)
stepTitle.setTextColor(ContextCompat.getColor(context, R.color.primary))
}
}
}
}
Expand Down
1 change: 1 addition & 0 deletions app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -466,6 +466,7 @@
<string name="tx_confirmations_execute_waiting">Execute (%1$d more confirmation needed)</string>
<string name="tx_confirmations_executed">Executed</string>
<string name="tx_confirmations_rejection_created">On-chain rejection created</string>
<string name="tx_confirmations_pending">Pending</string>

<string name="signing_owner_add_key">Add owner key</string>
<string name="signing_owner_import_existing_title">Import existing owner key</string>
Expand Down

0 comments on commit 9fa370a

Please sign in to comment.