Skip to content

Commit 125888e

Browse files
committed
coin control tree widget root decoration
1 parent e4ba616 commit 125888e

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

src/qt/coincontroldialog.cpp

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,9 +207,11 @@ CoinControlDialog::CoinControlDialog(QWidget* parent, bool fMultisigEnabled) : Q
207207
QSettings settings;
208208
if (settings.contains("nCoinControlMode") && !settings.value("nCoinControlMode").toBool()) {
209209
ui->radioTreeMode->setChecked(true);
210+
ui->treeWidget->setRootIsDecorated(true);
210211
ui->radioTreeMode->click();
211212
}else{
212213
ui->radioListMode->setChecked(true);
214+
ui->treeWidget->setRootIsDecorated(false);
213215
}
214216
if (settings.contains("nCoinControlSortColumn") && settings.contains("nCoinControlSortOrder"))
215217
sortView(settings.value("nCoinControlSortColumn").toInt(), ((Qt::SortOrder)settings.value("nCoinControlSortOrder").toInt()));
@@ -775,9 +777,14 @@ void CoinControlDialog::updateView()
775777

776778
bool treeMode = ui->radioTreeMode->isChecked();
777779

780+
if(treeMode){
781+
ui->treeWidget->setRootIsDecorated(true);
782+
}else{
783+
ui->treeWidget->setRootIsDecorated(false);
784+
}
785+
778786
ui->treeWidget->clear();
779787
ui->treeWidget->setEnabled(false); // performance, otherwise updateLabels would be called for every checked checkbox
780-
//ui->treeWidget->setAlternatingRowColors(!treeMode);
781788
QFlags<Qt::ItemFlag> flgCheckbox = Qt::ItemIsSelectable | Qt::ItemIsEnabled | Qt::ItemIsUserCheckable;
782789
QFlags<Qt::ItemFlag> flgTristate = Qt::ItemIsSelectable | Qt::ItemIsEnabled | Qt::ItemIsUserCheckable | Qt::ItemIsTristate;
783790

0 commit comments

Comments
 (0)