7 #include "ui_sendcoinsentry.h" 18 #include <QGraphicsDropShadowEffect> 19 #include <QApplication> 23 QStackedWidget(parent),
26 platformStyle(_platformStyle)
36 setCurrentWidget(
ui->SendCoins);
39 ui->payToLayout->setSpacing(4);
40 #if QT_VERSION >= 0x040700 41 ui->addAsLabel->setPlaceholderText(tr(
"Enter a label for this address to add it to your address book"));
52 connect(
ui->deleteButton, SIGNAL(clicked()),
this, SLOT(
deleteClicked()));
53 connect(
ui->deleteButton_is, SIGNAL(clicked()),
this, SLOT(
deleteClicked()));
54 connect(
ui->deleteButton_s, SIGNAL(clicked()),
this, SLOT(
deleteClicked()));
72 ui->checkboxSubtractFeeFromAmount->setStyleSheet(QString(
".QCheckBox{ %1; }").arg(
STRING_LABEL_COLOR));
87 ui->payTo->setText(QApplication::clipboard()->text());
99 ui->payAmount->setFocus();
110 this->
model = _model;
122 ui->addAsLabel->clear();
123 ui->payAmount->clear();
124 ui->checkboxSubtractFeeFromAmount->setCheckState(Qt::Unchecked);
125 ui->messageTextLabel->clear();
126 ui->messageTextLabel->hide();
127 ui->messageLabel->hide();
129 ui->payTo_is->clear();
130 ui->memoTextLabel_is->clear();
131 ui->payAmount_is->clear();
133 ui->payTo_s->clear();
134 ui->memoTextLabel_s->clear();
135 ui->payAmount_s->clear();
160 ui->payTo->setValid(
false);
164 if (!
ui->payAmount->validate())
170 if (
ui->payAmount->value(0) <= 0)
172 ui->payAmount->setValid(
false);
178 ui->payAmount->setValid(
false);
203 QWidget::setTabOrder(prev,
ui->payTo);
204 QWidget::setTabOrder(
ui->payTo,
ui->addAsLabel);
205 QWidget *w =
ui->payAmount->setupTabChain(
ui->addAsLabel);
206 QWidget::setTabOrder(w,
ui->checkboxSubtractFeeFromAmount);
207 QWidget::setTabOrder(
ui->checkboxSubtractFeeFromAmount,
ui->addressBookButton);
208 QWidget::setTabOrder(
ui->addressBookButton,
ui->pasteButton);
209 QWidget::setTabOrder(
ui->pasteButton,
ui->deleteButton);
210 return ui->deleteButton;
224 ui->payAmount_is->setReadOnly(
true);
225 setCurrentWidget(
ui->SendCoins_UnauthenticatedPaymentRequest);
232 ui->payAmount_s->setReadOnly(
true);
233 setCurrentWidget(
ui->SendCoins_AuthenticatedPaymentRequest);
243 ui->addAsLabel->clear();
253 ui->payTo->setText(address);
254 ui->payAmount->setFocus();
259 return ui->payTo->text().isEmpty() &&
ui->payTo_is->text().isEmpty() &&
ui->payTo_s->text().isEmpty();
264 ui->payTo->setFocus();
285 if(!associatedLabel.isEmpty())
287 ui->addAsLabel->setText(associatedLabel);
bool isDust(const QString &address, const CAmount &amount)
void setValue(const SendCoinsRecipient &value)
PaymentRequestPlus paymentRequest
QGraphicsDropShadowEffect * getShadowEffect()
SendCoinsRecipient getValue()
void setModel(AddressTableModel *model)
void setAddress(const QString &address)
bool updateLabel(const QString &address)
void on_payTo_textChanged(const QString &address)
bool IsInitialized() const
Open address book to pick address.
AddressTableModel * getAddressTableModel()
A single entry in the dialog for sending ravens.
int getDisplayUnit() const
QWidget * setupTabChain(QWidget *prev)
Set up the tab chain manually, as Qt messes up the tab chain by default in some cases (issue https://...
void setupAddressWidget(QValidatedLineEdit *widget, QWidget *parent)
#define STRING_LABEL_COLOR
QString labelForAddress(const QString &address) const
Widget that shows a list of sending or receiving addresses.
void removeEntry(SendCoinsEntry *entry)
bool isClear()
Return whether the entry is still empty and unedited.
bool validateAddress(const QString &address)
void subtractFeeFromAmountChanged()
void on_pasteButton_clicked()
Interface to Raven wallet from Qt view code.
SendCoinsRecipient recipient
void on_addressBookButton_clicked()
void setModel(WalletModel *model)
SendCoinsEntry(const PlatformStyle *platformStyle, QWidget *parent=0)
bool fSubtractFeeFromAmount
const PlatformStyle * platformStyle
QString authenticatedMerchant
OptionsModel * getOptionsModel()
const QString & getReturnValue() const