Anoncoin  0.9.4
P2P Digital Currency
transactionview.h
Go to the documentation of this file.
1 // Copyright (c) 2011-2013 The Bitcoin developers
2 // Copyright (c) 2013-2014 The Anoncoin Core developers
3 // Distributed under the MIT/X11 software license, see the accompanying
4 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
5 
6 #ifndef TRANSACTIONVIEW_H
7 #define TRANSACTIONVIEW_H
8 
9 #include "guiutil.h"
10 
11 #include <QWidget>
12 
14 class WalletModel;
15 
16 QT_BEGIN_NAMESPACE
17 class QComboBox;
18 class QDateTimeEdit;
19 class QFrame;
20 class QLineEdit;
21 class QMenu;
22 class QModelIndex;
23 class QSignalMapper;
24 class QTableView;
25 QT_END_NAMESPACE
26 
30 class TransactionView : public QWidget
31 {
32  Q_OBJECT
33 
34 public:
35  explicit TransactionView(QWidget *parent = 0);
36 
37  void setModel(WalletModel *model);
38 
39  // Date ranges for filter
40  enum DateEnum
41  {
42  All,
49  };
50 
51  enum ColumnWidths {
58  };
59 
60 private:
63  QTableView *transactionView;
64 
65  QComboBox *dateWidget;
66  QComboBox *typeWidget;
67  QComboBox *watchOnlyWidget;
68  QLineEdit *addressWidget;
69  QLineEdit *amountWidget;
70 
71  QMenu *contextMenu;
72  QSignalMapper *mapperThirdPartyTxUrls;
73 
74  QFrame *dateRangeWidget;
75  QDateTimeEdit *dateFrom;
76  QDateTimeEdit *dateTo;
77 
78  QWidget *createDateRangeWidget();
79 
81 
82  virtual void resizeEvent(QResizeEvent* event);
83 
84 private slots:
85  void contextualMenu(const QPoint &);
86  void dateRangeChanged();
87  void showDetails();
88  void copyAddress();
89  void editLabel();
90  void copyLabel();
91  void copyAmount();
92  void copyTxID();
93  void openThirdPartyTxUrl(QString url);
94  void updateWatchOnlyColumn(bool fHaveWatchOnly);
95 
96 signals:
97  void doubleClicked(const QModelIndex&);
98 
100  void message(const QString &title, const QString &message, unsigned int style);
101 
102 public slots:
103  void chooseDate(int idx);
104  void chooseType(int idx);
105  void chooseWatchonly(int idx);
106  void changedPrefix(const QString &prefix);
107  void changedAmount(const QString &amount);
108  void exportClicked();
109  void focusTransaction(const QModelIndex&);
110 
111 };
112 
113 #endif // TRANSACTIONVIEW_H
void changedPrefix(const QString &prefix)
TransactionView(QWidget *parent=0)
void openThirdPartyTxUrl(QString url)
QWidget * createDateRangeWidget()
void focusTransaction(const QModelIndex &)
QTableView * transactionView
void chooseWatchonly(int idx)
QDateTimeEdit * dateTo
const char * url
Definition: rpcconsole.cpp:51
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:140
void changedAmount(const QString &amount)
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 Anoncoin wallet from Qt view code.
Definition: walletmodel.h:97
QFrame * dateRangeWidget
QLineEdit * addressWidget
void contextualMenu(const QPoint &)
void chooseType(int idx)
GUIUtil::TableViewLastColumnResizingFixer * columnResizingFixer
QDateTimeEdit * dateFrom
void doubleClicked(const QModelIndex &)
WalletModel * model
QComboBox * dateWidget