From c94600a2c89c303ae08d8449b35d019d5e80a8d0 Mon Sep 17 00:00:00 2001 From: Evan Duffield Date: Fri, 26 Dec 2014 15:30:00 -0700 Subject: [PATCH] Added coincontrol darksend rounds colunm from v10 --- src/qt/coincontroldialog.cpp | 15 +++++++++++++-- src/qt/coincontroldialog.h | 1 + src/qt/forms/coincontroldialog.ui | 5 +++++ 3 files changed, 19 insertions(+), 2 deletions(-) diff --git a/src/qt/coincontroldialog.cpp b/src/qt/coincontroldialog.cpp index 27bf714e93..c4c27cec0a 100644 --- a/src/qt/coincontroldialog.cpp +++ b/src/qt/coincontroldialog.cpp @@ -16,6 +16,7 @@ #include "coincontrol.h" #include "main.h" #include "wallet.h" +#include "darksend.h" #include #include @@ -117,8 +118,9 @@ CoinControlDialog::CoinControlDialog(QWidget *parent) : ui->treeWidget->setColumnWidth(COLUMN_CHECKBOX, 84); ui->treeWidget->setColumnWidth(COLUMN_AMOUNT, 100); ui->treeWidget->setColumnWidth(COLUMN_LABEL, 170); - ui->treeWidget->setColumnWidth(COLUMN_ADDRESS, 290); - ui->treeWidget->setColumnWidth(COLUMN_DATE, 110); + ui->treeWidget->setColumnWidth(COLUMN_ADDRESS, 190); + ui->treeWidget->setColumnWidth(COLUMN_DARKSEND_ROUNDS, 120); + ui->treeWidget->setColumnWidth(COLUMN_DATE, 60); ui->treeWidget->setColumnWidth(COLUMN_CONFIRMATIONS, 100); ui->treeWidget->setColumnWidth(COLUMN_PRIORITY, 100); ui->treeWidget->setColumnHidden(COLUMN_TXHASH, true); // store transacton hash in this column, but dont show it @@ -738,6 +740,15 @@ void CoinControlDialog::updateView() itemOutput->setText(COLUMN_DATE, GUIUtil::dateTimeStr(out.tx->GetTxTime())); itemOutput->setText(COLUMN_DATE_INT64, strPad(QString::number(out.tx->GetTxTime()), 20, " ")); + + // ds+ rounds + CTxIn vin = CTxIn(out.tx->GetHash(), out.i); + int rounds = GetInputDarksendRounds(vin); + + if(rounds >= 0) itemOutput->setText(COLUMN_DARKSEND_ROUNDS, strPad(QString::number(rounds), 15, " ")); + else itemOutput->setText(COLUMN_DARKSEND_ROUNDS, strPad(QString("n/a"), 15, " ")); + + // confirmations itemOutput->setText(COLUMN_CONFIRMATIONS, strPad(QString::number(out.nDepth), 8, " ")); diff --git a/src/qt/coincontroldialog.h b/src/qt/coincontroldialog.h index 465e2a009d..9353fd38cd 100644 --- a/src/qt/coincontroldialog.h +++ b/src/qt/coincontroldialog.h @@ -59,6 +59,7 @@ private: COLUMN_AMOUNT, COLUMN_LABEL, COLUMN_ADDRESS, + COLUMN_DARKSEND_ROUNDS, COLUMN_DATE, COLUMN_CONFIRMATIONS, COLUMN_PRIORITY, diff --git a/src/qt/forms/coincontroldialog.ui b/src/qt/forms/coincontroldialog.ui index cd1c0ffa18..9fee89a8e5 100644 --- a/src/qt/forms/coincontroldialog.ui +++ b/src/qt/forms/coincontroldialog.ui @@ -456,6 +456,11 @@ Address + + + Darksend Rounds + + Date