mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-04-25 06:19:25 +02:00
qt: Register wallet::AddressPurpose type
This commit is contained in:
@@ -40,6 +40,7 @@
|
|||||||
#include <qt/paymentserver.h>
|
#include <qt/paymentserver.h>
|
||||||
#include <qt/walletcontroller.h>
|
#include <qt/walletcontroller.h>
|
||||||
#include <qt/walletmodel.h>
|
#include <qt/walletmodel.h>
|
||||||
|
#include <wallet/types.h>
|
||||||
#endif // ENABLE_WALLET
|
#endif // ENABLE_WALLET
|
||||||
|
|
||||||
#include <boost/signals2/connection.hpp>
|
#include <boost/signals2/connection.hpp>
|
||||||
@@ -79,6 +80,9 @@ Q_DECLARE_METATYPE(CAmount)
|
|||||||
Q_DECLARE_METATYPE(SynchronizationState)
|
Q_DECLARE_METATYPE(SynchronizationState)
|
||||||
Q_DECLARE_METATYPE(SyncType)
|
Q_DECLARE_METATYPE(SyncType)
|
||||||
Q_DECLARE_METATYPE(uint256)
|
Q_DECLARE_METATYPE(uint256)
|
||||||
|
#ifdef ENABLE_WALLET
|
||||||
|
Q_DECLARE_METATYPE(wallet::AddressPurpose)
|
||||||
|
#endif // ENABLE_WALLET
|
||||||
|
|
||||||
static void RegisterMetaTypes()
|
static void RegisterMetaTypes()
|
||||||
{
|
{
|
||||||
@@ -88,7 +92,8 @@ static void RegisterMetaTypes()
|
|||||||
qRegisterMetaType<SyncType>();
|
qRegisterMetaType<SyncType>();
|
||||||
#ifdef ENABLE_WALLET
|
#ifdef ENABLE_WALLET
|
||||||
qRegisterMetaType<WalletModel*>();
|
qRegisterMetaType<WalletModel*>();
|
||||||
#endif
|
qRegisterMetaType<wallet::AddressPurpose>();
|
||||||
|
#endif // ENABLE_WALLET
|
||||||
// Register typedefs (see https://doc.qt.io/qt-5/qmetatype.html#qRegisterMetaType)
|
// Register typedefs (see https://doc.qt.io/qt-5/qmetatype.html#qRegisterMetaType)
|
||||||
// IMPORTANT: if CAmount is no longer a typedef use the normal variant above (see https://doc.qt.io/qt-5/qmetatype.html#qRegisterMetaType-1)
|
// IMPORTANT: if CAmount is no longer a typedef use the normal variant above (see https://doc.qt.io/qt-5/qmetatype.html#qRegisterMetaType-1)
|
||||||
qRegisterMetaType<CAmount>("CAmount");
|
qRegisterMetaType<CAmount>("CAmount");
|
||||||
|
|||||||
Reference in New Issue
Block a user