mirror of
https://github.com/feather-wallet/feather.git
synced 2024-12-22 11:39:25 +00:00
Send: clear donate description if address was changed
This commit is contained in:
parent
8c88f69f25
commit
a5135ecf8e
3 changed files with 7 additions and 1 deletions
|
@ -1067,7 +1067,7 @@ void MainWindow::changeEvent(QEvent* event)
|
|||
}
|
||||
|
||||
void MainWindow::donateButtonClicked() {
|
||||
m_sendWidget->fill(constants::donationAddress, "Donation to the Feather development team");
|
||||
m_sendWidget->fill(constants::donationAddress, constants::donationDescription);
|
||||
ui->tabWidget->setCurrentIndex(Tabs::SEND);
|
||||
}
|
||||
|
||||
|
|
|
@ -90,6 +90,11 @@ void SendWidget::addressEdited() {
|
|||
}
|
||||
|
||||
ui->btn_openAlias->setVisible(ui->lineAddress->isOpenAlias());
|
||||
|
||||
// Clear donation description if address no longer matches
|
||||
if (ui->lineDescription->text() == constants::donationDescription && ui->lineAddress->text() != constants::donationAddress) {
|
||||
ui->lineDescription->clear();
|
||||
}
|
||||
}
|
||||
|
||||
void SendWidget::amountEdited(const QString &text) {
|
||||
|
|
|
@ -23,6 +23,7 @@ namespace constants
|
|||
|
||||
// donation constants
|
||||
const QString donationAddress = "47ntfT2Z5384zku39pTM6hGcnLnvpRYW2Azm87GiAAH2bcTidtq278TL6HmwyL8yjMeERqGEBs3cqC8vvHPJd1cWQrGC65f";
|
||||
const QString donationDescription = "Donation to the Feather development team";
|
||||
const int donationBoundary = 25;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue