@@ -36,13 +36,41 @@ QString TransactionDesc::FormatTxStatus(const interfaces::WalletTxStatus& status
36
36
{
37
37
int depth = status.depth_in_main_chain ;
38
38
if (depth < 0 ) {
39
+ /* : Text explaining the current status of a transaction, shown in the
40
+ status field of the details window for this transaction. This status
41
+ represents an unconfirmed transaction that conflicts with a confirmed
42
+ transaction. */
39
43
return tr (" conflicted with a transaction with %1 confirmations" ).arg (-depth);
40
44
} else if (depth == 0 ) {
41
- const QString abandoned{status.is_abandoned ? QLatin1String (" , " ) + tr (" abandoned" ) : QString ()};
42
- return tr (" 0/unconfirmed, %1" ).arg (inMempool ? tr (" in memory pool" ) : tr (" not in memory pool" )) + abandoned;
45
+ QString s;
46
+ if (inMempool) {
47
+ /* : Text explaining the current status of a transaction, shown in the
48
+ status field of the details window for this transaction. This status
49
+ represents an unconfirmed transaction that is in the memory pool. */
50
+ s = tr (" 0/unconfirmed, in memory pool" );
51
+ } else {
52
+ /* : Text explaining the current status of a transaction, shown in the
53
+ status field of the details window for this transaction. This status
54
+ represents an unconfirmed transaction that is not in the memory pool. */
55
+ s = tr (" 0/unconfirmed, not in memory pool" );
56
+ }
57
+ if (status.is_abandoned ) {
58
+ /* : Text explaining the current status of a transaction, shown in the
59
+ status field of the details window for this transaction. This
60
+ status represents an abandoned transaction. */
61
+ s += QLatin1String (" , " ) + tr (" abandoned" );
62
+ }
63
+ return s;
43
64
} else if (depth < 6 ) {
65
+ /* : Text explaining the current status of a transaction, shown in the
66
+ status field of the details window for this transaction. This
67
+ status represents a transaction confirmed in at least one block,
68
+ but less than 6 blocks. */
44
69
return tr (" %1/unconfirmed" ).arg (depth);
45
70
} else {
71
+ /* : Text explaining the current status of a transaction, shown in the
72
+ status field of the details window for this transaction. This status
73
+ represents a transaction confirmed in 6 or more blocks. */
46
74
return tr (" %1 confirmations" ).arg (depth);
47
75
}
48
76
}
0 commit comments