mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-21 15:50:07 +01:00
fix crash: CoinControl "space" bug
Just likebaf80c26a2Github-Pull: #5700 Rebased-From:944c256741
This commit is contained in:
committed by
Wladimir J. van der Laan
parent
58259ad1ed
commit
ed4206acb1
@@ -17,7 +17,8 @@ void CoinControlTreeWidget::keyPressEvent(QKeyEvent *event)
|
||||
{
|
||||
event->ignore();
|
||||
int COLUMN_CHECKBOX = 0;
|
||||
this->currentItem()->setCheckState(COLUMN_CHECKBOX, ((this->currentItem()->checkState(COLUMN_CHECKBOX) == Qt::Checked) ? Qt::Unchecked : Qt::Checked));
|
||||
if(this->currentItem())
|
||||
this->currentItem()->setCheckState(COLUMN_CHECKBOX, ((this->currentItem()->checkState(COLUMN_CHECKBOX) == Qt::Checked) ? Qt::Unchecked : Qt::Checked));
|
||||
}
|
||||
else if (event->key() == Qt::Key_Escape) // press esc -> close dialog
|
||||
{
|
||||
@@ -29,4 +30,4 @@ void CoinControlTreeWidget::keyPressEvent(QKeyEvent *event)
|
||||
{
|
||||
this->QTreeWidget::keyPressEvent(event);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user