diff --git a/src/coincontrol.h b/src/coincontrol.h index d3f75ca81..82346aefd 100644 --- a/src/coincontrol.h +++ b/src/coincontrol.h @@ -13,7 +13,7 @@ class CCoinControl public: CTxDestination destChange; bool fUsePrivateSend; - bool useInstantX; + bool fUseInstantSend; //! If false, allows unselected inputs, but requires all selected inputs be used bool fAllowOtherInputs; //! Includes watch only addresses which match the ISMINE_WATCH_SOLVABLE criteria @@ -32,7 +32,7 @@ public: fAllowOtherInputs = false; fAllowWatchOnly = false; setSelected.clear(); - useInstantX = false; + fUseInstantSend = false; fUsePrivateSend = true; nMinimumTotalFee = 0; } diff --git a/src/instantx.cpp b/src/instantx.cpp index a58518f98..e404a3bdb 100644 --- a/src/instantx.cpp +++ b/src/instantx.cpp @@ -51,7 +51,7 @@ void ProcessMessageInstantSend(CNode* pfrom, std::string& strCommand, CDataStrea // Ignore any InstantSend messages until masternode list is synced if(!masternodeSync.IsMasternodeListSynced()) return; - if (strCommand == NetMsgType::IX) + if (strCommand == NetMsgType::IX) // InstantSend Transaction Lock Request { //LogPrintf("ProcessMessageInstantSend\n"); CDataStream vMsg(vRecv); @@ -70,7 +70,7 @@ void ProcessMessageInstantSend(CNode* pfrom, std::string& strCommand, CDataStrea if(!IsInstantSendTxValid(tx)) return; BOOST_FOREACH(const CTxOut o, tx.vout) { - // IX supports normal scripts and unspendable scripts (used in DS collateral and Budget collateral). + // InstandSend supports normal scripts and unspendable scripts (used in PrivateSend collateral and Governance collateral). // TODO: Look into other script types that are normal and can be included if(!o.scriptPubKey.IsNormalPaymentScript() && !o.scriptPubKey.IsUnspendable()) { LogPrintf("ProcessMessageInstantSend -- Invalid Script %s", tx.ToString()); @@ -127,7 +127,7 @@ void ProcessMessageInstantSend(CNode* pfrom, std::string& strCommand, CDataStrea return; } } - else if (strCommand == NetMsgType::IXLOCKVOTE) //InstantX Lock Consensus Votes + else if (strCommand == NetMsgType::IXLOCKVOTE) // InstantSend Transaction Lock Consensus Votes { CConsensusVote vote; vRecv >> vote; diff --git a/src/instantx.h b/src/instantx.h index b2bf9926f..343ddc0ee 100644 --- a/src/instantx.h +++ b/src/instantx.h @@ -17,7 +17,7 @@ class CTransactionLock; /* At 15 signatures, 1/2 of the masternode network can be owned by - one party without comprimising the security of InstantX + one party without comprimising the security of InstantSend (1000/2150.0)**10 = 0.00047382219560689856 (1000/2900.0)**10 = 2.3769498616783657e-05 diff --git a/src/main.cpp b/src/main.cpp index ca5515880..cc30c62bd 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1087,7 +1087,7 @@ bool AcceptToMemoryPoolWorker(CTxMemPool& pool, CValidationState &state, const C if (pool.exists(hash)) return state.Invalid(false, REJECT_ALREADY_KNOWN, "txn-already-in-mempool"); - // ----------- instantX transaction scanning ----------- + // ----------- InstantSend transaction scanning ----------- BOOST_FOREACH(const CTxIn& in, tx.vin){ if(mapLockedInputs.count(in.prevout)){ diff --git a/src/qt/coincontroldialog.cpp b/src/qt/coincontroldialog.cpp index 3f10741a7..6662af082 100644 --- a/src/qt/coincontroldialog.cpp +++ b/src/qt/coincontroldialog.cpp @@ -607,7 +607,7 @@ void CoinControlDialog::updateLabels(WalletModel *model, QDialog* dialog) nPayFee = coinControl->nMinimumTotalFee; // InstantSend Fee - if(coinControl->useInstantX) nPayFee = max(nPayFee, INSTANTSEND_MIN_FEE); + if (coinControl->fUseInstantSend) nPayFee = std::max(nPayFee, INSTANTSEND_MIN_FEE); // Allow free? (require at least hard-coded threshold and default to that if no estimate) double dPriorityNeeded = std::max(mempoolEstimatePriority, AllowFreeThreshold()); diff --git a/src/qt/forms/sendcoinsdialog.ui b/src/qt/forms/sendcoinsdialog.ui index 3c82fcc76..fdce0f823 100644 --- a/src/qt/forms/sendcoinsdialog.ui +++ b/src/qt/forms/sendcoinsdialog.ui @@ -1332,7 +1332,7 @@ - + true diff --git a/src/qt/res/css/crownium.css b/src/qt/res/css/crownium.css index 7b245d21b..70d3d1f21 100644 --- a/src/qt/res/css/crownium.css +++ b/src/qt/res/css/crownium.css @@ -1227,7 +1227,7 @@ padding-top:20px; padding-bottom:18px; } -QDialog#SendCoinsDialog .QCheckBox#checkInstantX { /* InstantX Checkbox */ +QDialog#SendCoinsDialog .QCheckBox#checkUseInstantSend { /* InstantSend Checkbox */ color:#555555; font-weight:bold; background: qradialgradient(cx:0.5, cy:0.5, radius: 0.5, fx:0.5, fy:0.5, stop:0 rgba(248, 246, 246, 128), stop: 1 rgba(0, 0, 0, 0)); diff --git a/src/qt/res/css/drkblue.css b/src/qt/res/css/drkblue.css index 8bc015726..f182605f4 100644 --- a/src/qt/res/css/drkblue.css +++ b/src/qt/res/css/drkblue.css @@ -1211,7 +1211,7 @@ padding-top:20px; padding-bottom:18px; } -QDialog#SendCoinsDialog .QCheckBox#checkInstantX { /* InstantX Checkbox */ +QDialog#SendCoinsDialog .QCheckBox#checkUseInstantSend { /* InstantSend Checkbox */ color:#616161; font-weight:bold; background: qradialgradient(cx:0.5, cy:0.5, radius: 0.5, fx:0.5, fy:0.5, stop:0 rgba(248, 246, 246, 128), stop: 1 rgba(0, 0, 0, 0)); diff --git a/src/qt/res/css/light.css b/src/qt/res/css/light.css index 06f90e45b..c2bd605b6 100644 --- a/src/qt/res/css/light.css +++ b/src/qt/res/css/light.css @@ -1219,7 +1219,7 @@ padding-top:20px; padding-bottom:18px; } -QDialog#SendCoinsDialog .QCheckBox#checkInstantX { /* InstantX Checkbox */ +QDialog#SendCoinsDialog .QCheckBox#checkUseInstantSend { /* InstantSend Checkbox */ color:#616161; font-weight:bold; background: qradialgradient(cx:0.5, cy:0.5, radius: 0.5, fx:0.5, fy:0.5, stop:0 rgba(248, 246, 246, 128), stop: 1 rgba(0, 0, 0, 0)); diff --git a/src/qt/sendcoinsdialog.cpp b/src/qt/sendcoinsdialog.cpp index 4131556bf..49ba1adce 100644 --- a/src/qt/sendcoinsdialog.cpp +++ b/src/qt/sendcoinsdialog.cpp @@ -70,23 +70,23 @@ SendCoinsDialog::SendCoinsDialog(const PlatformStyle *platformStyle, QWidget *pa settings.setValue("bUseInstantX", false); bool fUsePrivateSend = settings.value("bUseDarkSend").toBool(); - bool useInstantX = settings.value("bUseInstantX").toBool(); + bool fUseInstantSend = settings.value("bUseInstantX").toBool(); if(fLiteMode) { ui->checkUsePrivateSend->setChecked(false); ui->checkUsePrivateSend->setVisible(false); - ui->checkInstantX->setVisible(false); + ui->checkUseInstantSend->setVisible(false); CoinControlDialog::coinControl->fUsePrivateSend = false; - CoinControlDialog::coinControl->useInstantX = false; + CoinControlDialog::coinControl->fUseInstantSend = false; } else{ ui->checkUsePrivateSend->setChecked(fUsePrivateSend); - ui->checkInstantX->setChecked(useInstantX); + ui->checkUseInstantSend->setChecked(fUseInstantSend); CoinControlDialog::coinControl->fUsePrivateSend = fUsePrivateSend; - CoinControlDialog::coinControl->useInstantX = useInstantX; + CoinControlDialog::coinControl->fUseInstantSend = fUseInstantSend; } connect(ui->checkUsePrivateSend, SIGNAL(stateChanged ( int )), this, SLOT(updateDisplayUnit())); - connect(ui->checkInstantX, SIGNAL(stateChanged ( int )), this, SLOT(updateInstantX())); + connect(ui->checkUseInstantSend, SIGNAL(stateChanged ( int )), this, SLOT(updateInstantSend())); // Coin Control: clipboard actions QAction *clipboardQuantityAction = new QAction(tr("Copy quantity"), this); @@ -269,12 +269,12 @@ void SendCoinsDialog::on_sendButton_clicked() strFunds = tr("using") + " " + tr("any available funds (not recommended)") + ""; } - if(ui->checkInstantX->isChecked()) { - recipients[0].useInstantX = true; + if(ui->checkUseInstantSend->isChecked()) { + recipients[0].fUseInstantSend = true; strFunds += " "; strFunds += tr("and InstantSend"); } else { - recipients[0].useInstantX = false; + recipients[0].fUseInstantSend = false; } @@ -599,11 +599,11 @@ void SendCoinsDialog::updateDisplayUnit() updateSmartFeeLabel(); } -void SendCoinsDialog::updateInstantX() +void SendCoinsDialog::updateInstantSend() { QSettings settings; - settings.setValue("bUseInstantX", ui->checkInstantX->isChecked()); - CoinControlDialog::coinControl->useInstantX = ui->checkInstantX->isChecked(); + settings.setValue("bUseInstantX", ui->checkUseInstantSend->isChecked()); + CoinControlDialog::coinControl->fUseInstantSend = ui->checkUseInstantSend->isChecked(); coinControlUpdateLabels(); } diff --git a/src/qt/sendcoinsdialog.h b/src/qt/sendcoinsdialog.h index 285621db4..c561121d0 100644 --- a/src/qt/sendcoinsdialog.h +++ b/src/qt/sendcoinsdialog.h @@ -79,7 +79,7 @@ private Q_SLOTS: void on_buttonMinimizeFee_clicked(); void removeEntry(SendCoinsEntry* entry); void updateDisplayUnit(); - void updateInstantX(); + void updateInstantSend(); void coinControlFeatureChanged(bool); void coinControlButtonClicked(); void coinControlChangeChecked(int); diff --git a/src/qt/walletmodel.cpp b/src/qt/walletmodel.cpp index 41deca462..f3f447a42 100644 --- a/src/qt/walletmodel.cpp +++ b/src/qt/walletmodel.cpp @@ -294,18 +294,18 @@ WalletModel::SendCoinsReturn WalletModel::prepareTransaction(WalletModelTransact CWalletTx *newTx = transaction.getTransaction(); CReserveKey *keyChange = transaction.getPossibleKeyChange(); - if(recipients[0].useInstantX && total > sporkManager.GetSporkValue(SPORK_5_INSTANTSEND_MAX_VALUE)*COIN){ + if(recipients[0].fUseInstantSend && total > sporkManager.GetSporkValue(SPORK_5_INSTANTSEND_MAX_VALUE)*COIN){ Q_EMIT message(tr("Send Coins"), tr("InstantSend doesn't support sending values that high yet. Transactions are currently limited to %1 DASH.").arg(sporkManager.GetSporkValue(SPORK_5_INSTANTSEND_MAX_VALUE)), CClientUIInterface::MSG_ERROR); return TransactionCreationFailed; } - bool fCreated = wallet->CreateTransaction(vecSend, *newTx, *keyChange, nFeeRequired, nChangePosRet, strFailReason, coinControl, true, recipients[0].inputType, recipients[0].useInstantX); + bool fCreated = wallet->CreateTransaction(vecSend, *newTx, *keyChange, nFeeRequired, nChangePosRet, strFailReason, coinControl, true, recipients[0].inputType, recipients[0].fUseInstantSend); transaction.setTransactionFee(nFeeRequired); if (fSubtractFeeFromAmount && fCreated) transaction.reassignAmounts(nChangePosRet); - if(recipients[0].useInstantX && newTx->GetValueOut() > sporkManager.GetSporkValue(SPORK_5_INSTANTSEND_MAX_VALUE)*COIN){ + if(recipients[0].fUseInstantSend && newTx->GetValueOut() > sporkManager.GetSporkValue(SPORK_5_INSTANTSEND_MAX_VALUE)*COIN){ Q_EMIT message(tr("Send Coins"), tr("InstantSend doesn't support sending values that high yet. Transactions are currently limited to %1 DASH.").arg(sporkManager.GetSporkValue(SPORK_5_INSTANTSEND_MAX_VALUE)), CClientUIInterface::MSG_ERROR); return TransactionCreationFailed; @@ -369,7 +369,7 @@ WalletModel::SendCoinsReturn WalletModel::sendCoins(WalletModelTransaction &tran CReserveKey *keyChange = transaction.getPossibleKeyChange(); - if(!wallet->CommitTransaction(*newTx, *keyChange, recipients[0].useInstantX ? NetMsgType::IX : NetMsgType::TX)) + if(!wallet->CommitTransaction(*newTx, *keyChange, recipients[0].fUseInstantSend ? NetMsgType::IX : NetMsgType::TX)) return TransactionCommitFailed; CTransaction* t = (CTransaction*)newTx; diff --git a/src/qt/walletmodel.h b/src/qt/walletmodel.h index 0bca129a3..af46af8b5 100644 --- a/src/qt/walletmodel.h +++ b/src/qt/walletmodel.h @@ -51,7 +51,7 @@ public: QString address; QString label; AvailableCoinsType inputType; - bool useInstantX; + bool fUseInstantSend; CAmount amount; // If from a payment request, this is used for storing the memo QString message; diff --git a/src/wallet/rpcwallet.cpp b/src/wallet/rpcwallet.cpp index a1d60ec6c..31913290f 100644 --- a/src/wallet/rpcwallet.cpp +++ b/src/wallet/rpcwallet.cpp @@ -371,7 +371,7 @@ UniValue getaddressesbyaccount(const UniValue& params, bool fHelp) return ret; } -static void SendMoney(const CTxDestination &address, CAmount nValue, bool fSubtractFeeFromAmount, CWalletTx& wtxNew, bool fUseIX=false, bool fUseDS=false) +static void SendMoney(const CTxDestination &address, CAmount nValue, bool fSubtractFeeFromAmount, CWalletTx& wtxNew, bool fUseInstantSend=false, bool fUsePrivateSend=false) { CAmount curBalance = pwalletMain->GetBalance(); @@ -394,12 +394,12 @@ static void SendMoney(const CTxDestination &address, CAmount nValue, bool fSubtr CRecipient recipient = {scriptPubKey, nValue, fSubtractFeeFromAmount}; vecSend.push_back(recipient); if (!pwalletMain->CreateTransaction(vecSend, wtxNew, reservekey, nFeeRequired, nChangePosRet, - strError, NULL, true, fUseDS ? ONLY_DENOMINATED : ALL_COINS, fUseIX)) { + strError, NULL, true, fUsePrivateSend ? ONLY_DENOMINATED : ALL_COINS, fUseInstantSend)) { if (!fSubtractFeeFromAmount && nValue + nFeeRequired > pwalletMain->GetBalance()) strError = strprintf("Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds!", FormatMoney(nFeeRequired)); throw JSONRPCError(RPC_WALLET_ERROR, strError); } - if (!pwalletMain->CommitTransaction(wtxNew, reservekey, fUseIX ? NetMsgType::IX : NetMsgType::TX)) + if (!pwalletMain->CommitTransaction(wtxNew, reservekey, fUseInstantSend ? NetMsgType::IX : NetMsgType::TX)) throw JSONRPCError(RPC_WALLET_ERROR, "Error: The transaction was rejected! This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here."); } @@ -456,16 +456,16 @@ UniValue sendtoaddress(const UniValue& params, bool fHelp) if (params.size() > 4) fSubtractFeeFromAmount = params[4].get_bool(); - bool fUseIX = false; - bool fUseDS = false; + bool fUseInstantSend = false; + bool fUsePrivateSend = false; if (params.size() > 5) - fUseIX = params[5].get_bool(); + fUseInstantSend = params[5].get_bool(); if (params.size() > 6) - fUseDS = params[6].get_bool(); + fUsePrivateSend = params[6].get_bool(); EnsureWalletIsUnlocked(); - SendMoney(address.Get(), nAmount, fSubtractFeeFromAmount, wtx, fUseIX, fUseDS); + SendMoney(address.Get(), nAmount, fSubtractFeeFromAmount, wtx, fUseInstantSend, fUsePrivateSend); return wtx.GetHash().GetHex(); } @@ -1112,18 +1112,18 @@ UniValue sendmany(const UniValue& params, bool fHelp) CAmount nFeeRequired = 0; int nChangePosRet = -1; string strFailReason; - bool fUseIX = false; - bool fUseDS = false; + bool fUseInstantSend = false; + bool fUsePrivateSend = false; if (params.size() > 5) - fUseIX = params[5].get_bool(); + fUseInstantSend = params[5].get_bool(); if (params.size() > 6) - fUseDS = params[6].get_bool(); + fUsePrivateSend = params[6].get_bool(); bool fCreated = pwalletMain->CreateTransaction(vecSend, wtx, keyChange, nFeeRequired, nChangePosRet, strFailReason, - NULL, true, fUseDS ? ONLY_DENOMINATED : ALL_COINS, fUseIX); + NULL, true, fUsePrivateSend ? ONLY_DENOMINATED : ALL_COINS, fUseInstantSend); if (!fCreated) throw JSONRPCError(RPC_WALLET_INSUFFICIENT_FUNDS, strFailReason); - if (!pwalletMain->CommitTransaction(wtx, keyChange, fUseIX ? NetMsgType::IX : NetMsgType::TX)) + if (!pwalletMain->CommitTransaction(wtx, keyChange, fUseInstantSend ? NetMsgType::IX : NetMsgType::TX)) throw JSONRPCError(RPC_WALLET_ERROR, "Transaction commit failed"); return wtx.GetHash().GetHex(); diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp index d15d869cc..08de7dce0 100644 --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -2105,7 +2105,7 @@ CAmount CWallet::GetImmatureWatchOnlyBalance() const return nTotal; } -void CWallet::AvailableCoins(vector& vCoins, bool fOnlyConfirmed, const CCoinControl *coinControl, bool fIncludeZeroValue, AvailableCoinsType coin_type, bool useIX) const +void CWallet::AvailableCoins(vector& vCoins, bool fOnlyConfirmed, const CCoinControl *coinControl, bool fIncludeZeroValue, AvailableCoinsType coin_type, bool fUseInstantSend) const { vCoins.clear(); @@ -2127,7 +2127,7 @@ void CWallet::AvailableCoins(vector& vCoins, bool fOnlyConfirmed, const int nDepth = pcoin->GetDepthInMainChain(false); // do not use IX for inputs that have less then 6 blockchain confirmations - if (useIX && nDepth < 6) + if (fUseInstantSend && nDepth < 6) continue; // We should not consider coins which aren't at least in our mempool @@ -2362,12 +2362,12 @@ bool CWallet::SelectCoinsMinConf(const CAmount& nTargetValue, int nConfMine, int return true; } -bool CWallet::SelectCoins(const CAmount& nTargetValue, set >& setCoinsRet, CAmount& nValueRet, const CCoinControl* coinControl, AvailableCoinsType coin_type, bool useIX) const +bool CWallet::SelectCoins(const CAmount& nTargetValue, set >& setCoinsRet, CAmount& nValueRet, const CCoinControl* coinControl, AvailableCoinsType coin_type, bool fUseInstantSend) const { // Note: this function should never be used for "always free" tx types like dstx vector vCoins; - AvailableCoins(vCoins, true, coinControl, false, coin_type, useIX); + AvailableCoins(vCoins, true, coinControl, false, coin_type, fUseInstantSend); // coin control -> return all selected outputs (we want all selected to go into the transaction for sure) if (coinControl && coinControl->HasSelected() && !coinControl->fAllowOtherInputs) @@ -2910,17 +2910,17 @@ bool CWallet::CreateCollateralTransaction(CMutableTransaction& txCollateral, std return true; } -bool CWallet::GetBudgetSystemCollateralTX(CTransaction& tx, uint256 hash, bool useIX) +bool CWallet::GetBudgetSystemCollateralTX(CTransaction& tx, uint256 hash, bool fUseInstantSend) { CWalletTx wtx; - if(GetBudgetSystemCollateralTX(wtx, hash, useIX)){ + if(GetBudgetSystemCollateralTX(wtx, hash, fUseInstantSend)){ tx = (CTransaction)wtx; return true; } return false; } -bool CWallet::GetBudgetSystemCollateralTX(CWalletTx& tx, uint256 hash, bool useIX) +bool CWallet::GetBudgetSystemCollateralTX(CWalletTx& tx, uint256 hash, bool fUseInstantSend) { // make our change address CReserveKey reservekey(pwalletMain); @@ -2935,7 +2935,7 @@ bool CWallet::GetBudgetSystemCollateralTX(CWalletTx& tx, uint256 hash, bool useI vecSend.push_back((CRecipient){scriptChange, GOVERNANCE_FEE_TX, false}); CCoinControl *coinControl=NULL; - bool success = CreateTransaction(vecSend, tx, reservekey, nFeeRet, nChangePosRet, strFail, coinControl, true, ALL_COINS, useIX); + bool success = CreateTransaction(vecSend, tx, reservekey, nFeeRet, nChangePosRet, strFail, coinControl, true, ALL_COINS, fUseInstantSend); if(!success){ LogPrintf("GetBudgetSystemCollateralTX: Error - %s\n", strFail); return false; @@ -2962,9 +2962,9 @@ bool CWallet::ConvertList(std::vector vCoins, std::vector& vecAm } bool CWallet::CreateTransaction(const vector& vecSend, CWalletTx& wtxNew, CReserveKey& reservekey, CAmount& nFeeRet, - int& nChangePosRet, std::string& strFailReason, const CCoinControl* coinControl, bool sign, AvailableCoinsType coin_type, bool useIX) + int& nChangePosRet, std::string& strFailReason, const CCoinControl* coinControl, bool sign, AvailableCoinsType coin_type, bool fUseInstantSend) { - CAmount nFeePay = useIX ? INSTANTSEND_MIN_FEE : 0; + CAmount nFeePay = fUseInstantSend ? INSTANTSEND_MIN_FEE : 0; CAmount nValue = 0; unsigned int nSubtractFeeFromAmount = 0; @@ -3012,7 +3012,7 @@ bool CWallet::CreateTransaction(const vector& vecSend, CWalletTx& wt // nLockTime that preclude a fix later. // FIXME: "compatibility mode" for 12.0 IX, make it "txNew.nLockTime = chainActive.Height();" again in 12.2 - txNew.nLockTime = useIX ? 0 : chainActive.Height(); + txNew.nLockTime = fUseInstantSend ? 0 : chainActive.Height(); // Secondly occasionally randomly pick a nLockTime even further back, so // that transactions that are delayed after signing for whatever reason, @@ -3078,7 +3078,7 @@ bool CWallet::CreateTransaction(const vector& vecSend, CWalletTx& wt set > setCoins; CAmount nValueIn = 0; - if (!SelectCoins(nValueToSelect, setCoins, nValueIn, coinControl, coin_type, useIX)) + if (!SelectCoins(nValueToSelect, setCoins, nValueIn, coinControl, coin_type, fUseInstantSend)) { if(coin_type == ALL_COINS) { strFailReason = _("Insufficient funds."); @@ -3091,7 +3091,7 @@ bool CWallet::CreateTransaction(const vector& vecSend, CWalletTx& wt strFailReason += " " + _("PrivateSend uses exact denominated amounts to send funds, you might simply need to anonymize some more coins."); } - if(useIX){ + if(fUseInstantSend){ strFailReason += " " + _("InstantSend requires inputs with at least 6 confirmations, you might need to wait a few minutes and try again."); } diff --git a/src/wallet/wallet.h b/src/wallet/wallet.h index a58886e3b..db949cd2a 100644 --- a/src/wallet/wallet.h +++ b/src/wallet/wallet.h @@ -518,7 +518,7 @@ private: * all coins from coinControl are selected; Never select unconfirmed coins * if they are not ours */ - bool SelectCoins(const CAmount& nTargetValue, std::set >& setCoinsRet, CAmount& nValueRet, const CCoinControl *coinControl = NULL, AvailableCoinsType coin_type=ALL_COINS, bool useIX = true) const; + bool SelectCoins(const CAmount& nTargetValue, std::set >& setCoinsRet, CAmount& nValueRet, const CCoinControl *coinControl = NULL, AvailableCoinsType coin_type=ALL_COINS, bool fUseInstantSend = true) const; CWalletDB *pwalletdbEncryption; @@ -637,7 +637,7 @@ public: /** * populate vCoins with vector of available COutputs. */ - void AvailableCoins(std::vector& vCoins, bool fOnlyConfirmed=true, const CCoinControl *coinControl = NULL, bool fIncludeZeroValue=false, AvailableCoinsType coin_type=ALL_COINS, bool useIX = false) const; + void AvailableCoins(std::vector& vCoins, bool fOnlyConfirmed=true, const CCoinControl *coinControl = NULL, bool fIncludeZeroValue=false, AvailableCoinsType coin_type=ALL_COINS, bool fUseInstantSend = false) const; /** * Shuffle and select coins until nTargetValue is reached while avoiding @@ -752,8 +752,8 @@ public: CAmount GetNeedsToBeAnonymizedBalance(CAmount nMinBalance = 0) const; CAmount GetDenominatedBalance(bool unconfirmed=false) const; - bool GetBudgetSystemCollateralTX(CTransaction& tx, uint256 hash, bool useIX); - bool GetBudgetSystemCollateralTX(CWalletTx& tx, uint256 hash, bool useIX); + bool GetBudgetSystemCollateralTX(CTransaction& tx, uint256 hash, bool fUseInstantSend); + bool GetBudgetSystemCollateralTX(CWalletTx& tx, uint256 hash, bool fUseInstantSend); /** * Insert additional inputs into the transaction by @@ -766,7 +766,7 @@ public: * selected by SelectCoins(); Also create the change output, when needed */ bool CreateTransaction(const std::vector& vecSend, CWalletTx& wtxNew, CReserveKey& reservekey, CAmount& nFeeRet, int& nChangePosRet, - std::string& strFailReason, const CCoinControl *coinControl = NULL, bool sign = true, AvailableCoinsType coin_type=ALL_COINS, bool useIX=false); + std::string& strFailReason, const CCoinControl *coinControl = NULL, bool sign = true, AvailableCoinsType coin_type=ALL_COINS, bool fUseInstantSend=false); bool CommitTransaction(CWalletTx& wtxNew, CReserveKey& reservekey, std::string strCommand="tx"); std::string PrepareDarksendDenominate(int minRounds, int maxRounds);