21 #include <QItemSelection> 22 #include <QMessageBox> 24 #include <QTextDocument> 29 columnResizingFixer(0),
31 platformStyle(_platformStyle)
61 QAction *copyURIAction =
new QAction(tr(
"Copy URI"),
this);
62 QAction *copyLabelAction =
new QAction(tr(
"Copy label"),
this);
63 QAction *copyMessageAction =
new QAction(tr(
"Copy message"),
this);
64 QAction *copyAmountAction =
new QAction(tr(
"Copy amount"),
this);
75 connect(copyURIAction, SIGNAL(triggered()),
this, SLOT(
copyURI()));
76 connect(copyLabelAction, SIGNAL(triggered()),
this, SLOT(
copyLabel()));
77 connect(copyMessageAction, SIGNAL(triggered()),
this, SLOT(
copyMessage()));
78 connect(copyAmountAction, SIGNAL(triggered()),
this, SLOT(
copyAmount()));
95 tableView->verticalHeader()->hide();
96 tableView->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
98 tableView->setAlternatingRowColors(
true);
99 tableView->setSelectionBehavior(QAbstractItemView::SelectRows);
100 tableView->setSelectionMode(QAbstractItemView::ContiguousSelection);
105 connect(tableView->selectionModel(),
106 SIGNAL(selectionChanged(QItemSelection, QItemSelection)),
this,
185 dialog->setAttribute(Qt::WA_DeleteOnClose);
187 dialog->setInfo(info);
200 dialog->
setInfo(submodel->
entry(index.row()).recipient);
201 dialog->setAttribute(Qt::WA_DeleteOnClose);
237 for (
const QModelIndex& index : selection) {
247 if(selection.empty())
250 QModelIndex firstIndex = selection.at(0);
263 QWidget::resizeEvent(event);
269 if (event->key() == Qt::Key_Return)
280 this->QDialog::keyPressEvent(event);
286 return QModelIndex();
288 if(selection.empty())
289 return QModelIndex();
291 QModelIndex firstIndex = selection.at(0);
299 if (!firstIndex.isValid()) {
318 if (!sel.isValid()) {
void stretchColumnWidth(int column)
Model for list of recently generated payment requests / fabcoin: URIs.
void addNewRequest(const SendCoinsRecipient &recipient)
void sort(int column, Qt::SortOrder order=Qt::AscendingOrder)
Dialog for requesting payment of fabcoins.
#define SetObjectStyleSheet(object, name)
bool removeRows(int row, int count, const QModelIndex &parent=QModelIndex())
QPushButton * receiveButton
void recentRequestsView_selectionChanged(const QItemSelection &selected, const QItemSelection &deselected)
void setModel(AddressTableModel *model)
const QString & getReturnValue() const
GUIUtil::TableViewLastColumnResizingFixer * columnResizingFixer
ReceiveCoinsDialog(const PlatformStyle *platformStyle, QWidget *parent=0)
FabcoinAmountField * reqAmount
Open address book to pick address.
AddressTableModel * getAddressTableModel()
Ui::ReceiveCoinsDialog * ui
QModelIndex selectedRow()
const RecentRequestEntry & entry(int row) const
void on_copyAddressButton_clicked()
QPushButton * showRequestButton
void setModel(WalletModel *model)
QPushButton * clearButton
void copyColumnToClipboard(int column)
QRImageWidget * lblQRCode
QVariant data(const QModelIndex &index, int role) const
void setClipboard(const QString &str)
void on_recentRequestsView_doubleClicked(const QModelIndex &index)
void setInfo(const SendCoinsRecipient &info)
Makes a QTableView last column feel as if it was being resized from its left border.
virtual void keyPressEvent(QKeyEvent *event)
Widget that shows a list of sending or receiving addresses.
static bool createQRCode(QLabel *label, SendCoinsRecipient info, bool showAddress=false)
void on_recentRequestsView_clicked(const QModelIndex &index)
QTableView * recentRequestsView
virtual void resizeEvent(QResizeEvent *event)
void on_removeRequestButton_clicked()
QString addRow(const QString &type, const QString &label, const QString &address)
void setValue(const CAmount &value)
RecentRequestsTableModel * getRecentRequestsTableModel()
void on_receiveButton_clicked()
QString formatFabcoinURI(const SendCoinsRecipient &info)
QString labelForAddress(const QString &address) const
Interface to Fabcoin wallet from Qt view code.
void setupUi(QWidget *ReceiveCoinsDialog)
void on_showRequestButton_clicked()
static const QString Receive
Specifies receive address.
const PlatformStyle * platformStyle
QPushButton * removeRequestButton
void showMenu(const QPoint &point)
QToolButton * copyAddressButton
struct evm_uint160be address(struct evm_env *env)
void setModel(OptionsModel *model)
void formatToolButtons(QToolButton *btn1, QToolButton *btn2, QToolButton *btn3)
void setDisplayUnit(int unit)
Change unit used to display amount.
void clear()
Make field empty and ready for new input.
QToolButton * refreshButton
OptionsModel * getOptionsModel()