From 34e5703f9c4628966f4863974a9336b8927049ef Mon Sep 17 00:00:00 2001 From: tobtoht Date: Sat, 12 Mar 2022 15:03:33 +0100 Subject: [PATCH] libwalletqt: more cleanup --- src/libwalletqt/ConstructionInfo.h | 7 ------- src/libwalletqt/PendingTransaction.cpp | 1 + src/libwalletqt/PendingTransaction.h | 11 +---------- src/libwalletqt/PendingTransactionInfo.h | 11 ----------- src/libwalletqt/Transfer.h | 3 +-- 5 files changed, 3 insertions(+), 30 deletions(-) diff --git a/src/libwalletqt/ConstructionInfo.h b/src/libwalletqt/ConstructionInfo.h index 5be7cc2..a86485d 100644 --- a/src/libwalletqt/ConstructionInfo.h +++ b/src/libwalletqt/ConstructionInfo.h @@ -14,12 +14,6 @@ class Transfer; class ConstructionInfo : public QObject { Q_OBJECT - Q_PROPERTY(quint64 unlockTime READ unlockTime) - Q_PROPERTY(QSet subaddressIndices READ subaddressIndices) - Q_PROPERTY(QVector subaddresses READ subaddresses) - Q_PROPERTY(quint64 minMixinCount READ minMixinCount) - Q_PROPERTY(QList inputs READ inputs) - Q_PROPERTY(QList outputs READ outputs) public: quint64 unlockTime() const; @@ -42,5 +36,4 @@ private: mutable QList m_outputs; }; - #endif //FEATHER_CONSTRUCTIONINFO_H diff --git a/src/libwalletqt/PendingTransaction.cpp b/src/libwalletqt/PendingTransaction.cpp index 726aade..6725b16 100644 --- a/src/libwalletqt/PendingTransaction.cpp +++ b/src/libwalletqt/PendingTransaction.cpp @@ -3,6 +3,7 @@ #include "PendingTransaction.h" +#include PendingTransaction::Status PendingTransaction::status() const { diff --git a/src/libwalletqt/PendingTransaction.h b/src/libwalletqt/PendingTransaction.h index ec037b3..202b3a4 100644 --- a/src/libwalletqt/PendingTransaction.h +++ b/src/libwalletqt/PendingTransaction.h @@ -6,7 +6,6 @@ #include #include -#include #include #include "PendingTransactionInfo.h" @@ -14,14 +13,6 @@ class PendingTransaction : public QObject { Q_OBJECT - Q_PROPERTY(Status status READ status) - Q_PROPERTY(QString errorString READ errorString) - Q_PROPERTY(quint64 amount READ amount) - Q_PROPERTY(quint64 dust READ dust) - Q_PROPERTY(quint64 fee READ fee) - Q_PROPERTY(QStringList txid READ txid) - Q_PROPERTY(quint64 txCount READ txCount) - Q_PROPERTY(QList subaddrIndices READ subaddrIndices) public: enum Status { @@ -41,7 +32,7 @@ public: Status status() const; QString errorString() const; - Q_INVOKABLE bool commit(); + bool commit(); bool saveToFile(const QString &fileName); quint64 amount() const; quint64 dust() const; diff --git a/src/libwalletqt/PendingTransactionInfo.h b/src/libwalletqt/PendingTransactionInfo.h index 2667c6e..28ec382 100644 --- a/src/libwalletqt/PendingTransactionInfo.h +++ b/src/libwalletqt/PendingTransactionInfo.h @@ -15,16 +15,6 @@ class Transfer; class PendingTransactionInfo : public ConstructionInfo { Q_OBJECT - Q_PROPERTY(quint64 fee READ fee) - Q_PROPERTY(quint64 dust READ dust) - Q_PROPERTY(bool dustAddedToFee READ dustAddedToFee) - Q_PROPERTY(QString txKey READ txKey) - Q_PROPERTY(quint64 unlockTime READ unlockTime) - Q_PROPERTY(QSet subaddressIndices READ subaddressIndices) - Q_PROPERTY(QVector subaddresses READ subaddresses) - Q_PROPERTY(quint64 minMixinCount READ minMixinCount) - Q_PROPERTY(QList inputs READ inputs) - Q_PROPERTY(QList outputs READ outputs) public: quint64 fee() const; @@ -42,5 +32,4 @@ private: QString m_txKey; }; - #endif //FEATHER_PENDINGTRANSACTIONINFO_H diff --git a/src/libwalletqt/Transfer.h b/src/libwalletqt/Transfer.h index aebf09e..65fe73c 100644 --- a/src/libwalletqt/Transfer.h +++ b/src/libwalletqt/Transfer.h @@ -11,8 +11,7 @@ class Transfer : public QObject { Q_OBJECT - Q_PROPERTY(quint64 amount READ amount) - Q_PROPERTY(QString address READ address) + private: explicit Transfer(uint64_t _amount, QString _address, QObject *parent = 0) : QObject(parent), m_amount(_amount), m_address(std::move(_address)) {};