TxConfAdv: label dummy outputs

This commit is contained in:
tobtoht
2021-06-28 17:30:08 +02:00
parent 6c3b691ae9
commit cfa96e8126
4 changed files with 11 additions and 10 deletions
+8 -7
View File
@@ -453,20 +453,21 @@ int Utils::maxLength(const QVector<QString> &array) {
return maxLength;
}
QTextCharFormat Utils::addressTextFormat(const SubaddressIndex &index) {
QTextCharFormat Utils::addressTextFormat(const SubaddressIndex &index, quint64 amount) {
QTextCharFormat rec;
if (index.isPrimary()) {
QTextCharFormat rec;
rec.setBackground(QBrush(ColorScheme::YELLOW.asColor(true)));
rec.setToolTip("Wallet change/primary address");
return rec;
}
if (index.isValid()) {
QTextCharFormat rec;
else if (index.isValid()) {
rec.setBackground(QBrush(ColorScheme::GREEN.asColor(true)));
rec.setToolTip("Wallet receive address");
return rec;
}
return QTextCharFormat();
else if (amount == 0) {
rec.setBackground(QBrush(ColorScheme::GRAY.asColor(true)));
rec.setToolTip("Dummy output (Min. 2 outs consensus rule)");
}
return rec;
}
bool Utils::isTorsocks() {
+1 -1
View File
@@ -75,7 +75,7 @@ public:
static QString amountToCurrencyString(double amount, const QString &currencyCode);
static int maxLength(const QVector<QString> &array);
static QMap<QString, QLocale> localeCache;
static QTextCharFormat addressTextFormat(const SubaddressIndex &index);
static QTextCharFormat addressTextFormat(const SubaddressIndex &index, quint64 amount);
static bool isTorsocks();
static QString defaultWalletDir();