Changeset View
Changeset View
Standalone View
Standalone View
src/interfaces/wallet.cpp
Show First 20 Lines • Show All 56 Lines • ▼ Show 20 Lines | namespace { | ||||
} | } | ||||
//! Construct wallet tx status struct. | //! Construct wallet tx status struct. | ||||
static WalletTxStatus | static WalletTxStatus | ||||
MakeWalletTxStatus(interfaces::Chain::Lock &locked_chain, | MakeWalletTxStatus(interfaces::Chain::Lock &locked_chain, | ||||
const CWalletTx &wtx) { | const CWalletTx &wtx) { | ||||
WalletTxStatus result; | WalletTxStatus result; | ||||
result.block_height = | result.block_height = | ||||
locked_chain.getBlockHeight(wtx.hashBlock) | locked_chain.getBlockHeight(wtx.m_confirm.hashBlock) | ||||
.get_value_or(std::numeric_limits<int>::max()); | .get_value_or(std::numeric_limits<int>::max()); | ||||
result.blocks_to_maturity = wtx.GetBlocksToMaturity(locked_chain); | result.blocks_to_maturity = wtx.GetBlocksToMaturity(locked_chain); | ||||
result.depth_in_main_chain = wtx.GetDepthInMainChain(locked_chain); | result.depth_in_main_chain = wtx.GetDepthInMainChain(locked_chain); | ||||
result.time_received = wtx.nTimeReceived; | result.time_received = wtx.nTimeReceived; | ||||
result.lock_time = wtx.tx->nLockTime; | result.lock_time = wtx.tx->nLockTime; | ||||
TxValidationState state; | TxValidationState state; | ||||
result.is_final = | result.is_final = | ||||
locked_chain.contextualCheckTransactionForCurrentBlock( | locked_chain.contextualCheckTransactionForCurrentBlock( | ||||
▲ Show 20 Lines • Show All 444 Lines • Show Last 20 Lines |