bitcoin/bitcoin — pull request #1019 by laanwj (2012-03-31 14:03:17+00:00)
Title: Streamline UI ↔ Core interface

This is a grab-bag of commits designed to streamline the UI↔Core interface. It contains various small improvements as well as code cleanups:

Improvements

- support RPC stop and encryptwallet with UI by queuing shutdown in UI thread (functionality in case of bitcoind is unchanged)
- update UI only when needed, instead of polling with a timer (core notifies UI using AddressBookRepaint / MainFrameRepaint functions)
- This fixes the issue with address created using RPC 'getnewaddress' not appearing in UI address book
- use a messagebox to display the error when -server is provided without providing rpcpassword, this doesn't get lost like a message to the console (functionality in case of bitcoind is unchanged)

Code cleanups:

- move QT_PLUGINS stuff to qt main file, where it belongs
- move translation function _ to qtui.h/noui.h instead of util.h
- remove dependency on serialize.h and util.h for SecureString by moving allocators to new include file allocators.h. Avoids having to include the whole shebang just to get SecureString.
- remove broken and/or unnecessary functions from qtui.h/noui.h, clarify names, and leave only one MessageBox function that can be used both from AppInit2 and other threads

In principle, these commits are fairly independent and could be separate pull requests if necessary.