aboutsummaryrefslogtreecommitdiff
path: root/src/qt/walletmodel.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Persistently poll for balance change when number of blocks changedWladimir J. van der Laan2012-07-111-15/+10
| | | | | | Fixes #1452. Until we can make the logic water-tight *and* are notified in every case the balance might have changed, remove the premature optimization and simply recompute the balance every half a second when the number of blocks changed.
* Add a timer to check for changes in immature or unconfirmed balances,Scott Ellis2012-07-061-13/+43
| | | | when these are non-zero. Fixed a minor mem leak.
* Merge pull request #837 from sje397/ShowImmatureBalanceWladimir J. van der Laan2012-06-021-3/+12
|\ | | | | Added 'immature balance' for miners. Only displayed if the balance is > 0
| * Added 'immature balance' for miners. Only displayed if the balance is ↵sje3972012-05-251-3/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | greater than zero. This adds a field labelled 'Immature' in the overview section under the 'unconfirmed' field, which shows mined income that has not yet matured (which is currently not displayed anywhere, even though the transactions exist in the transaction list). To do that I added a 'GetImmatureBalance' method to the wallet, and connected that through to the GUI as per the 'GetBalance' and 'GetUnconfirmedBalance' methods. I did a small 'no-op' change to make the code in adjacent functions a little more readable (imo); it was a change I had made in my repo earlier...but I thought it wouldn't hurt so left it in. Immature balance comes from mined income that is at least two blocks deep in the chain (same logic as displayed transactions). My reasoning is: - as a miner, it's a critical stat I want to see - as a miner, and taking into account the label 'immature', the uncertainty is pretty clearly implied - those numbers are already displayed in the transaction list - this makes the overview numbers add up to what's in the transaction list - it's not displayed if the immature balance is 0, so won't bother non-miners I also 'cleaned' the overview UI a little, moving code to the XML and removing HTML.
* | Refactor: split CKeyID/CScriptID/CTxDestination from CBitcoinAddressPieter Wuille2012-05-241-6/+8
|/ | | | | | | | | | | | | | | | | This introduces internal types: * CKeyID: reference (hash160) of a key * CScriptID: reference (hash160) of a script * CTxDestination: a boost::variant of the former two CBitcoinAddress is retrofitted to be a Base58 encoding of a CTxDestination. This allows all internal code to only use the internal types, and only have RPC and GUI depend on the base58 code. Furthermore, the header dependencies are a lot saner now. base58.h is at the top (right below rpc and gui) instead of at the bottom. For the rest: wallet -> script -> keystore -> key. Only keystore still requires a forward declaration of CScript. Solving that would require splitting script into two layers.
* Process address book updates incrementallyWladimir J. van der Laan2012-05-201-6/+7
| | | | | - No longer invalidates selection model, thus retains selection on address book changes - Fixes selection of new address when added
* Convert UI interface to boost::signals2.Wladimir J. van der Laan2012-05-201-1/+48
| | | | | | | | - Signals now go directly from the core to WalletModel/ClientModel. - WalletModel subscribes to signals on CWallet: Prepares for multi-wallet support, by no longer assuming an implicit global wallet. - Gets rid of noui.cpp, the few lines that were left are merged into init.cpp - Rename wxXXX message flags to MF_XXX, to make them UI indifferent. - ThreadSafeMessageBox no longer returns the value `4` which was never used, converted to void.
* Fine-grained UI updatesWladimir J. van der Laan2012-05-201-8/+16
| | | | | | | | | | | | | | | | | | | Gets rid of `MainFrameRepaint` in favor of specific update functions that tell the UI exactly what changed. This improves the efficiency of various handlers. Also fixes problems with mined transactions not showing up until restart. The following notifications were added: - `NotifyBlocksChanged`: Block chain changed - `NotifyKeyStoreStatusChanged`: Wallet status (encrypted, locked) changed. - `NotifyAddressBookChanged`: Address book entry changed. - `NotifyTransactionChanged`: Wallet transaction added, removed or updated. - `NotifyNumConnectionsChanged`: Number of connections changed. - `NotifyAlertChanged`: New, updated or cancelled alert. As this finally makes it possible for the UI to know when a new alert arrived, it can be shown as OS notification. These notifications could also be useful for RPC clients. However, currently, they are ignored in bitcoind (in noui.cpp). Also brings back polling with timer for numBlocks in ClientModel. This value updates so frequently during initial download that the number of signals clogs the UI thread and causes heavy CPU usage. And after initial block download, the value changes so rarely that a delay of half a second until the UI updates is unnoticable.
* fix #952 by checking if we have a new address or an updated labelPhilip Kaufmann2012-05-041-3/+10
|
* Fix critical UI performance issue (#1154)Wladimir J. van der Laan2012-04-291-2/+0
|
* Further reduce header dependenciesPieter Wuille2012-04-171-0/+1
| | | | | | | This commit removes the dependency of serialize.h on PROTOCOL_VERSION, and makes this parameter required instead of implicit. This is much saner, as it makes the places where changing a version number can have an influence obvious.
* Move CWalletDB code to new walletdb module.Jeff Garzik2012-04-171-1/+1
| | | | | In addition to standard code separation, this change opens the door to fixing several include inter-dependencies.
* Remove headers.hPieter Wuille2012-04-171-1/+1
|
* Use scoped locks instead of CRITICAL_BLOCKPieter Wuille2012-04-091-5/+5
|
* qtui.h/noui.h interface cleanupWladimir J. van der Laan2012-04-041-1/+1
| | | | | | | - rename wxMessageBox, remove redundant arguments to noui/qtui calls - also, add flag to force blocking, modal dialog box for disk space warning etc - clarify function naming - no more special MessageBox needed from AppInit2, as window object is created before calling AppInit2
* Update UI through async calls MainFrameRepaint and AddressBookRepaint ↵Wladimir J. van der Laan2012-04-041-10/+5
| | | | | | | | instead of a timer. - Overall, this is better design - This fixes problems with the address book UI not updating when the address book is changed through RPC - Move Statusbar change detection responsibility to ClientModel
* Added 'Backup Wallet' menu optionsje3972012-02-151-0/+6
| | | | | | | | - icon from the LGPL Nuvola set (like the tick) - http://www.icon-king.com/projects/nuvola/ - include 'boost/version.hpp' in db.cpp so that the overwrite version of copy can be used - catch exceptions in BackupWallet (e.g. filesystem_error thrown when trying to overwrite without the overwrite flag set) - include db.h in walletmodel.cpp for BackupWallet function - updated doc/assets-attribution.txt and contrib/debian/copyright with copyright info for new icon
* Revert "Use standard C99 (and Qt) types for 64-bit integers"Wladimir J. van der Laan2011-12-211-3/+2
| | | | This reverts commit 21d9f36781604e4ca9fc35dc65265593423b73e9.
* Use standard C99 (and Qt) types for 64-bit integersLuke Dashjr2011-12-201-2/+3
|
* Implement an mlock()'d string class for storing passphrasesDylan Noblesmith2011-11-261-3/+3
| | | | | | | SecureString is identical to std::string except with secure_allocator substituting for std::allocator. This makes casting between them impossible, so converting between the two at API boundaries requires calling ::c_str() for now.
* update to work with new lock system, add protocol.* to build systemWladimir J. van der Laan2011-09-021-4/+4
|
* Wallet encryption part 2: ask passphrase when needed, add menu optionsWladimir J. van der Laan2011-08-311-0/+76
|
* Wallet encryption part 1: show wallet encryption statusWladimir J. van der Laan2011-08-231-2/+21
|
* QtUI code cleanup / comment improvementsWladimir J. van der Laan2011-08-081-2/+0
|
* comment updateWladimir J. van der Laan2011-07-301-0/+2
|
* make sure address book model is up to date after sending coinsWladimir J. van der Laan2011-07-301-0/+1
|
* Full support for other units, add configuration option for default unit ↵Wladimir J. van der Laan2011-07-291-3/+2
| | | | (used when displaying amounts)
* Merge remote branch 'upstream/master'Wladimir J. van der Laan2011-07-261-4/+3
| | | | | Conflicts: src/bitcoinrpc.cpp
* make initial block download reporting somewhat better by tracking version ↵Wladimir J. van der Laan2011-07-171-6/+15
| | | | responses
* add sendmany supportWladimir J. van der Laan2011-07-161-24/+67
|
* solve warnings at startupWladimir J. van der Laan2011-07-141-1/+1
|
* Show unconfirmed balance on overview pageWladimir J. van der Laan2011-07-111-0/+5
|
* Add context menu on transaction list: copy label, copy address, edit label, ↵Wladimir J. van der Laan2011-07-081-14/+0
| | | | show details
* Send: dialog redesign (automatically look up label for entered address)Wladimir J. van der Laan2011-07-021-0/+16
|
* Split off WalletModel from ClientModel, to be able to support multi-wallets ↵Wladimir J. van der Laan2011-06-301-0/+124
in future