aboutsummaryrefslogtreecommitdiff
path: root/gui/include
diff options
context:
space:
mode:
Diffstat (limited to 'gui/include')
-rw-r--r--gui/include/bitcoingui.h1
-rw-r--r--gui/include/clientmodel.h17
-rw-r--r--gui/include/sendcoinsdialog.h4
3 files changed, 22 insertions, 0 deletions
diff --git a/gui/include/bitcoingui.h b/gui/include/bitcoingui.h
index 80c24a3733..955d7b4781 100644
--- a/gui/include/bitcoingui.h
+++ b/gui/include/bitcoingui.h
@@ -67,6 +67,7 @@ private slots:
void newAddressClicked();
void copyClipboardClicked();
+ void error(const QString &title, const QString &message);
};
#endif
diff --git a/gui/include/clientmodel.h b/gui/include/clientmodel.h
index a5613e34b6..828c80f8db 100644
--- a/gui/include/clientmodel.h
+++ b/gui/include/clientmodel.h
@@ -9,18 +9,35 @@ class ClientModel : public QObject
public:
explicit ClientModel(QObject *parent = 0);
+ enum StatusCode
+ {
+ OK,
+ InvalidAmount,
+ InvalidAddress,
+ AmountExceedsBalance,
+ AmountWithFeeExceedsBalance,
+ Aborted,
+ MiscError
+ };
+
qint64 getBalance();
QString getAddress();
int getNumConnections();
int getNumBlocks();
int getNumTransactions();
+ qint64 getTransactionFee();
+
+ StatusCode sendCoins(const QString &payTo, qint64 payAmount);
+
signals:
void balanceChanged(qint64 balance);
void addressChanged(const QString &address);
void numConnectionsChanged(int count);
void numBlocksChanged(int count);
void numTransactionsChanged(int count);
+ /* Asynchronous error notification */
+ void error(const QString &title, const QString &message);
public slots:
diff --git a/gui/include/sendcoinsdialog.h b/gui/include/sendcoinsdialog.h
index 95dd34b1e5..f73c38d63a 100644
--- a/gui/include/sendcoinsdialog.h
+++ b/gui/include/sendcoinsdialog.h
@@ -6,6 +6,7 @@
namespace Ui {
class SendCoinsDialog;
}
+class ClientModel;
class SendCoinsDialog : public QDialog
{
@@ -15,8 +16,11 @@ public:
explicit SendCoinsDialog(QWidget *parent = 0, const QString &address = "");
~SendCoinsDialog();
+ void setModel(ClientModel *model);
+
private:
Ui::SendCoinsDialog *ui;
+ ClientModel *model;
private slots:
void on_buttonBox_rejected();