Watchonly balances are shown separately in gui.

This commit is contained in:
JaSK
2014-03-29 05:15:28 +01:00
parent 2935b21103
commit ffd40da361
14 changed files with 597 additions and 233 deletions

View File

@@ -45,7 +45,8 @@ QList<TransactionRecord> TransactionRecord::decomposeTransaction(const CWallet *
//
BOOST_FOREACH(const CTxOut& txout, wtx.vout)
{
if(wallet->IsMine(txout))
isminetype mine = wallet->IsMine(txout);
if(mine)
{
TransactionRecord sub(hash, nTime);
CTxDestination address;
@@ -75,13 +76,19 @@ QList<TransactionRecord> TransactionRecord::decomposeTransaction(const CWallet *
}
else
{
bool fAllFromMe = true;
isminetype fAllFromMe = MINE_SPENDABLE;
BOOST_FOREACH(const CTxIn& txin, wtx.vin)
fAllFromMe = fAllFromMe && wallet->IsMine(txin);
{
isminetype mine = wallet->IsMine(txin);
if(fAllFromMe > mine) fAllFromMe = mine;
}
bool fAllToMe = true;
isminetype fAllToMe = MINE_SPENDABLE;
BOOST_FOREACH(const CTxOut& txout, wtx.vout)
fAllToMe = fAllToMe && wallet->IsMine(txout);
{
isminetype mine = wallet->IsMine(txout);
if(fAllToMe > mine) fAllToMe = mine;
}
if (fAllFromMe && fAllToMe)
{