Fabcoin Core  0.16.2
P2P Digital Currency
transactionview.h
Go to the documentation of this file.
1 // Copyright (c) 2011-2017 The Bitcoin Core developers
2 // Distributed under the MIT software license, see the accompanying
3 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
4 
5 #ifndef FABCOIN_QT_TRANSACTIONVIEW_H
6 #define FABCOIN_QT_TRANSACTIONVIEW_H
7 
8 #include <guiutil.h>
9 
10 #include <QWidget>
11 #include <QKeyEvent>
12 
13 class PlatformStyle;
15 class WalletModel;
16 
17 QT_BEGIN_NAMESPACE
18 class QComboBox;
19 class QDateTimeEdit;
20 class QFrame;
21 class QLineEdit;
22 class QMenu;
23 class QModelIndex;
24 class QSignalMapper;
25 class QTableView;
26 QT_END_NAMESPACE
27 
31 class TransactionView : public QWidget
32 {
33  Q_OBJECT
34 
35 public:
36  explicit TransactionView(const PlatformStyle *platformStyle, QWidget *parent = 0);
37 
38  void setModel(WalletModel *model);
39 
40  // Date ranges for filter
41  enum DateEnum
42  {
43  All,
50  };
51 
52  enum ColumnWidths {
59  };
60 
61 private:
64  QTableView *transactionView;
65 
66  QComboBox *dateWidget;
67  QComboBox *typeWidget;
68  QComboBox *watchOnlyWidget;
69  QLineEdit *addressWidget;
70  QLineEdit *amountWidget;
71 
72  QMenu *contextMenu;
73  QSignalMapper *mapperThirdPartyTxUrls;
74 
75  QFrame *dateRangeWidget;
76  QDateTimeEdit *dateFrom;
77  QDateTimeEdit *dateTo;
78  QAction *abandonAction;
79  QAction *bumpFeeAction;
80 
81  QWidget *createDateRangeWidget();
82 
84 
85  virtual void resizeEvent(QResizeEvent* event);
86 
87  bool eventFilter(QObject *obj, QEvent *event);
88 
89 private Q_SLOTS:
90  void contextualMenu(const QPoint &);
91  void dateRangeChanged();
92  void showDetails();
93  void copyAddress();
94  void editLabel();
95  void copyLabel();
96  void copyAmount();
97  void copyTxID();
98  void copyTxHex();
99  void copyTxPlainText();
100  void openThirdPartyTxUrl(QString url);
101  void updateWatchOnlyColumn(bool fHaveWatchOnly);
102  void abandonTx();
103  void bumpFee();
104 
105 Q_SIGNALS:
106  void doubleClicked(const QModelIndex&);
107 
109  void message(const QString &title, const QString &message, unsigned int style);
110 
111 public Q_SLOTS:
112  void chooseDate(int idx);
113  void chooseType(int idx);
114  void chooseWatchonly(int idx);
115  void changedAmount();
116  void changedPrefix();
117  void exportClicked();
118  void focusTransaction(const QModelIndex&);
119 
120 };
121 
122 #endif // FABCOIN_QT_TRANSACTIONVIEW_H
TransactionView(const PlatformStyle *platformStyle, QWidget *parent=0)
bool eventFilter(QObject *obj, QEvent *event)
void openThirdPartyTxUrl(QString url)
QWidget * createDateRangeWidget()
QAction * abandonAction
void focusTransaction(const QModelIndex &)
QTableView * transactionView
void chooseWatchonly(int idx)
QDateTimeEdit * dateTo
const char * url
Definition: rpcconsole.cpp:59
virtual void resizeEvent(QResizeEvent *event)
QSignalMapper * mapperThirdPartyTxUrls
void message(const QString &title, const QString &message, unsigned int style)
Fired when a message should be reported to the user.
Widget showing the transaction list for a wallet, including a filter row.
Makes a QTableView last column feel as if it was being resized from its left border.
Definition: guiutil.h:158
void updateWatchOnlyColumn(bool fHaveWatchOnly)
TransactionFilterProxy * transactionProxyModel
QComboBox * watchOnlyWidget
void chooseDate(int idx)
void setModel(WalletModel *model)
QLineEdit * amountWidget
QComboBox * typeWidget
Filter the transaction list according to pre-specified rules.
Interface to Fabcoin wallet from Qt view code.
Definition: walletmodel.h:103
QFrame * dateRangeWidget
QLineEdit * addressWidget
void contextualMenu(const QPoint &)
void chooseType(int idx)
QAction * bumpFeeAction
GUIUtil::TableViewLastColumnResizingFixer * columnResizingFixer
QDateTimeEdit * dateFrom
void doubleClicked(const QModelIndex &)
WalletModel * model
QComboBox * dateWidget