Merge pull request #513 from cjdelisle/feature-hardening
authorGavin Andresen <gavinandresen@gmail.com>
Mon, 26 Sep 2011 13:12:59 +0000 (06:12 -0700)
committerGavin Andresen <gavinandresen@gmail.com>
Mon, 26 Sep 2011 13:12:59 +0000 (06:12 -0700)
Hardening

181 files changed:
.gitignore
README.md
bitcoin-qt.pro [new file with mode: 0644]
contrib/BitcoinTemplate.dmg [new file with mode: 0644]
contrib/create_osx_dmg.sh [new file with mode: 0755]
contrib/gitian-descriptors/boost-win32.yml [moved from contrib/boost-win32.yml with 100% similarity]
contrib/gitian-descriptors/gitian-win32.yml [moved from contrib/gitian-win32.yml with 99% similarity]
contrib/gitian-descriptors/gitian.yml [moved from contrib/gitian.yml with 97% similarity]
contrib/gitian-descriptors/wxwidgets-win32.yml [moved from contrib/wxwidgets-win32.yml with 100% similarity]
contrib/gitian-descriptors/wxwidgets.yml [moved from contrib/wxwidgets.yml with 100% similarity]
contrib/gitian-downloader/bluematt-key.pgp [new file with mode: 0644]
contrib/gitian-downloader/devrandom-key.pgp [new file with mode: 0644]
contrib/gitian-downloader/gavinandresen-key.pgp [new file with mode: 0644]
contrib/gitian-downloader/linux-download-config [new file with mode: 0644]
contrib/gitian-downloader/sipa-key.pgp [new file with mode: 0644]
contrib/gitian-downloader/tcatm-key.pgp [new file with mode: 0644]
contrib/gitian-downloader/win32-download-config [new file with mode: 0644]
contrib/miniupnpc/Portfile [new file with mode: 0644]
doc/assets-attribution.txt [new file with mode: 0644]
doc/build-unix.txt
doc/readme-qt.rst [new file with mode: 0644]
doc/release-process.txt
locale/de/LC_MESSAGES/bitcoin.mo
locale/de/LC_MESSAGES/bitcoin.po
locale/es/LC_MESSAGES/bitcoin.po
locale/nl/LC_MESSAGES/bitcoin.mo
locale/nl/LC_MESSAGES/bitcoin.po
locale/zh_cn/LC_MESSAGES/bitcoin.po
scripts/qt/extract_strings_qt.py [new file with mode: 0755]
scripts/qt/img/reload.xcf [new file with mode: 0644]
scripts/qt/make_spinner.py [new file with mode: 0755]
scripts/qt/make_windows_icon.py [new file with mode: 0755]
share/pixmaps/bitcoin.ico
src/bitcoinrpc.cpp [moved from src/rpc.cpp with 99% similarity]
src/bitcoinrpc.h [moved from src/rpc.h with 100% similarity]
src/headers.h
src/init.cpp
src/main.cpp
src/main.h
src/makefile.linux-mingw
src/makefile.mingw
src/makefile.osx
src/makefile.unix
src/makefile.vc
src/net.cpp
src/net.h
src/noui.h
src/qt/aboutdialog.cpp [new file with mode: 0644]
src/qt/aboutdialog.h [new file with mode: 0644]
src/qt/addressbookpage.cpp [new file with mode: 0644]
src/qt/addressbookpage.h [new file with mode: 0644]
src/qt/addresstablemodel.cpp [new file with mode: 0644]
src/qt/addresstablemodel.h [new file with mode: 0644]
src/qt/askpassphrasedialog.cpp [new file with mode: 0644]
src/qt/askpassphrasedialog.h [new file with mode: 0644]
src/qt/bitcoin.cpp [new file with mode: 0644]
src/qt/bitcoin.qrc [new file with mode: 0644]
src/qt/bitcoinaddressvalidator.cpp [new file with mode: 0644]
src/qt/bitcoinaddressvalidator.h [new file with mode: 0644]
src/qt/bitcoinamountfield.cpp [new file with mode: 0644]
src/qt/bitcoinamountfield.h [new file with mode: 0644]
src/qt/bitcoingui.cpp [new file with mode: 0644]
src/qt/bitcoingui.h [new file with mode: 0644]
src/qt/bitcoinstrings.cpp [new file with mode: 0644]
src/qt/bitcoinunits.cpp [new file with mode: 0644]
src/qt/bitcoinunits.h [new file with mode: 0644]
src/qt/clientmodel.cpp [new file with mode: 0644]
src/qt/clientmodel.h [new file with mode: 0644]
src/qt/csvmodelwriter.cpp [new file with mode: 0644]
src/qt/csvmodelwriter.h [new file with mode: 0644]
src/qt/editaddressdialog.cpp [new file with mode: 0644]
src/qt/editaddressdialog.h [new file with mode: 0644]
src/qt/forms/aboutdialog.ui [new file with mode: 0644]
src/qt/forms/addressbookpage.ui [new file with mode: 0644]
src/qt/forms/askpassphrasedialog.ui [new file with mode: 0644]
src/qt/forms/editaddressdialog.ui [new file with mode: 0644]
src/qt/forms/overviewpage.ui [new file with mode: 0644]
src/qt/forms/sendcoinsdialog.ui [new file with mode: 0644]
src/qt/forms/sendcoinsentry.ui [new file with mode: 0644]
src/qt/forms/transactiondescdialog.ui [new file with mode: 0644]
src/qt/guiconstants.h [new file with mode: 0644]
src/qt/guiutil.cpp [new file with mode: 0644]
src/qt/guiutil.h [new file with mode: 0644]
src/qt/locale/bitcoin_de.ts [new file with mode: 0644]
src/qt/locale/bitcoin_nl.ts [new file with mode: 0644]
src/qt/locale/bitcoin_ru.ts [new file with mode: 0644]
src/qt/monitoreddatamapper.cpp [new file with mode: 0644]
src/qt/monitoreddatamapper.h [new file with mode: 0644]
src/qt/notificator.cpp [new file with mode: 0644]
src/qt/notificator.h [new file with mode: 0644]
src/qt/optionsdialog.cpp [new file with mode: 0644]
src/qt/optionsdialog.h [new file with mode: 0644]
src/qt/optionsmodel.cpp [new file with mode: 0644]
src/qt/optionsmodel.h [new file with mode: 0644]
src/qt/overviewpage.cpp [new file with mode: 0644]
src/qt/overviewpage.h [new file with mode: 0644]
src/qt/qvalidatedlineedit.cpp [new file with mode: 0644]
src/qt/qvalidatedlineedit.h [new file with mode: 0644]
src/qt/qvaluecombobox.cpp [new file with mode: 0644]
src/qt/qvaluecombobox.h [new file with mode: 0644]
src/qt/res/bitcoin-qt.rc [new file with mode: 0644]
src/qt/res/icons/add.png [new file with mode: 0644]
src/qt/res/icons/address-book.png [new file with mode: 0644]
src/qt/res/icons/bitcoin.icns [new file with mode: 0644]
src/qt/res/icons/bitcoin.ico [new file with mode: 0644]
src/qt/res/icons/bitcoin.png [new file with mode: 0644]
src/qt/res/icons/bitcoin_testnet.png [new file with mode: 0644]
src/qt/res/icons/clock1.png [new file with mode: 0644]
src/qt/res/icons/clock2.png [new file with mode: 0644]
src/qt/res/icons/clock3.png [new file with mode: 0644]
src/qt/res/icons/clock4.png [new file with mode: 0644]
src/qt/res/icons/clock5.png [new file with mode: 0644]
src/qt/res/icons/configure.png [new file with mode: 0644]
src/qt/res/icons/connect0_16.png [new file with mode: 0644]
src/qt/res/icons/connect1_16.png [new file with mode: 0644]
src/qt/res/icons/connect2_16.png [new file with mode: 0644]
src/qt/res/icons/connect3_16.png [new file with mode: 0644]
src/qt/res/icons/connect4_16.png [new file with mode: 0644]
src/qt/res/icons/edit.png [new file with mode: 0644]
src/qt/res/icons/editcopy.png [new file with mode: 0644]
src/qt/res/icons/editpaste.png [new file with mode: 0644]
src/qt/res/icons/export.png [new file with mode: 0644]
src/qt/res/icons/history.png [new file with mode: 0644]
src/qt/res/icons/key.png [new file with mode: 0644]
src/qt/res/icons/lock_closed.png [new file with mode: 0644]
src/qt/res/icons/lock_open.png [new file with mode: 0644]
src/qt/res/icons/notsynced.png [new file with mode: 0644]
src/qt/res/icons/overview.png [new file with mode: 0644]
src/qt/res/icons/quit.png [new file with mode: 0644]
src/qt/res/icons/receive.png [new file with mode: 0644]
src/qt/res/icons/remove.png [new file with mode: 0644]
src/qt/res/icons/send.png [new file with mode: 0644]
src/qt/res/icons/synced.png [new file with mode: 0644]
src/qt/res/icons/toolbar.png [new file with mode: 0644]
src/qt/res/icons/toolbar_testnet.png [new file with mode: 0644]
src/qt/res/icons/transaction0.png [new file with mode: 0644]
src/qt/res/icons/transaction2.png [new file with mode: 0644]
src/qt/res/icons/tx_inout.png [new file with mode: 0644]
src/qt/res/icons/tx_input.png [new file with mode: 0644]
src/qt/res/icons/tx_mined.png [new file with mode: 0644]
src/qt/res/icons/tx_output.png [new file with mode: 0644]
src/qt/res/images/about.png [new file with mode: 0644]
src/qt/res/images/splash2.jpg [new file with mode: 0644]
src/qt/res/movies/update_spinner.mng [new file with mode: 0644]
src/qt/res/src/bitcoin.svg [new file with mode: 0644]
src/qt/res/src/clock1.svg [new file with mode: 0644]
src/qt/res/src/clock2.svg [new file with mode: 0644]
src/qt/res/src/clock3.svg [new file with mode: 0644]
src/qt/res/src/clock4.svg [new file with mode: 0644]
src/qt/res/src/clock5.svg [new file with mode: 0644]
src/qt/res/src/clock_green.svg [new file with mode: 0644]
src/qt/res/src/inout.svg [new file with mode: 0644]
src/qt/res/src/questionmark.svg [new file with mode: 0644]
src/qt/sendcoinsdialog.cpp [new file with mode: 0644]
src/qt/sendcoinsdialog.h [new file with mode: 0644]
src/qt/sendcoinsentry.cpp [new file with mode: 0644]
src/qt/sendcoinsentry.h [new file with mode: 0644]
src/qt/transactiondesc.cpp [new file with mode: 0644]
src/qt/transactiondesc.h [new file with mode: 0644]
src/qt/transactiondescdialog.cpp [new file with mode: 0644]
src/qt/transactiondescdialog.h [new file with mode: 0644]
src/qt/transactionfilterproxy.cpp [new file with mode: 0644]
src/qt/transactionfilterproxy.h [new file with mode: 0644]
src/qt/transactionrecord.cpp [new file with mode: 0644]
src/qt/transactionrecord.h [new file with mode: 0644]
src/qt/transactiontablemodel.cpp [new file with mode: 0644]
src/qt/transactiontablemodel.h [new file with mode: 0644]
src/qt/transactionview.cpp [new file with mode: 0644]
src/qt/transactionview.h [new file with mode: 0644]
src/qt/walletmodel.cpp [new file with mode: 0644]
src/qt/walletmodel.h [new file with mode: 0644]
src/qtui.h [new file with mode: 0644]
src/script.cpp
src/serialize.h
src/test/DoS_tests.cpp [new file with mode: 0644]
src/test/test_bitcoin.cpp
src/ui.h
src/util.cpp
src/util.h
src/wallet.cpp
src/wallet.h

index c1d06a3..a5f96ba 100644 (file)
@@ -9,3 +9,16 @@ src/bitcoind
 *.o
 *.patch
 .bitcoin
+#compilation and Qt preprocessor part
+*.o
+ui_*.h
+*.qm
+moc_*
+Makefile
+bitcoin-qt
+#resources cpp
+qrc_*.cpp
+#qt creator
+*.pro.user
+#mac specific
+.DS_Store
index a41eb2d..99710bc 100644 (file)
--- a/README.md
+++ b/README.md
@@ -23,8 +23,7 @@ or are controversial.
 The master branch is regularly built and tested, but is not guaranteed
 to be completely stable. Tags are regularly created to indicate new
 official, stable release versions of Bitcoin. If you would like to
-help test the Bitcoin core, please contact QA@Bitcoin.org.
+help test the Bitcoin core, please contact QA@BitcoinTesting.org.
 
 Feature branches are created when there are major new features being
 worked on by several people.
-
diff --git a/bitcoin-qt.pro b/bitcoin-qt.pro
new file mode 100644 (file)
index 0000000..19d7814
--- /dev/null
@@ -0,0 +1,185 @@
+TEMPLATE = app
+TARGET =
+INCLUDEPATH += src src/json src/cryptopp src/qt
+DEFINES += QT_GUI
+# DEFINES += SSL
+CONFIG += no_include_pwd
+
+# for boost 1.37, add -mt to the boost libraries
+LIBS += -lssl -lcrypto -ldb_cxx
+unix:!macx:LIBS += -lboost_system -lboost_filesystem -lboost_program_options -lboost_thread
+macx:LIBS += -lboost_system-mt -lboost_filesystem-mt -lboost_program_options-mt -lboost_thread-mt
+macx:DEFINES += __WXMAC_OSX__ MSG_NOSIGNAL=0 BOOST_FILESYSTEM_VERSION=3
+windows:LIBS += -lboost_system-mgw44-mt-1_43 -lboost_filesystem-mgw44-mt-1_43 -lboost_program_options-mgw44-mt-1_43 -lboost_thread-mgw44-mt-1_43 -lws2_32 -lgdi32
+windows:DEFINES += __WXMSW__
+windows:RC_FILE = src/qt/res/bitcoin-qt.rc
+
+# use: qmake "USE_UPNP=1"
+# miniupnpc (http://miniupnp.free.fr/files/) must be installed
+count(USE_UPNP, 1) {
+    message(Building with UPNP support)
+    DEFINES += USE_UPNP=$$USE_UPNP
+    LIBS += -lminiupnpc
+}
+
+count(USE_DBUS, 1) {
+    message(Building with DBUS (Freedesktop notifications) support)
+    DEFINES += QT_DBUS
+    QT += dbus
+}
+
+# for extra security against potential buffer overflows
+QMAKE_CXXFLAGS += -fstack-protector 
+QMAKE_LFLAGS += -fstack-protector
+
+# disable quite some warnings because bitcoin core "sins" a lot
+QMAKE_CXXFLAGS_WARN_ON = -fdiagnostics-show-option -Wall -Wno-invalid-offsetof -Wno-unused-variable -Wno-unused-parameter -Wno-sign-compare -Wno-char-subscripts  -Wno-unused-value -Wno-sequence-point -Wno-parentheses -Wno-unknown-pragmas -Wno-switch
+
+# Input
+DEPENDPATH += src/qt src src/cryptopp src json/include
+HEADERS += src/qt/bitcoingui.h \
+    src/qt/transactiontablemodel.h \
+    src/qt/addresstablemodel.h \
+    src/qt/optionsdialog.h \
+    src/qt/sendcoinsdialog.h \
+    src/qt/addressbookpage.h \
+    src/qt/aboutdialog.h \
+    src/qt/editaddressdialog.h \
+    src/qt/bitcoinaddressvalidator.h \
+    src/base58.h \
+    src/bignum.h \
+    src/util.h \
+    src/uint256.h \
+    src/serialize.h \
+    src/cryptopp/stdcpp.h \
+    src/cryptopp/smartptr.h \
+    src/cryptopp/simple.h \
+    src/cryptopp/sha.h \
+    src/cryptopp/secblock.h \
+    src/cryptopp/pch.h \
+    src/cryptopp/misc.h \
+    src/cryptopp/iterhash.h \
+    src/cryptopp/cryptlib.h \
+    src/cryptopp/cpu.h \
+    src/cryptopp/config.h \
+    src/strlcpy.h \
+    src/main.h \
+    src/net.h \
+    src/key.h \
+    src/db.h \
+    src/script.h \
+    src/noui.h \
+    src/init.h \
+    src/headers.h \
+    src/irc.h \
+    src/json/json_spirit_writer_template.h \
+    src/json/json_spirit_writer.h \
+    src/json/json_spirit_value.h \
+    src/json/json_spirit_utils.h \
+    src/json/json_spirit_stream_reader.h \
+    src/json/json_spirit_reader_template.h \
+    src/json/json_spirit_reader.h \
+    src/json/json_spirit_error_position.h \
+    src/json/json_spirit.h \
+    src/qt/clientmodel.h \
+    src/qt/guiutil.h \
+    src/qt/transactionrecord.h \
+    src/qt/guiconstants.h \
+    src/qt/optionsmodel.h \
+    src/qt/monitoreddatamapper.h \
+    src/qtui.h \
+    src/qt/transactiondesc.h \
+    src/qt/transactiondescdialog.h \
+    src/qt/bitcoinamountfield.h \
+    src/wallet.h \
+    src/keystore.h \
+    src/qt/transactionfilterproxy.h \
+    src/qt/transactionview.h \
+    src/qt/walletmodel.h \
+    src/bitcoinrpc.h \
+    src/qt/overviewpage.h \
+    src/qt/csvmodelwriter.h \
+    src/crypter.h \
+    src/qt/sendcoinsentry.h \
+    src/qt/qvalidatedlineedit.h \
+    src/qt/bitcoinunits.h \
+    src/qt/qvaluecombobox.h \
+    src/qt/askpassphrasedialog.h \
+    src/protocol.h \
+    src/qt/notificator.h
+
+SOURCES += src/qt/bitcoin.cpp src/qt/bitcoingui.cpp \
+    src/qt/transactiontablemodel.cpp \
+    src/qt/addresstablemodel.cpp \
+    src/qt/optionsdialog.cpp \
+    src/qt/sendcoinsdialog.cpp \
+    src/qt/addressbookpage.cpp \
+    src/qt/aboutdialog.cpp \
+    src/qt/editaddressdialog.cpp \
+    src/qt/bitcoinaddressvalidator.cpp \
+    src/cryptopp/sha.cpp \
+    src/cryptopp/cpu.cpp \
+    src/util.cpp \
+    src/script.cpp \
+    src/main.cpp \
+    src/init.cpp \
+    src/net.cpp \
+    src/irc.cpp \
+    src/db.cpp \
+    src/json/json_spirit_writer.cpp \
+    src/json/json_spirit_value.cpp \
+    src/json/json_spirit_reader.cpp \
+    src/qt/clientmodel.cpp \
+    src/qt/guiutil.cpp \
+    src/qt/transactionrecord.cpp \
+    src/qt/optionsmodel.cpp \
+    src/qt/monitoreddatamapper.cpp \
+    src/qt/transactiondesc.cpp \
+    src/qt/transactiondescdialog.cpp \
+    src/qt/bitcoinstrings.cpp \
+    src/qt/bitcoinamountfield.cpp \
+    src/wallet.cpp \
+    src/keystore.cpp \
+    src/qt/transactionfilterproxy.cpp \
+    src/qt/transactionview.cpp \
+    src/qt/walletmodel.cpp \
+    src/bitcoinrpc.cpp \
+    src/qt/overviewpage.cpp \
+    src/qt/csvmodelwriter.cpp \
+    src/crypter.cpp \
+    src/qt/sendcoinsentry.cpp \
+    src/qt/qvalidatedlineedit.cpp \
+    src/qt/bitcoinunits.cpp \
+    src/qt/qvaluecombobox.cpp \
+    src/qt/askpassphrasedialog.cpp \
+    src/protocol.cpp \
+    src/qt/notificator.cpp
+
+RESOURCES += \
+    src/qt/bitcoin.qrc
+
+FORMS += \
+    src/qt/forms/sendcoinsdialog.ui \
+    src/qt/forms/addressbookpage.ui \
+    src/qt/forms/aboutdialog.ui \
+    src/qt/forms/editaddressdialog.ui \
+    src/qt/forms/transactiondescdialog.ui \
+    src/qt/forms/overviewpage.ui \
+    src/qt/forms/sendcoinsentry.ui \
+    src/qt/forms/askpassphrasedialog.ui
+
+CODECFORTR = UTF-8
+# for lrelease/lupdate
+TRANSLATIONS = src/qt/locale/bitcoin_nl.ts src/qt/locale/bitcoin_de.ts \
+               src/qt/locale/bitcoin_ru.ts
+
+OTHER_FILES += \
+    README.rst
+
+# For use with MacPorts
+macx:INCLUDEPATH += /opt/local/include /opt/local/include/db48
+macx:LIBS += -L/opt/local/lib -L/opt/local/lib/db48
+
+# Additional Mac options
+macx:ICON = src/qt/res/icons/bitcoin.icns
+macx:TARGET = "Bitcoin Qt"
diff --git a/contrib/BitcoinTemplate.dmg b/contrib/BitcoinTemplate.dmg
new file mode 100644 (file)
index 0000000..ca86308
Binary files /dev/null and b/contrib/BitcoinTemplate.dmg differ
diff --git a/contrib/create_osx_dmg.sh b/contrib/create_osx_dmg.sh
new file mode 100755 (executable)
index 0000000..af164e5
--- /dev/null
@@ -0,0 +1,60 @@
+#!/usr/bin/env bash
+# 
+# Creates a Bitcoin.dmg OSX file from the contrib/BitcoinTemplate.dmg file
+#
+# Recipe from: http://digital-sushi.org/entry/how-to-create-a-disk-image-installer-for-apple-mac-os-x/
+#
+# To make a prettier BitcoinTemplate.dmg:
+#  + open (mount) BitcoinTemplate.dmg
+#  + change the file properties, icon positions, background image, etc
+#  + eject, then commit the changed BitcoinTemplate.dmg
+#
+
+CWD=$(pwd)
+
+if [ $# -lt 1 ]; then
+    if [ $(basename $CWD) == "contrib" ]
+    then
+        TOP=$(dirname $CWD)
+    else
+        echo "Usage: $0 /path/to/bitcoin/tree"
+        exit 1
+    fi
+else
+    TOP=$1
+fi
+
+CONTRIB=$TOP/contrib
+BUILD_DIR=/tmp/bitcoin_osx_build
+
+# First, compile bitcoin and bitcoind
+cd "$TOP/src"
+if [ ! -e bitcoin ]; then make -f makefile.osx bitcoin; fi
+if [ ! -e bitcoind ]; then make -f makefile.osx bitcoind; fi
+strip bitcoin bitcoind
+
+mkdir -p "$BUILD_DIR"
+cd "$BUILD_DIR"
+
+rm -f Bitcoin.sparseimage
+hdiutil convert "$CONTRIB/BitcoinTemplate.dmg" -format UDSP -o Bitcoin
+hdiutil mount Bitcoin.sparseimage
+
+# Copy over placeholders in /Volumes/Bitcoin
+cp "$TOP/src/bitcoind" /Volumes/Bitcoin/
+cp "$TOP/src/bitcoin" /Volumes/Bitcoin/Bitcoin.app/Contents/MacOS/
+
+# Create source code .zip
+cd "$TOP"
+git archive -o /Volumes/Bitcoin/bitcoin.zip $(git branch 2>/dev/null|grep -e ^* | cut -d ' ' -f 2)
+
+# Fix permissions
+chmod -Rf go-w /Volumes/Bitcoin
+
+cd "$BUILD_DIR"
+hdiutil eject /Volumes/Bitcoin
+rm -f "$CWD/Bitcoin.dmg"
+hdiutil convert Bitcoin.sparseimage -format UDBZ -o "$CWD/Bitcoin.dmg"
+
+cd "$CWD"
+rm -rf "$BUILD_DIR"
similarity index 99%
rename from contrib/gitian-win32.yml
rename to contrib/gitian-descriptors/gitian-win32.yml
index 963c381..52b10bc 100644 (file)
@@ -10,6 +10,7 @@ packages:
 - "unzip"
 - "nsis"
 - "faketime"
+- "wine"
 reference_datetime: "2011-01-30 00:00:00"
 remotes:
 - "url": "https://github.com/bitcoin/bitcoin.git"
similarity index 97%
rename from contrib/gitian.yml
rename to contrib/gitian-descriptors/gitian.yml
index 8d0abf8..efa9cb8 100644 (file)
@@ -34,7 +34,7 @@ script: |
   mkdir wxWidgets-2.9.2
   cd wxWidgets-2.9.2
   unzip ../wxWidgets-2.9.2-x32-gitian.zip
-  unzip -f ../wxWidgets-2.9.2-x64-gitian.zip
+  unzip -o ../wxWidgets-2.9.2-x64-gitian.zip
   cp -a bin/$GBUILD_BITS/wx/config/gtk2-unicode-static-2.9 $INSTDIR/bin/wx-config
   for lib in wx_gtk2u wxregexu wxtiff; do
     ar rc $INSTDIR/lib/lib${lib}-2.9.a bin/$GBUILD_BITS/$lib/*.o
diff --git a/contrib/gitian-downloader/bluematt-key.pgp b/contrib/gitian-downloader/bluematt-key.pgp
new file mode 100644 (file)
index 0000000..fb6d9eb
Binary files /dev/null and b/contrib/gitian-downloader/bluematt-key.pgp differ
diff --git a/contrib/gitian-downloader/devrandom-key.pgp b/contrib/gitian-downloader/devrandom-key.pgp
new file mode 100644 (file)
index 0000000..7189812
Binary files /dev/null and b/contrib/gitian-downloader/devrandom-key.pgp differ
diff --git a/contrib/gitian-downloader/gavinandresen-key.pgp b/contrib/gitian-downloader/gavinandresen-key.pgp
new file mode 100644 (file)
index 0000000..f81f44e
Binary files /dev/null and b/contrib/gitian-downloader/gavinandresen-key.pgp differ
diff --git a/contrib/gitian-downloader/linux-download-config b/contrib/gitian-downloader/linux-download-config
new file mode 100644 (file)
index 0000000..d21bb07
--- /dev/null
@@ -0,0 +1,30 @@
+--- 
+name: bitcoin
+urls:
+- http://bitcoin.org/bitcoin-latest-linux-gitian.zip
+rss:
+- url: http://sourceforge.net/api/file/index/project-id/244765/mtime/desc/limit/100/rss
+  xpath: //item/link/text()
+  pattern: bitcoin-\d+.\d+.\d+-linux-gitian.zip
+signers:
+  0A82509767C7D4A5D14DA2301AE1D35043E08E54:
+    weight: 40
+    name: BlueMatt
+    key: bluematt
+  BF6273FAEF7CC0BA1F562E50989F6B3048A116B5:
+    weight: 40
+    name: Devrandom
+    key: devrandom
+  D762373D24904A3E42F33B08B9A408E71DAAC974:
+    weight: 40
+    name: Sipa
+    key: sipa
+  77E72E69DA7EE0A148C06B21B34821D4944DE5F7:
+    weight: 40
+    name: tcatm
+    key: tcatm
+  01CDF4627A3B88AAE4A571C87588242FBE38D3A8:
+    weight: 40
+    name: "Gavin Andresen"
+    key: gavinandresen
+minimum_weight: 120
diff --git a/contrib/gitian-downloader/sipa-key.pgp b/contrib/gitian-downloader/sipa-key.pgp
new file mode 100644 (file)
index 0000000..086c9eb
Binary files /dev/null and b/contrib/gitian-downloader/sipa-key.pgp differ
diff --git a/contrib/gitian-downloader/tcatm-key.pgp b/contrib/gitian-downloader/tcatm-key.pgp
new file mode 100644 (file)
index 0000000..baaec76
Binary files /dev/null and b/contrib/gitian-downloader/tcatm-key.pgp differ
diff --git a/contrib/gitian-downloader/win32-download-config b/contrib/gitian-downloader/win32-download-config
new file mode 100644 (file)
index 0000000..c0de21c
--- /dev/null
@@ -0,0 +1,30 @@
+--- 
+name: bitcoin
+urls:
+- http://bitcoin.org/bitcoin-latest-win32-gitian.zip
+rss:
+- url: http://sourceforge.net/api/file/index/project-id/244765/mtime/desc/limit/100/rss
+  xpath: //item/link/text()
+  pattern: bitcoin-\d+.\d+.\d+-win32-gitian.zip
+signers:
+  0A82509767C7D4A5D14DA2301AE1D35043E08E54:
+    weight: 40
+    name: BlueMatt
+    key: bluematt
+  BF6273FAEF7CC0BA1F562E50989F6B3048A116B5:
+    weight: 40
+    name: Devrandom
+    key: devrandom
+  D762373D24904A3E42F33B08B9A408E71DAAC974:
+    weight: 40
+    name: Sipa
+    key: sipa
+  77E72E69DA7EE0A148C06B21B34821D4944DE5F7:
+    weight: 40
+    name: tcatm
+    key: tcatm
+  01CDF4627A3B88AAE4A571C87588242FBE38D3A8:
+    weight: 40
+    name: "Gavin Andresen"
+    key: gavinandresen
+minimum_weight: 120
diff --git a/contrib/miniupnpc/Portfile b/contrib/miniupnpc/Portfile
new file mode 100644 (file)
index 0000000..133aee5
--- /dev/null
@@ -0,0 +1,43 @@
+# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
+# $Id$
+
+PortSystem          1.0
+
+name                miniupnpc
+epoch               2
+version             1.6
+revision            2
+categories          net
+platforms           darwin
+license             BSD
+maintainers         singingwolfboy openmaintainer
+description         Lightweight client for UPnP protocol
+long_description    \
+    ${description}
+    
+homepage            http://miniupnp.free.fr/
+master_sites        http://miniupnp.free.fr/files/download.php?file=${distname}${extract.suffix}&dummy=
+checksums           md5     88055f2d4a061cfd4cfe25a9eae22f67 \
+                    sha1    ef8f2edb17f2e7c5b8dc67ee80a65c199d823e0a \
+                    rmd160  d86b75b331a3fb5525c71708548f311977c0598f
+
+use_configure       no
+
+variant universal {}
+if {[variant_isset universal]} {
+    set archflags ${configure.universal_cflags}
+} else {
+    set archflags ${configure.cc_archflags}
+}
+
+build.args-append   CC="${configure.cc} ${archflags}"
+
+post-patch {
+    reinplace "s|-Wl,-install_name,|-Wl,-install_name,${prefix}/lib/|" ${worksrcpath}/Makefile
+}
+
+destroot.destdir    PREFIX=${prefix} INSTALLPREFIX=${destroot}${prefix}
+
+livecheck.type      regex
+livecheck.url       http://miniupnp.free.fr/files/
+livecheck.regex     ${name}-(\\d+(\\.\\d{1,4})+)${extract.suffix}
diff --git a/doc/assets-attribution.txt b/doc/assets-attribution.txt
new file mode 100644 (file)
index 0000000..91d2e65
--- /dev/null
@@ -0,0 +1,73 @@
+Icon: src/qt/res/icons/clock*.png, src/qt/res/icons/tx*.png,
+      src/qt/res/src/*.svg
+Designer: Wladimir van der Laan
+License: Creative Commons Attribution
+
+Icon: src/qt/res/icons/send.png
+Icon Pack: Vista Style Arrow
+Designer: Icons Land
+License: Freeware Non-commercial
+Site: http://findicons.com/icon/231371/right3green
+
+Icon: src/qt/res/icons/address-book.png
+Icon Pack: Farm-Fresh Web
+Designer: FatCow Web Hosting
+License: Creative Commons Attribution (by)
+Site: http://findicons.com/icon/163938/book_open
+
+Icon: src/qt/res/icons/connect*.png, src/qt/res/icons/synced.png, src/qt/res/icons/lock_*.png
+Icon Pack: Human-O2
+Designer: schollidesign
+License: GNU/GPL
+Site: http://findicons.com/icon/93743/blocks_gnome_netstatus_0
+
+Icon: src/qt/res/icons/transaction*.png
+Designer: md2k7
+Site: https://forum.bitcoin.org/index.php?topic=15276.0
+License: You are free to do with these icons as you wish, including selling,
+ copying, modifying etc.
+
+Icon: src/qt/res/icons/configure.png, src/qt/res/icons/quit.png,
+      src/qt/res/icons/editcopy.png, src/qt/res/icons/editpaste.png,
+      src/qt/res/icons/add.png, src/qt/res/icons/edit.png,
+      src/qt/res/icons/remove.png (edited)
+Designer: http://www.everaldo.com
+Icon Pack: Crystal SVG
+License: LGPL
+
+Icon: src/qt/res/icons/receive.png, src/qt/res/icons/history.png,
+      src/qt/res/icons/export.png
+Designer: Oxygen team
+Icon Pack: Oxygen
+License: Creative Common Attribution-ShareAlike 3.0 License or LGPL
+Site: http://www.oxygen-icons.org/
+
+Icon: src/qt/res/icons/bitcoin.png, src/qt/res/icons/toolbar.png
+Designer: Bitboy (optimized for 16x16 by Wladimir van der Laan)
+License: Public Domain
+Site: http://forum.bitcoin.org/?topic=1756.0
+
+Icon: src/qt/res/icons/overview.png
+Icon Pack: Primo
+Designer: Jack Cai
+License: Creative Commons Attribution No Derivatives (by-nd)
+Site: http://findicons.com/icon/175944/home?id=176221#
+
+Icon:  scripts/img/reload.xcf (modified),src/qt/res/movies/update_spinner.mng
+Icon Pack: Kids
+Designer: Everaldo (Everaldo Coelho)
+License: GNU/GPL 
+Site: http://findicons.com/icon/17102/reload?id=17102
+
+Image: src/qt/res/images/splash2.jpg (Wallet image)
+Designer: Crobbo (forum)
+Site: https://bitcointalk.org/index.php?topic=32273.0
+License: Public domain
+
+Icon: src/qt/res/icons/key.png
+Designer: VisualPharm (Ivan Boyko)
+Icon Pack: Must Have
+Site: http://findicons.com/icon/51009/key?id=51009
+License: Creative Commons Attribution (by)
+
+
index 62abb7b..e608c25 100644 (file)
@@ -32,8 +32,7 @@ or Boost 1.37: sudo apt-get install libboost1.37-dev
 
 If using Boost 1.37, append -mt to the boost libraries in the makefile.
 
-Requires wxWidgets 2.9.0 or greater, which uses UTF-8.  Don't try 2.8, it
-won't work.
+Requires wxWidgets 2.9.1 or newer.
 
 You need to download wxWidgets from http://www.wxwidgets.org/downloads/
 and build it yourself.  See the build instructions and configure parameters
diff --git a/doc/readme-qt.rst b/doc/readme-qt.rst
new file mode 100644 (file)
index 0000000..b12aa30
--- /dev/null
@@ -0,0 +1,162 @@
+Bitcoin-qt: Qt4 based GUI replacement for Bitcoin
+=================================================
+
+Features
+========
+
+- All functionality of the Wx GUI, including wallet encryption
+
+- Compatibility with Linux (both GNOME and KDE), MacOSX and Windows
+
+- Notification on incoming / outgoing transactions (compatible with FreeDesktop and other desktop notification schemes)
+
+- General interface improvements: Splash screen, tabbed interface
+
+- Overview page with current balance, unconfirmed balance, and such
+
+- Better transaction list with status icons, real-time filtering and a context menu
+
+- Asks for confirmation before sending coins, for your own safety
+
+- CSV export of transactions and address book (for Excel bookkeeping)
+
+- Shows alternative icon when connected to testnet, so you never accidentally send real coins during testing
+
+- Shows a progress bar on initial block download, so that you don't have to wonder how many blocks it needs to download to be up to date
+
+- Sendmany support, send to multiple recipients at the same time
+
+- Multiple unit support, can show subdivided bitcoins (uBTC, mBTC) for users that like large numbers
+
+- Support for English, German, Russian and Dutch languages
+
+- Address books and transaction table can be sorted by any column
+
+- Accepts "bitcoin:" URLs from browsers and other sources through drag and drop
+
+Build instructions
+===================
+
+Debian
+-------
+
+First, make sure that the required packages for Qt4 development of your
+distribution are installed, for Debian and Ubuntu these are:
+
+::
+
+    apt-get install qt4-qmake libqt4-dev build-essential libboost-dev libboost-system-dev \
+        libboost-filesystem-dev libboost-program-options-dev libboost-thread-dev \
+        libssl-dev libdb4.8++-dev
+
+then execute the following:
+
+::
+
+    qmake
+    make
+
+Alternatively, install Qt Creator and open the `bitcoin-qt.pro` file.
+
+An executable named `bitcoin-qt` will be built.
+
+
+Windows
+--------
+
+Windows build instructions:
+
+- Download the `QT Windows SDK`_ and install it. You don't need the Symbian stuff, just the desktop Qt.
+
+- Download and extract the `dependencies archive`_  [#]_, or compile openssl, boost and dbcxx yourself.
+
+- Copy the contents of the folder "deps" to "X:\\QtSDK\\mingw", replace X:\\ with the location where you installed the Qt SDK. Make sure that the contents of "deps\\include" end up in the current "include" directory.
+
+- Open the .pro file in QT creator and build as normal (ctrl-B)
+
+.. _`QT Windows SDK`: http://qt.nokia.com/downloads/sdk-windows-cpp
+.. _`dependencies archive`: https://download.visucore.com/bitcoin/qtgui_deps_1.zip
+.. [#] PGP signature: https://download.visucore.com/bitcoin/qtgui_deps_1.zip.sig (signed with RSA key ID `610945D0`_)
+.. _`610945D0`: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x610945D0
+
+
+Mac OS X
+--------
+
+- Download and install the `Qt Mac OS X SDK`_. It is recommended to also install Apple's Xcode with UNIX tools.
+
+- Download and install `MacPorts`_.
+
+- Execute the following commands in a terminal to get the dependencies:
+
+::
+
+       sudo port selfupdate
+       sudo port install boost db48
+
+- Open the .pro file in Qt Creator and build as normal (cmd-B)
+
+.. _`Qt Mac OS X SDK`: http://qt.nokia.com/downloads/sdk-mac-os-cpp
+.. _`MacPorts`: http://www.macports.org/install.php
+
+
+Build configuration options
+============================
+
+UPNnP port forwarding
+---------------------
+
+To use UPnP for port forwarding behind a NAT router (recommended, as more connections overall allow for a faster and more stable bitcoin experience), pass the following argument to qmake:
+
+::
+
+    qmake "USE_UPNP=1"
+
+(in **Qt Creator**, you can find the setting for additional qmake arguments under "Projects" -> "Build Settings" -> "Build Steps", then click "Details" next to **qmake**)
+
+This requires miniupnpc for UPnP port mapping.  It can be downloaded from
+http://miniupnp.tuxfamily.org/files/.  UPnP support is not compiled in by default.
+
+Set USE_UPNP to a different value to control this:
+
++------------+--------------------------------------------------------------+
+| USE_UPNP=  | (the default) no UPnP support, miniupnpc not required;       |
++------------+--------------------------------------------------------------+
+| USE_UPNP=0 | UPnP support turned off by default at runtime;               |
++------------+--------------------------------------------------------------+
+| USE_UPNP=1 | UPnP support turned on by default at runtime.                |
++------------+--------------------------------------------------------------+
+
+Mac OS X users: miniupnpc is currently outdated on MacPorts. An updated Portfile is provided in contrib/miniupnpc within this project.
+You can execute the following commands in a terminal to install it:
+
+::
+
+       cd <location of bitcoin-qt>/contrib/miniupnpc
+       sudo port install
+
+Notification support for recent (k)ubuntu versions
+---------------------------------------------------
+
+To see desktop notifications on (k)ubuntu versions starting from 10.04, enable usage of the
+FreeDesktop notification interface through DBUS using the following qmake option:
+
+::
+
+    qmake "USE_DBUS=1"
+
+Berkely DB version warning
+==========================
+
+A warning for people using the *static binary* version of Bitcoin on a Linux/UNIX-ish system (tl;dr: **Berkely DB databases are not forward compatible**).
+
+The static binary version of Bitcoin is linked against libdb4.7 or libdb4.8 (see also `this Debian issue`_).
+
+Now the nasty thing is that databases from 5.X are not compatible with 4.X.
+
+If the globally installed development package of Berkely DB installed on your system is 5.X, any source you
+build yourself will be linked against that. The first time you run with a 5.X version the database will be upgraded,
+and 4.X cannot open the new format. This means that you cannot go back to the old statically linked version without
+significant hassle!
+
+.. _`this Debian issue`: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=621425
index bcda64d..2e8b93e 100644 (file)
   2. windows 32-bit binary + source
   3. windows installer
 
+* repackage gitian builds:
+
+  * Windows .zip and setup.exe:
+  $ mkdir bitcoin-$VERSION-win32
+  $ cd bitcoin-$VERSION-win32
+  $ unzip bitcoin-$VERSION-win32-gitian.zip
+  $ mv bitcoin-$VERSION-win32-setup.exe ..
+  $ cd ..; zip bitcoin-$VERSION-win32.zip bitcoin-$VERSION-win32
+
+  * Linux .tar.gz:
+  $ mkdir bitcoin-$VERSION-linux
+  $ cd bitcoin-$VERSION-linux
+  $ unzip bitcoin-$VERSION-linux-gitian.zip
+  $ cd ..; tar czvf bitcoin-$VERSION-linux.tar.gz bitcoin-$VERSION-linux
+
+* perform Mac build
+  * From the bitcoin source dir
+  $ cd contrib
+  $ ./create_osx_dmg.sh
+  $ mv Bitcoin.dmg bitcoin-$VERSION-macosx.dmg
+
 * upload source and builds to SF
 
 * create SHA1SUMS for builds, and PGP-sign it
index 622661f..bd03fd2 100644 (file)
Binary files a/locale/de/LC_MESSAGES/bitcoin.mo and b/locale/de/LC_MESSAGES/bitcoin.mo differ
index 94ecc96..59381c1 100644 (file)
@@ -3,8 +3,8 @@ msgid ""
 msgstr ""
 "Project-Id-Version: \n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2011-07-17 02:21+0100\n"
-"PO-Revision-Date: 2011-07-17 02:54+0100\n"
+"POT-Creation-Date: 2011-08-07 01:46+0100\n"
+"PO-Revision-Date: 2011-08-07 01:47+0100\n"
 "Last-Translator: Michael Bemmerl <mail@mx-server.de>\n"
 "Language-Team: German <translation-team-de@lists.sourceforge.net>\n"
 "MIME-Version: 1.0\n"
@@ -169,28 +169,28 @@ msgstr "Anzunehmende Verschlüsselungen (Standard: TLSv1+HIGH:!SSLv2:!aNULL:!eNU
 msgid "This help message\n"
 msgstr "Diese Anleitung\n"
 
-#: ../../../src/init.cpp:351
+#: ../../../src/init.cpp:352
 #, c-format
 msgid "Cannot obtain a lock on data directory %s.  Bitcoin is probably already running."
 msgstr "Erhalte keine Datensperre für das Datenverzeichnis %s. Bitcoin läuft wahrscheinlich bereits."
 
-#: ../../../src/init.cpp:377
+#: ../../../src/init.cpp:378
 msgid "Error loading addr.dat      \n"
 msgstr "Fehler beim Laden von addr.dat      \n"
 
-#: ../../../src/init.cpp:383
+#: ../../../src/init.cpp:384
 msgid "Error loading blkindex.dat      \n"
 msgstr "Fehler beim Laden von blkindex.dat      \n"
 
-#: ../../../src/init.cpp:394
+#: ../../../src/init.cpp:395
 msgid "Error loading wallet.dat: Wallet corrupted      \n"
 msgstr "Fehler beim Laden von wallet.dat: Brieftasche beschädigt      \n"
 
-#: ../../../src/init.cpp:396
+#: ../../../src/init.cpp:397
 msgid "Error loading wallet.dat: Wallet requires newer version of Bitcoin      \n"
 msgstr "Fehler beim Laden von wallet.dat: Die Brieftasche benötigt eine neuere Version von Bitcoin      \n"
 
-#: ../../../src/init.cpp:398
+#: ../../../src/init.cpp:399
 msgid "Error loading wallet.dat      \n"
 msgstr "Fehler beim Laden von wallet.dat      \n"
 
@@ -206,22 +206,22 @@ msgstr "Ungültiger Betrag für -paytxfee=<amount>"
 msgid "Warning: -paytxfee is set very high.  This is the transaction fee you will pay if you send a transaction."
 msgstr "Warnung: -paytxfee ist sehr hoch gesetzt. Das ist die Überweisungsgebühr, die Sie für das Senden einer Überweisung zahlen."
 
-#: ../../../src/main.cpp:1430
+#: ../../../src/main.cpp:1427
 msgid "Warning: Disk space is low  "
 msgstr "Warnung: Festplatte fast voll  "
 
-#: ../../../src/net.cpp:1615
+#: ../../../src/net.cpp:1616
 #, c-format
 msgid "Unable to bind to port %d on this computer.  Bitcoin is probably already running."
 msgstr "Kann nicht zu Port %d auf diesem Computer verbinden. Bitcoin läuft wahrscheinlich bereits."
 
-#: ../../../src/rpc.cpp:2100
-#: ../../../src/rpc.cpp:2102
+#: ../../../src/rpc.cpp:2086
+#: ../../../src/rpc.cpp:2088
 #, c-format
 msgid "To use the %s option"
 msgstr "Um die %s-Option zu nutzen"
 
-#: ../../../src/rpc.cpp:2104
+#: ../../../src/rpc.cpp:2090
 #, c-format
 msgid ""
 "Warning: %s, you must set rpcpassword=<password>\n"
@@ -232,7 +232,7 @@ msgstr ""
 "in der Konfigurationsdatei %s einstellen.\n"
 "Wenn die Datei nicht existiert, erstellen Sie sie mit ausschließlich Besitzer-Leserechten.\n"
 
-#: ../../../src/rpc.cpp:2277
+#: ../../../src/rpc.cpp:2263
 #, c-format
 msgid ""
 "You must set rpcpassword=<password> in the configuration file:\n"
@@ -248,13 +248,13 @@ msgstr ""
 msgid "This transaction is over the size limit.  You can still send it for a fee of %s, which goes to the nodes that process your transaction and helps to support the network.  Do you want to pay the fee?"
 msgstr "Diese Überweisung übersteigt das Betragslimit. Sie können sie trotzdem tätigen, aber es wird eine Gebühr von %s erhoben, die an den Teilnehmer ausgeschüttet wird, der Ihre Überweisung bearbeitet und dadurch hilft, das Netzwerk am laufen zu halten. Möchten Sie die Gebühr entrichten?"
 
-#: ../../../src/ui.cpp:259
+#: ../../../src/ui.cpp:260
 #: ../../../src/ui.cpp:1246
 msgid "Enter the current passphrase to the wallet."
 msgstr "Geben Sie die derzeitige Passphrase der Brieftasche ein."
 
 # See http://dict.leo.org/forum/viewUnsolvedquery.php?idThread=465865&idForum=2&lp=ende&lang=de
-#: ../../../src/ui.cpp:260
+#: ../../../src/ui.cpp:261
 #: ../../../src/ui.cpp:1182
 #: ../../../src/ui.cpp:1199
 #: ../../../src/ui.cpp:1247
@@ -263,83 +263,83 @@ msgstr "Geben Sie die derzeitige Passphrase der Brieftasche ein."
 msgid "Passphrase"
 msgstr "Passphrase"
 
-#: ../../../src/ui.cpp:266
+#: ../../../src/ui.cpp:267
 msgid "Please supply the current wallet decryption passphrase."
 msgstr "Bitte geben Sie die derzeitige Passphrase zur Entschlüsselung der Brieftasche an."
 
-#: ../../../src/ui.cpp:274
+#: ../../../src/ui.cpp:275
 #: ../../../src/ui.cpp:1258
 #: ../../../src/ui.cpp:1315
 msgid "The passphrase entered for the wallet decryption was incorrect."
 msgstr "Die eingegebene Passphrase zur Entschlüsselung der Brieftasche war inkorrekt."
 
-#: ../../../src/ui.cpp:351
+#: ../../../src/ui.cpp:352
 msgid "Status"
 msgstr "Status"
 
-#: ../../../src/ui.cpp:352
+#: ../../../src/ui.cpp:353
 msgid "Date"
 msgstr "Datum"
 
-#: ../../../src/ui.cpp:353
+#: ../../../src/ui.cpp:354
 msgid "Description"
 msgstr "Beschreibung"
 
-#: ../../../src/ui.cpp:354
+#: ../../../src/ui.cpp:355
 msgid "Debit"
 msgstr "Belastungen"
 
-#: ../../../src/ui.cpp:355
+#: ../../../src/ui.cpp:356
 msgid "Credit"
 msgstr "Gutschriften"
 
-#: ../../../src/ui.cpp:566
+#: ../../../src/ui.cpp:567
 #, c-format
 msgid "Open for %d blocks"
 msgstr "Offen für %d Blöcke"
 
-#: ../../../src/ui.cpp:568
+#: ../../../src/ui.cpp:569
 #, c-format
 msgid "Open until %s"
 msgstr "Offen bis %s"
 
-#: ../../../src/ui.cpp:574
+#: ../../../src/ui.cpp:575
 #, c-format
 msgid "%d/offline?"
 msgstr "%d/Offline?"
 
-#: ../../../src/ui.cpp:576
+#: ../../../src/ui.cpp:577
 #, c-format
 msgid "%d/unconfirmed"
 msgstr "%d/nicht bestätigt"
 
-#: ../../../src/ui.cpp:578
+#: ../../../src/ui.cpp:579
 #, c-format
 msgid "%d confirmations"
 msgstr "%d Bestätigungen"
 
-#: ../../../src/ui.cpp:663
+#: ../../../src/ui.cpp:664
 msgid "Generated"
 msgstr "Erzeugt"
 
-#: ../../../src/ui.cpp:671
+#: ../../../src/ui.cpp:672
 #, c-format
 msgid "Generated (%s matures in %d more blocks)"
 msgstr "Erzeugt (%s reifen nach %d weiteren Blöcken)"
 
-#: ../../../src/ui.cpp:675
+#: ../../../src/ui.cpp:676
 msgid "Generated - Warning: This block was not received by any other nodes and will probably not be accepted!"
 msgstr "Erzeugt - Warnung: Dieser Block wurde von keinem anderen Teilnehmer empfangen und wird wahrscheinlich nicht akzeptiert werden!"
 
-#: ../../../src/ui.cpp:679
+#: ../../../src/ui.cpp:680
 msgid "Generated (not accepted)"
 msgstr "Erzeugt (nicht akzeptiert)"
 
-#: ../../../src/ui.cpp:689
+#: ../../../src/ui.cpp:690
 msgid "From: "
 msgstr "Von: "
 
-#: ../../../src/ui.cpp:713
+#: ../../../src/ui.cpp:714
 msgid "Received with: "
 msgstr "Empfangen durch: "
 
@@ -427,12 +427,12 @@ msgid "Wallet Passphrase Changed."
 msgstr "Die Passphrase der Brieftasche wurde geändert."
 
 #: ../../../src/ui.cpp:1381
-#: ../../../src/ui.cpp:2816
+#: ../../../src/ui.cpp:2814
 msgid "New Receiving Address"
 msgstr "&Neue Empfangs-Adresse"
 
 #: ../../../src/ui.cpp:1382
-#: ../../../src/ui.cpp:2817
+#: ../../../src/ui.cpp:2815
 msgid ""
 "You should use a new address for each payment you receive.\n"
 "\n"
@@ -469,221 +469,221 @@ msgid "<b>Source:</b> Generated<br>"
 msgstr "<b>Quelle:</b> Erzeugt<br>"
 
 #: ../../../src/ui.cpp:1493
-#: ../../../src/ui.cpp:1511
+#: ../../../src/ui.cpp:1510
 msgid "<b>From:</b> "
 msgstr "<b>Von:</b> "
 
-#: ../../../src/ui.cpp:1511
+#: ../../../src/ui.cpp:1510
 msgid "unknown"
 msgstr "Unbekannt"
 
-#: ../../../src/ui.cpp:1512
-#: ../../../src/ui.cpp:1536
-#: ../../../src/ui.cpp:1595
+#: ../../../src/ui.cpp:1511
+#: ../../../src/ui.cpp:1535
+#: ../../../src/ui.cpp:1594
 msgid "<b>To:</b> "
 msgstr "<b>An:</b> "
 
-#: ../../../src/ui.cpp:1515
+#: ../../../src/ui.cpp:1514
 msgid " (yours, label: "
 msgstr " (Eigene, Beschreibung: "
 
-#: ../../../src/ui.cpp:1517
+#: ../../../src/ui.cpp:1516
 msgid " (yours)"
 msgstr " (Eigene)"
 
-#: ../../../src/ui.cpp:1554
-#: ../../../src/ui.cpp:1566
-#: ../../../src/ui.cpp:1612
-#: ../../../src/ui.cpp:1629
+#: ../../../src/ui.cpp:1553
+#: ../../../src/ui.cpp:1565
+#: ../../../src/ui.cpp:1611
+#: ../../../src/ui.cpp:1628
 msgid "<b>Credit:</b> "
 msgstr "<b>Gutschrift:</b> "
 
-#: ../../../src/ui.cpp:1556
+#: ../../../src/ui.cpp:1555
 #, c-format
 msgid "(%s matures in %d more blocks)"
 msgstr "(%s reifen nach %d weiteren Blöcken)"
 
-#: ../../../src/ui.cpp:1558
+#: ../../../src/ui.cpp:1557
 msgid "(not accepted)"
 msgstr "(nicht akzeptiert)"
 
-#: ../../../src/ui.cpp:1603
-#: ../../../src/ui.cpp:1611
-#: ../../../src/ui.cpp:1626
+#: ../../../src/ui.cpp:1602
+#: ../../../src/ui.cpp:1610
+#: ../../../src/ui.cpp:1625
 msgid "<b>Debit:</b> "
 msgstr "<b>Belastung:</b> "
 
-#: ../../../src/ui.cpp:1617
+#: ../../../src/ui.cpp:1616
 msgid "<b>Transaction fee:</b> "
 msgstr "<b>Überweisungsgebühr:</b> "
 
-#: ../../../src/ui.cpp:1633
+#: ../../../src/ui.cpp:1632
 msgid "<b>Net amount:</b> "
 msgstr "<b>Nettobetrag:</b> "
 
-#: ../../../src/ui.cpp:1640
+#: ../../../src/ui.cpp:1639
 msgid "Message:"
 msgstr "Nachricht:"
 
-#: ../../../src/ui.cpp:1642
+#: ../../../src/ui.cpp:1641
 msgid "Comment:"
 msgstr "Kommentar:"
 
-#: ../../../src/ui.cpp:1645
+#: ../../../src/ui.cpp:1644
 msgid "Generated coins must wait 120 blocks before they can be spent.  When you generated this block, it was broadcast to the network to be added to the block chain.  If it fails to get into the chain, it will change to \"not accepted\" and not be spendable.  This may occasionally happen if another node generates a block within a few seconds of yours."
 msgstr "Erzeugte Münzen müssen 120 Blöcke lang reifen. Als Sie diesen Block erzeugt haben, wurde er an alle Teilnehmer übertragen, damit er zur Block-Kette hinzugefügt werden kann. Falls der Block es nicht in die Block-Kette schafft, wird die Beschreibung zu \"nicht akzeptiert\" geändert, und Sie können die Münzen nicht ausgeben. Dies kann manchmal passieren, wenn Sie und ein anderer Teilnehmer annähernd zeitgleich einen Block erzeugen."
 
-#: ../../../src/ui.cpp:1825
+#: ../../../src/ui.cpp:1824
 msgid "Cannot write autostart/bitcoin.desktop file"
 msgstr "Kann Datei autostart/bitcoin.desktop nicht schreiben"
 
-#: ../../../src/ui.cpp:1861
+#: ../../../src/ui.cpp:1860
 msgid "Main"
 msgstr "Haupt"
 
-#: ../../../src/ui.cpp:1871
+#: ../../../src/ui.cpp:1870
 msgid "&Start Bitcoin on window system startup"
 msgstr "Bitcoin beim &Systemstart ausführen"
 
-#: ../../../src/ui.cpp:1878
+#: ../../../src/ui.cpp:1877
 msgid "&Minimize on close"
 msgstr "Beim Schließen &minimieren"
 
-#: ../../../src/ui.cpp:2020
+#: ../../../src/ui.cpp:2019
 #, c-format
 msgid "version %s"
 msgstr "Version %s"
 
-#: ../../../src/ui.cpp:2143
+#: ../../../src/ui.cpp:2142
 msgid "Error in amount  "
 msgstr "Fehler in Betrag  "
 
-#: ../../../src/ui.cpp:2143
-#: ../../../src/ui.cpp:2148
-#: ../../../src/ui.cpp:2153
-#: ../../../src/ui.cpp:2202
+#: ../../../src/ui.cpp:2142
+#: ../../../src/ui.cpp:2147
+#: ../../../src/ui.cpp:2152
+#: ../../../src/ui.cpp:2201
 #: ../../../src/uibase.cpp:61
 msgid "Send Coins"
 msgstr "Überweisen"
 
-#: ../../../src/ui.cpp:2148
+#: ../../../src/ui.cpp:2147
 msgid "Amount exceeds your balance  "
 msgstr "Der Betrag übersteigt Ihr Guthaben  "
 
-#: ../../../src/ui.cpp:2153
+#: ../../../src/ui.cpp:2152
 msgid "Total exceeds your balance when the "
 msgstr "Der Betrag übersteigt Ihr Guthaben, wenn man die "
 
-#: ../../../src/ui.cpp:2153
+#: ../../../src/ui.cpp:2152
 msgid " transaction fee is included  "
 msgstr " Überweisungsgebühr berücksichtigt  "
 
-#: ../../../src/ui.cpp:2176
+#: ../../../src/ui.cpp:2175
 msgid "Payment sent  "
 msgstr "Zahlung überwiesen  "
 
-#: ../../../src/ui.cpp:2176
-#: ../../../src/ui.cpp:2185
-#: ../../../src/ui.cpp:2336
-#: ../../../src/ui.cpp:2500
-#: ../../../src/wallet.cpp:1097
+#: ../../../src/ui.cpp:2175
+#: ../../../src/ui.cpp:2184
+#: ../../../src/ui.cpp:2335
+#: ../../../src/ui.cpp:2499
+#: ../../../src/wallet.cpp:1099
 msgid "Sending..."
 msgstr "Überweise ..."
 
-#: ../../../src/ui.cpp:2202
+#: ../../../src/ui.cpp:2201
 msgid "Invalid address  "
 msgstr "Ungültige Adresse  "
 
-#: ../../../src/ui.cpp:2257
+#: ../../../src/ui.cpp:2256
 #, c-format
 msgid "Sending %s to %s"
 msgstr "Überweise %s an %s"
 
-#: ../../../src/ui.cpp:2330
-#: ../../../src/ui.cpp:2363
+#: ../../../src/ui.cpp:2329
+#: ../../../src/ui.cpp:2362
 msgid "CANCELLED"
 msgstr "ANNULLIERT"
 
-#: ../../../src/ui.cpp:2334
+#: ../../../src/ui.cpp:2333
 msgid "Cancelled"
 msgstr "Annulliert"
 
-#: ../../../src/ui.cpp:2336
+#: ../../../src/ui.cpp:2335
 msgid "Transfer cancelled  "
 msgstr "Überweisung annulliert  "
 
-#: ../../../src/ui.cpp:2389
+#: ../../../src/ui.cpp:2388
 msgid "Error: "
 msgstr "Fehler: "
 
-#: ../../../src/ui.cpp:2403
-#: ../../../src/ui.cpp:2474
-#: ../../../src/wallet.cpp:1116
+#: ../../../src/ui.cpp:2402
+#: ../../../src/ui.cpp:2473
+#: ../../../src/wallet.cpp:1118
 msgid "Insufficient funds"
 msgstr "Unzureichende Geldmittel"
 
-#: ../../../src/ui.cpp:2408
+#: ../../../src/ui.cpp:2407
 msgid "Connecting..."
 msgstr "Verbinde ..."
 
-#: ../../../src/ui.cpp:2413
+#: ../../../src/ui.cpp:2412
 msgid "Unable to connect"
 msgstr "Kann nicht verbinden"
 
-#: ../../../src/ui.cpp:2418
+#: ../../../src/ui.cpp:2417
 msgid "Requesting public key..."
 msgstr "Fordere öffentlichen Schlüssel an ..."
 
-#: ../../../src/ui.cpp:2430
+#: ../../../src/ui.cpp:2429
 msgid "Received public key..."
 msgstr "Öffentlicher Schlüssel empfangen ..."
 
-#: ../../../src/ui.cpp:2444
+#: ../../../src/ui.cpp:2443
 msgid "Recipient is not accepting transactions sent by IP address"
 msgstr "Empfänger akzeptiert keine Überweisungen von IP-Adressen"
 
-#: ../../../src/ui.cpp:2446
+#: ../../../src/ui.cpp:2445
 msgid "Transfer was not accepted"
 msgstr "Überweisung wurde nicht akzeptiert"
 
-#: ../../../src/ui.cpp:2455
+#: ../../../src/ui.cpp:2454
 msgid "Invalid response received"
 msgstr "Ungültige Antwort erhalten"
 
-#: ../../../src/ui.cpp:2470
+#: ../../../src/ui.cpp:2469
 msgid "Creating transaction..."
 msgstr "Erstelle Überweisung ..."
 
-#: ../../../src/ui.cpp:2489
+#: ../../../src/ui.cpp:2488
 #, c-format
 msgid "This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds"
 msgstr "Diese Überweisung benötigt eine Überweisungsgebühr von mindestens %s wegen ihres Betrags, Komplexität oder der Benutzung kürzlich erhaltener Geldmittel"
 
-#: ../../../src/ui.cpp:2491
+#: ../../../src/ui.cpp:2490
 msgid "Transaction creation failed"
 msgstr "Überweisung konnte nicht erzeugt werden."
 
-#: ../../../src/ui.cpp:2502
+#: ../../../src/ui.cpp:2501
 msgid "Transaction aborted"
 msgstr "Überweisung abgebrochen"
 
-#: ../../../src/ui.cpp:2510
+#: ../../../src/ui.cpp:2509
 msgid "Lost connection, transaction cancelled"
 msgstr "Verbindung verloren, Überweisungsvorgang abgebrochen"
 
-#: ../../../src/ui.cpp:2526
+#: ../../../src/ui.cpp:2525
 msgid "Sending payment..."
 msgstr "Überweise Zahlung ..."
 
-#: ../../../src/ui.cpp:2532
+#: ../../../src/ui.cpp:2531
 msgid "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."
 msgstr "Die Überweisung wurde abgelehnt. Das kann passieren, wenn einige der Münzen in Ihrer Brieftasche bereits ausgegeben wurden, z.B. weil Sie eine Kopie der Brieftasche (wallet.dat) gemacht haben. Bitcoins, die mithilfe der Kopie ausgegeben wurden, sind in dieser Brieftasche noch nicht als ausgegeben markiert worden."
 
-#: ../../../src/ui.cpp:2541
+#: ../../../src/ui.cpp:2540
 msgid "Waiting for confirmation..."
 msgstr "Warte auf Bestätigung ..."
 
-#: ../../../src/ui.cpp:2559
+#: ../../../src/ui.cpp:2558
 msgid ""
 "The payment was sent, but the recipient was unable to verify it.\n"
 "The transaction is recorded and will credit to the recipient,\n"
@@ -693,84 +693,84 @@ msgstr ""
 "Die Überweisung wurde gespeichert und wird dem Empfänger gutgeschrieben,\n"
 "aber die begleitende Nachricht wird leer sein."
 
-#: ../../../src/ui.cpp:2568
+#: ../../../src/ui.cpp:2567
 msgid "Payment was sent, but an invalid response was received"
 msgstr "Die Zahlung wurde überwiesen, aber die Antwort war fehlerhaft"
 
-#: ../../../src/ui.cpp:2574
+#: ../../../src/ui.cpp:2573
 msgid "Payment completed"
 msgstr "Zahlung ausgeführt"
 
-#: ../../../src/ui.cpp:2616
-#: ../../../src/ui.cpp:2764
-#: ../../../src/ui.cpp:2804
+#: ../../../src/ui.cpp:2615
+#: ../../../src/ui.cpp:2762
+#: ../../../src/ui.cpp:2802
 msgid "Name"
 msgstr "Name"
 
-#: ../../../src/ui.cpp:2617
-#: ../../../src/ui.cpp:2764
-#: ../../../src/ui.cpp:2804
+#: ../../../src/ui.cpp:2616
+#: ../../../src/ui.cpp:2762
+#: ../../../src/ui.cpp:2802
 msgid "Address"
 msgstr "Adresse"
 
-#: ../../../src/ui.cpp:2619
-#: ../../../src/ui.cpp:2776
+#: ../../../src/ui.cpp:2618
+#: ../../../src/ui.cpp:2774
 msgid "Label"
 msgstr "Beschreibung"
 
-#: ../../../src/ui.cpp:2620
+#: ../../../src/ui.cpp:2619
 #: ../../../src/uibase.cpp:847
 msgid "Bitcoin Address"
 msgstr "Bitcoin-Adresse"
 
-#: ../../../src/ui.cpp:2746
+#: ../../../src/ui.cpp:2744
 msgid "This is one of your own addresses for receiving payments and cannot be entered in the address book.  "
 msgstr "Dies ist eine Ihrer eigenen Adressen für den Zahlungseingang und kann deshalb nicht in das Adressbuch übernommen werden.  "
 
-#: ../../../src/ui.cpp:2764
-#: ../../../src/ui.cpp:2770
+#: ../../../src/ui.cpp:2762
+#: ../../../src/ui.cpp:2768
 msgid "Edit Address"
 msgstr "Adresse bearbeiten"
 
-#: ../../../src/ui.cpp:2776
+#: ../../../src/ui.cpp:2774
 msgid "Edit Address Label"
 msgstr "Beschreibung der Adresse bearbeiten"
 
-#: ../../../src/ui.cpp:2804
-#: ../../../src/ui.cpp:2810
+#: ../../../src/ui.cpp:2802
+#: ../../../src/ui.cpp:2808
 msgid "Add Address"
 msgstr "Adresse hinzufügen"
 
-#: ../../../src/ui.cpp:2898
+#: ../../../src/ui.cpp:2896
 msgid "Bitcoin"
 msgstr "Bitcoin"
 
-#: ../../../src/ui.cpp:2900
+#: ../../../src/ui.cpp:2898
 msgid "Bitcoin - Generating"
 msgstr "Bitcoin - Erzeuge"
 
-#: ../../../src/ui.cpp:2902
+#: ../../../src/ui.cpp:2900
 msgid "Bitcoin - (not connected)"
 msgstr "Bitcoin - (nicht verbunden)"
 
-#: ../../../src/ui.cpp:2981
+#: ../../../src/ui.cpp:2979
 msgid "&Open Bitcoin"
 msgstr "Bitcoin ö&ffnen"
 
-#: ../../../src/ui.cpp:2982
+#: ../../../src/ui.cpp:2980
 msgid "&Send Bitcoins"
 msgstr "Bitcoins &senden"
 
-#: ../../../src/ui.cpp:2983
+#: ../../../src/ui.cpp:2981
 msgid "O&ptions..."
 msgstr "O&ptionen ..."
 
-#: ../../../src/ui.cpp:2986
+#: ../../../src/ui.cpp:2984
 #: ../../../src/uibase.cpp:25
 msgid "E&xit"
 msgstr "B&eenden"
 
-#: ../../../src/ui.cpp:3212
+#: ../../../src/ui.cpp:3210
 msgid "Program has crashed and will terminate.  "
 msgstr "Das Programm ist abgestürzt und wird beendet.  "
 
@@ -887,8 +887,8 @@ msgid "M&inimize to the tray on close"
 msgstr "Beim Schließen in den Infobereich m&inimieren"
 
 #: ../../../src/uibase.cpp:370
-msgid "&Connect through socks4 proxy: "
-msgstr "&Per Socks4-Proxy verbinden: "
+msgid "&Connect through socks4 proxy (requires restart to apply): "
+msgstr "&Per Socks4-Proxy verbinden (erfordert einen Neustart): "
 
 #: ../../../src/uibase.cpp:381
 msgid "Proxy &IP:"
@@ -1040,31 +1040,27 @@ msgstr "Warnung: Bitte überprüfen Sie die Richtigkeit des Datums und der Uhrze
 msgid "beta"
 msgstr "Beta"
 
-#: ../../../src/wallet.cpp:1081
+#: ../../../src/wallet.cpp:1083
 msgid "Error: Wallet locked, unable to create transaction  "
 msgstr "Fehler: Brieftasche ist verschlossen; Überweisung konnte nicht erstellt werden  "
 
-#: ../../../src/wallet.cpp:1089
+#: ../../../src/wallet.cpp:1091
 #, c-format
 msgid "Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds  "
 msgstr "Fehler: Diese Überweisung benötigt eine Überweisungsgebühr von mindestens %s wegen ihrer Größe, Komplexität oder der Benutzung erst kürzlich erhaltener Geldmittel  "
 
-#: ../../../src/wallet.cpp:1091
+#: ../../../src/wallet.cpp:1093
 msgid "Error: Transaction creation failed  "
 msgstr "Fehler: Überweisung konnte nicht erzeugt werden.  "
 
-#: ../../../src/wallet.cpp:1101
+#: ../../../src/wallet.cpp:1103
 msgid "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."
 msgstr "Fehler: Die Überweisung wurde abgelehnt. Das kann passieren, wenn einige der Münzen in Ihrer Brieftasche bereits ausgegeben wurden, z.B. weil Sie eine Kopie der Brieftasche (wallet.dat) gemacht haben. Bitcoins, die mithilfe der Kopie ausgegeben wurden, sind in dieser Brieftasche noch nicht als ausgegeben markiert worden."
 
-#: ../../../src/wallet.cpp:1114
+#: ../../../src/wallet.cpp:1116
 msgid "Invalid amount"
 msgstr "Ungültiger Betrag"
 
-#: ../../../src/wallet.cpp:1121
-msgid "Invalid bitcoin address"
-msgstr "Ungültige Bitcoin-Adresse"
-
 #: ../../../src/uibase.h:151
 msgid "Transaction Details"
 msgstr "Überweisungsdetails"
@@ -1081,3 +1077,5 @@ msgstr "Über Bitcoin"
 msgid "Your Bitcoin Addresses"
 msgstr "Ihre Bitcoin-Adressen"
 
+#~ msgid "Invalid bitcoin address"
+#~ msgstr "Ungültige Bitcoin-Adresse"
index c67886e..1787c48 100644 (file)
@@ -2,126 +2,433 @@ msgid ""
 msgstr ""
 "Project-Id-Version: \n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2011-05-24 20:21-0500\n"
-"PO-Revision-Date: 2011-05-24 20:23-0500\n"    
-"Last-Translator: Ariel Patiño <ariel@ficticio.com>\n"
+"POT-Creation-Date: 2011-09-06 21:58+0100\n"
+"PO-Revision-Date: 2011-09-06 22:19+0100\n"
+"Last-Translator: Alex B <paraipanakos@gmail.com>\n"
 "Language-Team: \n"
-"Language: \n"
 "MIME-Version: 1.0\n"
 "Content-Type: text/plain; charset=UTF-8\n"
 "Content-Transfer-Encoding: 8bit\n"
+"Language: \n"
 "X-Poedit-KeywordsList: _;gettext;gettext_noop\n"
 "X-Poedit-Basepath: .\n"
 "X-Poedit-SearchPath-0: ../../..\n"
 
-#: ../../../src/net.cpp:1503
+#: ../../../src/init.cpp:163
+msgid "Bitcoin version"
+msgstr "versión Bitcoin"
+
+#: ../../../src/init.cpp:164
+msgid "Usage:"
+msgstr "Uso:"
+
+#: ../../../src/init.cpp:166
+msgid "Send command to -server or bitcoind\n"
+msgstr "Envia comando a bitcoin lanzado con -server u bitcoind\n"
+
+#: ../../../src/init.cpp:167
+msgid "List commands\n"
+msgstr "Muestra comandos\n"
+
+#: ../../../src/init.cpp:168
+msgid "Get help for a command\n"
+msgstr "Recibir ayuda para un comando\n"
+
+#: ../../../src/init.cpp:169
+msgid "Options:\n"
+msgstr "Opciones:\n"
+
+#: ../../../src/init.cpp:170
+msgid "Specify configuration file (default: bitcoin.conf)\n"
+msgstr "Especifica archivo de configuración (predeterminado: bitcoin.conf)\n"
+
+#: ../../../src/init.cpp:171
+msgid "Specify pid file (default: bitcoind.pid)\n"
+msgstr "Especifica archivo pid (predeterminado: bitcoin.pid)\n"
+
+#: ../../../src/init.cpp:172
+msgid "Generate coins\n"
+msgstr "Genera monedas\n"
+
+#: ../../../src/init.cpp:173
+msgid "Don't generate coins\n"
+msgstr "No generar monedas\n"
+
+#: ../../../src/init.cpp:174
+msgid "Start minimized\n"
+msgstr "Arranca minimizado\n"
+
+#: ../../../src/init.cpp:175
+msgid "Specify data directory\n"
+msgstr "Especifica directorio para los datos\n"
+
+#: ../../../src/init.cpp:176
+msgid "Specify connection timeout (in milliseconds)\n"
+msgstr "Especifica tiempo de espera para conexion (en milisegundos)\n"
+
+#: ../../../src/init.cpp:177
+msgid "Connect through socks4 proxy\n"
+msgstr "Conecta mediante proxy socks4\n"
+
+#: ../../../src/init.cpp:178
+msgid "Allow DNS lookups for addnode and connect\n"
+msgstr "Permite búsqueda DNS para addnode y connect\n"
+
+#: ../../../src/init.cpp:179
+msgid "Add a node to connect to\n"
+msgstr "Agrega un nodo para conectarse\n"
+
+#: ../../../src/init.cpp:180
+msgid "Connect only to the specified node\n"
+msgstr "Conecta solo al nodo especificado\n"
+
+#: ../../../src/init.cpp:181
+msgid "Don't accept connections from outside\n"
+msgstr "No aceptar conexiones desde el exterior\n"
+
+#: ../../../src/init.cpp:184
+msgid "Don't attempt to use UPnP to map the listening port\n"
+msgstr "No intentar usar UPnP para mapear el puerto de entrada\n"
+
+#: ../../../src/init.cpp:186
+msgid "Attempt to use UPnP to map the listening port\n"
+msgstr "Intenta usar UPnP para mapear el puerto de escucha.\n"
+
+#: ../../../src/init.cpp:189
+msgid "Fee per KB to add to transactions you send\n"
+msgstr "Comisión por KB para agregar a las transacciones que envias\n"
+
+#: ../../../src/init.cpp:191
+msgid "Accept command line and JSON-RPC commands\n"
+msgstr "Aceptar comandos consola y JSON-RPC\n"
+
+#: ../../../src/init.cpp:194
+msgid "Run in the background as a daemon and accept commands\n"
+msgstr "Correr como demonio y acepta comandos\n"
+
+#: ../../../src/init.cpp:196
+msgid "Use the test network\n"
+msgstr "Usa la red de pruebas\n"
+
+#: ../../../src/init.cpp:197
+msgid "Username for JSON-RPC connections\n"
+msgstr "Usuario para las conexiones JSON-RPC\n"
+
+#: ../../../src/init.cpp:198
+msgid "Password for JSON-RPC connections\n"
+msgstr "Contraseña para las conexiones JSON-RPC\n"
+
+#: ../../../src/init.cpp:199
+msgid "Listen for JSON-RPC connections on <port> (default: 8332)\n"
+msgstr "Escucha conexiones JSON-RPC en el puerto <port> (predeterminado: 8332)\n"
+
+#: ../../../src/init.cpp:200
+msgid "Allow JSON-RPC connections from specified IP address\n"
+msgstr "Permite conexiones JSON-RPC desde la dirección IP especificada\n"
+
+#: ../../../src/init.cpp:201
+msgid "Send commands to node running on <ip> (default: 127.0.0.1)\n"
+msgstr "Envia comando al nodo situado en <ip> (predeterminado: 127.0.0.1)\n"
+
+#: ../../../src/init.cpp:202
+msgid "Set key pool size to <n> (default: 100)\n"
+msgstr "Ajusta el numero de claves en reserva <n> (predeterminado: 100)\n"
+
+#: ../../../src/init.cpp:203
+msgid "Rescan the block chain for missing wallet transactions\n"
+msgstr "Rescanea la cadena de bloques para transacciones perdidas de la cartera\n"
+
+#: ../../../src/init.cpp:207
+msgid ""
+"\n"
+"SSL options: (see the Bitcoin Wiki for SSL setup instructions)\n"
+msgstr ""
+"\n"
+"Opciones SSL: (ver la Bitcoin Wiki para instrucciones de configuración SSL)\n"
+
+#: ../../../src/init.cpp:208
+msgid "Use OpenSSL (https) for JSON-RPC connections\n"
+msgstr "Usa OpenSSL (https) para las conexiones JSON-RPC\n"
+
+#: ../../../src/init.cpp:209
+msgid "Server certificate file (default: server.cert)\n"
+msgstr "Archivo de certificado del servidor (Predeterminado: server.cert)\n"
+
+#: ../../../src/init.cpp:210
+msgid "Server private key (default: server.pem)\n"
+msgstr "Clave privada del servidor (Predeterminado: server.pem)\n"
+
+#: ../../../src/init.cpp:211
+msgid "Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
+msgstr "Cifrados aceptados (Predeterminado: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
+
+#: ../../../src/init.cpp:215
+msgid "This help message\n"
+msgstr "Este mensaje de ayuda\n"
+
+#: ../../../src/init.cpp:353
+#, c-format
+msgid "Cannot obtain a lock on data directory %s.  Bitcoin is probably already running."
+msgstr "No se puede obtener permiso de trabajo en la carpeta de datos %s. Probablemente Bitcoin ya se está ejecutando."
+
+#: ../../../src/init.cpp:379
+msgid "Error loading addr.dat      \n"
+msgstr "Error cargando addr.dat      \n"
+
+#: ../../../src/init.cpp:385
+msgid "Error loading blkindex.dat      \n"
+msgstr "Error cargando blkindex.dat      \n"
+
+#: ../../../src/init.cpp:396
+msgid "Error loading wallet.dat: Wallet corrupted      \n"
+msgstr "Error cargando wallet.dat: Cartera dañada      \n"
+
+#: ../../../src/init.cpp:398
+msgid "Error loading wallet.dat: Wallet requires newer version of Bitcoin      \n"
+msgstr "Error cargando el archivo wallet.dat: Se necesita una versión mas nueva de Bitcoin      \n"
+
+#: ../../../src/init.cpp:400
+msgid "Error loading wallet.dat      \n"
+msgstr "Error cargando wallet.dat      \n"
+
+#: ../../../src/init.cpp:489
+msgid "Invalid -proxy address"
+msgstr "Dirección -proxy no valida"
+
+#: ../../../src/init.cpp:514
+msgid "Invalid amount for -paytxfee=<amount>"
+msgstr "Cantidad inválida para -paytxfee=<amount>"
+
+#: ../../../src/init.cpp:518
+msgid "Warning: -paytxfee is set very high.  This is the transaction fee you will pay if you send a transaction."
+msgstr "Precaución: -paytxfee es muy alta. Esta es la comisión que pagarás si envias una transacción."
+
+#: ../../../src/main.cpp:1398
+msgid "Warning: Disk space is low  "
+msgstr "Cuidado: Poco espacio en el disco duro"
+
+#: ../../../src/net.cpp:1610
 #, c-format
 msgid "Unable to bind to port %d on this computer.  Bitcoin is probably already running."
-msgstr "No es posible escuchar en el puerto %d en este computador. Probablemente el cliente Bitcoin ya se está ejecutando."
+msgstr "No es posible escuchar en el puerto %d en este ordenador. Probablemente Bitcoin ya se está ejecutando."
 
-#: ../../../src/ui.cpp:204
+#: ../../../src/rpc.cpp:2005
+#: ../../../src/rpc.cpp:2007
+#, c-format
+msgid "To use the %s option"
+msgstr "Para usar la opción %s"
+
+#: ../../../src/rpc.cpp:2009
+#, c-format
+msgid ""
+"Warning: %s, you must set rpcpassword=<password>\n"
+"in the configuration file: %s\n"
+"If the file does not exist, create it with owner-readable-only file permissions.\n"
+msgstr ""
+"Precaución: %s, debes especificar rpcpassword=<password>\n"
+"en el archivo de configuración: %s\n"
+"Si el archivo no existe, debes crearlo con permisos de lectura al autor solamente.\n"
+
+#: ../../../src/rpc.cpp:2185
+#, c-format
+msgid ""
+"You must set rpcpassword=<password> in the configuration file:\n"
+"%s\n"
+"If the file does not exist, create it with owner-readable-only file permissions."
+msgstr ""
+"Debes especificar rpcpassword=<password> en el archivo de configuración:\n"
+"%s\n"
+"Si el archivo no existe, debes crearlo con permisos de lectura al autor solamente."
+
+#: ../../../src/ui.cpp:217
 #, c-format
 msgid "This transaction is over the size limit.  You can still send it for a fee of %s, which goes to the nodes that process your transaction and helps to support the network.  Do you want to pay the fee?"
-msgstr "Esta transacción supera el límite. Puede seguir enviandola con una comisión de %s, que va a los nodos que procesan su transacción y ayuda a mantener la red. ¿Quiere pagar la comisión?"
+msgstr "Esta transacción supera el límite. Puedes seguir enviandola incluyendo una comisión de %s que se va a repartir entre los nodos que procesan su transacción y ayudan a mantener la red. ¿Quieres seguir con la transacción?"
+
+#: ../../../src/ui.cpp:261
+#: ../../../src/ui.cpp:1247
+msgid "Enter the current passphrase to the wallet."
+msgstr "Introduce la contraseña actual de la cartera."
 
-#: ../../../src/ui.cpp:303
+#: ../../../src/ui.cpp:262
+#: ../../../src/ui.cpp:1183
+#: ../../../src/ui.cpp:1200
+#: ../../../src/ui.cpp:1248
+#: ../../../src/ui.cpp:1272
+#: ../../../src/ui.cpp:1292
+msgid "Passphrase"
+msgstr "Contraseña"
+
+#: ../../../src/ui.cpp:268
+msgid "Please supply the current wallet decryption passphrase."
+msgstr "Por favor introduce la contraseña actual de la cartera."
+
+#: ../../../src/ui.cpp:276
+#: ../../../src/ui.cpp:1257
+#: ../../../src/ui.cpp:1314
+msgid "The passphrase entered for the wallet decryption was incorrect."
+msgstr "La contraseña introducida para decriptar la cartera es incorrecta."
+
+#: ../../../src/ui.cpp:353
 msgid "Status"
 msgstr "Estado"
 
-#: ../../../src/ui.cpp:304
+#: ../../../src/ui.cpp:354
 msgid "Date"
 msgstr "Fecha"
 
-#: ../../../src/ui.cpp:305
+#: ../../../src/ui.cpp:355
 msgid "Description"
 msgstr "Descripción"
 
-#: ../../../src/ui.cpp:306
+#: ../../../src/ui.cpp:356
 msgid "Debit"
 msgstr "Débito"
 
-#: ../../../src/ui.cpp:307
+#: ../../../src/ui.cpp:357
 msgid "Credit"
 msgstr "Crédito"
 
-#: ../../../src/ui.cpp:513
+#: ../../../src/ui.cpp:568
 #, c-format
 msgid "Open for %d blocks"
 msgstr "Abrir para %d bloques"
 
-#: ../../../src/ui.cpp:515
+#: ../../../src/ui.cpp:570
 #, c-format
 msgid "Open until %s"
 msgstr "Abrir hasta %s"
 
-#: ../../../src/ui.cpp:521
+#: ../../../src/ui.cpp:576
 #, c-format
 msgid "%d/offline?"
 msgstr "%d/desconectado?"
 
-#: ../../../src/ui.cpp:523
+#: ../../../src/ui.cpp:578
 #, c-format
 msgid "%d/unconfirmed"
 msgstr "%d/no confirmado"
 
-#: ../../../src/ui.cpp:525
+#: ../../../src/ui.cpp:580
 #, c-format
 msgid "%d confirmations"
 msgstr "%d confirmaciones"
 
-#: ../../../src/ui.cpp:610
+#: ../../../src/ui.cpp:665
 msgid "Generated"
 msgstr "Generado"
 
-#: ../../../src/ui.cpp:618
+#: ../../../src/ui.cpp:673
 #, c-format
 msgid "Generated (%s matures in %d more blocks)"
 msgstr "Generado (%s madura en %d bloques)"
 
-#: ../../../src/ui.cpp:622
+#: ../../../src/ui.cpp:677
 msgid "Generated - Warning: This block was not received by any other nodes and will probably not be accepted!"
 msgstr "Generado - Cuidado: Este bloque no se recibió de otros nodos y probablemente no sea aceptado!"
 
-#: ../../../src/ui.cpp:626
+#: ../../../src/ui.cpp:681
 msgid "Generated (not accepted)"
 msgstr "Generado (no aceptado)"
 
-#: ../../../src/ui.cpp:636
+#: ../../../src/ui.cpp:691
 msgid "From: "
 msgstr "De: "
 
-#: ../../../src/ui.cpp:660
+#: ../../../src/ui.cpp:715
 msgid "Received with: "
 msgstr "Recibido con: "
 
-#: ../../../src/ui.cpp:706
+#: ../../../src/ui.cpp:760
 msgid "Payment to yourself"
-msgstr "Pago para usted mismo"
+msgstr "Pago a ti mismo"
 
-#: ../../../src/ui.cpp:740
+#: ../../../src/ui.cpp:794
 msgid "To: "
 msgstr "Para: "
 
-#: ../../../src/ui.cpp:1055
+#: ../../../src/ui.cpp:1109
 msgid "    Generating"
 msgstr "    Generando"
 
-#: ../../../src/ui.cpp:1057
+#: ../../../src/ui.cpp:1111
 msgid "(not connected)"
 msgstr "(no conectado)"
 
-#: ../../../src/ui.cpp:1060
+#: ../../../src/ui.cpp:1114
 #, c-format
 msgid "     %d connections     %d blocks     %d transactions"
 msgstr "     %d conexiones     %d bloques     %d transacciones"
 
-#: ../../../src/ui.cpp:1165
-#: ../../../src/ui.cpp:2529
+#: ../../../src/ui.cpp:1171
+msgid "Wallet already encrypted."
+msgstr "La cartera ya esta encriptada."
+
+#: ../../../src/ui.cpp:1182
+msgid ""
+"Enter the new passphrase to the wallet.\n"
+"Please use a passphrase of 10 or more random characters, or eight or more words."
+msgstr ""
+"Introduce la nueva contraseña de cartera.\n"
+"Por favor utiliza un contraseña de 10 o mas caracteres aleatorios, u ocho o mas palabras."
+
+#: ../../../src/ui.cpp:1189
+#: ../../../src/ui.cpp:1280
+msgid "Error: The supplied passphrase was too short."
+msgstr "Error: La contraseña introducida es demasiado corta."
+
+#: ../../../src/ui.cpp:1193
+msgid ""
+"WARNING: If you encrypt your wallet and lose your passphrase, you will LOSE ALL OF YOUR BITCOINS!\n"
+"Are you sure you wish to encrypt your wallet?"
+msgstr ""
+"ATENCION: ¡Si encriptas tu cartera y pierdes la contraseña perderas TODOS TUS BITCOINS!\n"
+"¿Seguro que quieres seguir encriptando la cartera?"
+
+#: ../../../src/ui.cpp:1199
+msgid "Please re-enter your new wallet passphrase."
+msgstr "Por favor vuelve introducir la nueva contraseña."
+
+#: ../../../src/ui.cpp:1208
+#: ../../../src/ui.cpp:1302
+msgid "Error: the supplied passphrases didn't match."
+msgstr "Error: las contraseñas no son identicas."
+
+#: ../../../src/ui.cpp:1218
+msgid "Wallet encryption failed."
+msgstr "Encriptacion de cartera fallida."
+
+#: ../../../src/ui.cpp:1225
+msgid ""
+"Wallet Encrypted.\n"
+"Remember that encrypting your wallet cannot fully protect your bitcoins from being stolen by malware infecting your computer."
+msgstr ""
+"Cartera Encriptada.\n"
+"Recuerda que encriptando tu cartera no garantiza mantener a salvo tus bitcoins en caso de tener viruses en el ordenador."
+
+#: ../../../src/ui.cpp:1236
+msgid "Wallet is unencrypted, please encrypt it first."
+msgstr "Cartera no encriptada, intenta encriptar primero."
+
+#: ../../../src/ui.cpp:1271
+msgid "Enter the new passphrase for the wallet."
+msgstr "Introduce la nueva contraseña para la cartera."
+
+#: ../../../src/ui.cpp:1291
+msgid "Re-enter the new passphrase for the wallet."
+msgstr "Reintroduce la nueva contraseña para la cartera."
+
+#: ../../../src/ui.cpp:1323
+msgid "Wallet Passphrase Changed."
+msgstr "Contraseña de cartera cambiada."
+
+#: ../../../src/ui.cpp:1379
+#: ../../../src/ui.cpp:2825
 msgid "New Receiving Address"
 msgstr "Nueva dirección de recepción"
 
-#: ../../../src/ui.cpp:1166
-#: ../../../src/ui.cpp:2530
+#: ../../../src/ui.cpp:1380
+#: ../../../src/ui.cpp:2826
 msgid ""
 "You should use a new address for each payment you receive.\n"
 "\n"
@@ -131,399 +438,338 @@ msgstr ""
 "\n"
 "Etiqueta"
 
-#: ../../../src/ui.cpp:1235
+#: ../../../src/ui.cpp:1464
 msgid "<b>Status:</b> "
 msgstr "<b>Estado:</b> "
 
-#: ../../../src/ui.cpp:1240
+#: ../../../src/ui.cpp:1469
 msgid ", has not been successfully broadcast yet"
 msgstr ", no ha sido emitido satisfactoriamente todavía"
 
-#: ../../../src/ui.cpp:1242
+#: ../../../src/ui.cpp:1471
 #, c-format
 msgid ", broadcast through %d node"
 msgstr ", emitido mediante %d nodo"
 
-#: ../../../src/ui.cpp:1244
+#: ../../../src/ui.cpp:1473
 #, c-format
 msgid ", broadcast through %d nodes"
 msgstr ", emitido mediante %d nodos"
 
-#: ../../../src/ui.cpp:1248
+#: ../../../src/ui.cpp:1477
 msgid "<b>Date:</b> "
 msgstr "<b>Fecha:</b> "
 
-#: ../../../src/ui.cpp:1256
+#: ../../../src/ui.cpp:1485
 msgid "<b>Source:</b> Generated<br>"
 msgstr "<b>Fuente:</b> Generado<br>"
 
-#: ../../../src/ui.cpp:1262
-#: ../../../src/ui.cpp:1280
+#: ../../../src/ui.cpp:1491
+#: ../../../src/ui.cpp:1508
 msgid "<b>From:</b> "
 msgstr "<b>De:</b> "
 
-#: ../../../src/ui.cpp:1280
+#: ../../../src/ui.cpp:1508
 msgid "unknown"
 msgstr "desconocido"
 
-#: ../../../src/ui.cpp:1281
-#: ../../../src/ui.cpp:1305
-#: ../../../src/ui.cpp:1364
+#: ../../../src/ui.cpp:1509
+#: ../../../src/ui.cpp:1533
+#: ../../../src/ui.cpp:1592
 msgid "<b>To:</b> "
 msgstr "<b>Para:</b> "
 
-#: ../../../src/ui.cpp:1284
+#: ../../../src/ui.cpp:1512
 msgid " (yours, label: "
-msgstr "(suya, etiqueta: "
+msgstr "(tuya, etiqueta: "
 
-#: ../../../src/ui.cpp:1286
+#: ../../../src/ui.cpp:1514
 msgid " (yours)"
-msgstr "(suya)"
+msgstr "(tuya)"
 
-#: ../../../src/ui.cpp:1323
-#: ../../../src/ui.cpp:1335
-#: ../../../src/ui.cpp:1381
-#: ../../../src/ui.cpp:1398
+#: ../../../src/ui.cpp:1551
+#: ../../../src/ui.cpp:1563
+#: ../../../src/ui.cpp:1609
+#: ../../../src/ui.cpp:1626
 msgid "<b>Credit:</b> "
 msgstr "<b>Crédito:</b> "
 
-#: ../../../src/ui.cpp:1325
+#: ../../../src/ui.cpp:1553
 #, c-format
 msgid "(%s matures in %d more blocks)"
 msgstr "(%s madura en %d bloques)"
 
-#: ../../../src/ui.cpp:1327
+#: ../../../src/ui.cpp:1555
 msgid "(not accepted)"
 msgstr "(no aceptada)"
 
-#: ../../../src/ui.cpp:1372
-#: ../../../src/ui.cpp:1380
-#: ../../../src/ui.cpp:1395
+#: ../../../src/ui.cpp:1600
+#: ../../../src/ui.cpp:1608
+#: ../../../src/ui.cpp:1623
 msgid "<b>Debit:</b> "
 msgstr "<b>Débito:</b> "
 
-#: ../../../src/ui.cpp:1386
+#: ../../../src/ui.cpp:1614
 msgid "<b>Transaction fee:</b> "
 msgstr "<b>Comisión transacción:</b> "
 
-#: ../../../src/ui.cpp:1402
+#: ../../../src/ui.cpp:1630
 msgid "<b>Net amount:</b> "
-msgstr "<b>Cantidad de la red:</b> "
+msgstr "<b>Cantidad total:</b> "
 
-#: ../../../src/ui.cpp:1409
+#: ../../../src/ui.cpp:1637
 msgid "Message:"
 msgstr "Mensaje:"
 
-#: ../../../src/ui.cpp:1411
+#: ../../../src/ui.cpp:1639
 msgid "Comment:"
 msgstr "Comentario:"
 
-#: ../../../src/ui.cpp:1414
+#: ../../../src/ui.cpp:1642
 msgid "Generated coins must wait 120 blocks before they can be spent.  When you generated this block, it was broadcast to the network to be added to the block chain.  If it fails to get into the chain, it will change to \"not accepted\" and not be spendable.  This may occasionally happen if another node generates a block within a few seconds of yours."
-msgstr "Las monedas generadas deben esperar 120 bloques antes de ser gastadas. Cuando usted generó este bloque, fue emitido a la red para ser agregado a la cadena de bloques. Si falla al incluirse en la cadena, cambiará a \"no aceptado\" y no se podrá gastar. Esto puede ocurrir ocasionalmente si otro nodo genera un bloque apenas a unos segundos del suyo."
+msgstr "Las monedas generadas deben esperar 120 bloques antes de ser gastadas. Cuando has generado este bloque se emitió a la red para ser agregado en la cadena de bloques. Si falla al incluirse en la cadena, cambiará a \"no aceptado\" y no se podrá gastar. Esto puede ocurrir ocasionalmente si otro nodo genera un bloque casi al mismo tiempo que el tuyo."
 
-#: ../../../src/ui.cpp:1594
+#: ../../../src/ui.cpp:1826
 msgid "Cannot write autostart/bitcoin.desktop file"
 msgstr "No se puede escribir el fichero autostart/bitcoin.desktop"
 
-#: ../../../src/ui.cpp:1630
+#: ../../../src/ui.cpp:1862
 msgid "Main"
 msgstr "Principal"
 
-#: ../../../src/ui.cpp:1638
+#: ../../../src/ui.cpp:1872
 msgid "&Start Bitcoin on window system startup"
-msgstr "&Arrancar Bitcoin al iniciar el sistema"
+msgstr "&Arranca Bitcoin al iniciar el sistema"
 
-#: ../../../src/ui.cpp:1645
+#: ../../../src/ui.cpp:1879
 msgid "&Minimize on close"
-msgstr "&Minimizar al cerrar"
+msgstr "&Minimiza al cerrar"
 
-#: ../../../src/ui.cpp:1787
+#: ../../../src/ui.cpp:2021
 #, c-format
 msgid "version %s"
 msgstr "versión %s"
 
-#: ../../../src/ui.cpp:1899
+#: ../../../src/ui.cpp:2144
 msgid "Error in amount  "
 msgstr "Error en la cantidad  "
 
-#: ../../../src/ui.cpp:1899
-#: ../../../src/ui.cpp:1904
-#: ../../../src/ui.cpp:1909
-#: ../../../src/ui.cpp:1944
-#: ../../../src/uibase.cpp:55
+#: ../../../src/ui.cpp:2144
+#: ../../../src/ui.cpp:2149
+#: ../../../src/ui.cpp:2154
+#: ../../../src/ui.cpp:2207
+#: ../../../src/uibase.cpp:61
 msgid "Send Coins"
-msgstr "Enviar monedas"
+msgstr "Envia monedas"
 
-#: ../../../src/ui.cpp:1904
+#: ../../../src/ui.cpp:2149
 msgid "Amount exceeds your balance  "
 msgstr "La cantidad excede su balance  "
 
-#: ../../../src/ui.cpp:1909
+#: ../../../src/ui.cpp:2154
 msgid "Total exceeds your balance when the "
 msgstr "El total excede su balance cuando el "
 
-#: ../../../src/ui.cpp:1909
+#: ../../../src/ui.cpp:2154
 msgid " transaction fee is included  "
-msgstr " la comisión de la transaccion está incluida  "
+msgstr " la comisión de la transacción está incluida "
 
-#: ../../../src/ui.cpp:1927
+#: ../../../src/ui.cpp:2181
 msgid "Payment sent  "
 msgstr "Pago enviado  "
 
-#: ../../../src/ui.cpp:1927
-#: ../../../src/ui.cpp:1932
-#: ../../../src/ui.cpp:2076
-#: ../../../src/ui.cpp:2229
-#: ../../../src/main.cpp:3997
+#: ../../../src/ui.cpp:2181
+#: ../../../src/ui.cpp:2191
+#: ../../../src/ui.cpp:2341
+#: ../../../src/ui.cpp:2506
+#: ../../../src/wallet.cpp:1088
 msgid "Sending..."
 msgstr "Enviando..."
 
-#: ../../../src/ui.cpp:1944
+#: ../../../src/ui.cpp:2207
 msgid "Invalid address  "
 msgstr "Dirección inválida  "
 
-#: ../../../src/ui.cpp:1997
+#: ../../../src/ui.cpp:2262
 #, c-format
 msgid "Sending %s to %s"
 msgstr "Enviando %s a %s"
 
-#: ../../../src/ui.cpp:2070
-#: ../../../src/ui.cpp:2103
+#: ../../../src/ui.cpp:2335
+#: ../../../src/ui.cpp:2368
 msgid "CANCELLED"
 msgstr "CANCELADO"
 
-#: ../../../src/ui.cpp:2074
+#: ../../../src/ui.cpp:2339
 msgid "Cancelled"
 msgstr "Cancelado"
 
-#: ../../../src/ui.cpp:2076
+#: ../../../src/ui.cpp:2341
 msgid "Transfer cancelled  "
 msgstr "Transferencia cancelada  "
 
-#: ../../../src/ui.cpp:2129
+#: ../../../src/ui.cpp:2394
 msgid "Error: "
 msgstr "Error: "
 
-#: ../../../src/ui.cpp:2143
-#: ../../../src/ui.cpp:2214
-#: ../../../src/main.cpp:4016
+#: ../../../src/ui.cpp:2408
+#: ../../../src/ui.cpp:2477
+#: ../../../src/wallet.cpp:1106
 msgid "Insufficient funds"
 msgstr "Fondos insuficientes"
 
-#: ../../../src/ui.cpp:2148
+#: ../../../src/ui.cpp:2413
 msgid "Connecting..."
 msgstr "Conectando..."
 
-#: ../../../src/ui.cpp:2153
+#: ../../../src/ui.cpp:2418
 msgid "Unable to connect"
 msgstr "No es posible conectar"
 
-#: ../../../src/ui.cpp:2158
+#: ../../../src/ui.cpp:2423
 msgid "Requesting public key..."
 msgstr "Pidiendo clave pública..."
 
-#: ../../../src/ui.cpp:2170
+#: ../../../src/ui.cpp:2435
 msgid "Received public key..."
 msgstr "Clave pública recibida..."
 
-#: ../../../src/ui.cpp:2184
+#: ../../../src/ui.cpp:2449
 msgid "Recipient is not accepting transactions sent by IP address"
-msgstr "El destinatario no está aceptando transacciones enviadas por direcciones IP"
+msgstr "El destinatario no accepta transacciones enviadas a direcciones IP"
 
-#: ../../../src/ui.cpp:2186
+#: ../../../src/ui.cpp:2451
 msgid "Transfer was not accepted"
 msgstr "La transferencia no fue aceptada"
 
-#: ../../../src/ui.cpp:2195
+#: ../../../src/ui.cpp:2460
 msgid "Invalid response received"
 msgstr "Respuesta inválida recibida"
 
-#: ../../../src/ui.cpp:2210
+#: ../../../src/ui.cpp:2473
 msgid "Creating transaction..."
 msgstr "Creando transacción..."
 
-#: ../../../src/ui.cpp:2222
+#: ../../../src/ui.cpp:2496
 #, c-format
 msgid "This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds"
-msgstr "Esta transacción requiere de una comisión de al menos %s por su cantidad, complejidad o uso de fondos recibidos recientemente"
+msgstr "Esta transacción requiere una comisión de al menos %s por su cantidad, complejidad o uso de fondos recibidos recientemente"
 
-#: ../../../src/ui.cpp:2224
+#: ../../../src/ui.cpp:2498
 msgid "Transaction creation failed"
 msgstr "Fallo al crear la transacción."
 
-#: ../../../src/ui.cpp:2231
+#: ../../../src/ui.cpp:2508
 msgid "Transaction aborted"
 msgstr "Transacción abortada"
 
-#: ../../../src/ui.cpp:2239
+#: ../../../src/ui.cpp:2516
 msgid "Lost connection, transaction cancelled"
 msgstr "Conexión perdida, transacción cancelada"
 
-#: ../../../src/ui.cpp:2255
+#: ../../../src/ui.cpp:2532
 msgid "Sending payment..."
 msgstr "Enviando pago..."
 
-#: ../../../src/ui.cpp:2261
+#: ../../../src/ui.cpp:2544
 msgid "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."
-msgstr "La transacción fue rechazada. Esto puede haber ocurrido si alguna de las monedas fue gastada, o si ha usado una copia de wallet.dat y las monedas fueron gastadas en la copia pero no fueron marcadas como gastadas aqui."
+msgstr "La transacción fue rechazada. Esto puede haber ocurrido si alguna de las monedas ya estaba gastada o si ha usado una copia de wallet.dat y las monedas se gastaron en la copia pero no se han marcado como gastadas aqui."
 
-#: ../../../src/ui.cpp:2270
+#: ../../../src/ui.cpp:2553
 msgid "Waiting for confirmation..."
 msgstr "Esperando confirmación..."
 
-#: ../../../src/ui.cpp:2288
+#: ../../../src/ui.cpp:2570
 msgid ""
 "The payment was sent, but the recipient was unable to verify it.\n"
 "The transaction is recorded and will credit to the recipient,\n"
 "but the comment information will be blank."
 msgstr ""
-"El pago fue enviado, pero el receptor no pudo verificarlo.\n"
-"La transacción se grabó y dará el crédito al receptor,\n"
-"pero la información en los comentarios quedará en blanco."
+"El pago se ha enviado, pero el receptor no pudo verificarlo.\n"
+"La transacción se grabó y el saldo fue transferido\n"
+"pero la información de los comentarios quedará en blanco."
 
-#: ../../../src/ui.cpp:2297
+#: ../../../src/ui.cpp:2579
 msgid "Payment was sent, but an invalid response was received"
 msgstr "El pago fue enviado, pero se recibió una respuesta inválida"
 
-#: ../../../src/ui.cpp:2303
+#: ../../../src/ui.cpp:2585
 msgid "Payment completed"
 msgstr "Pago completado"
 
-#: ../../../src/ui.cpp:2334
-#: ../../../src/ui.cpp:2480
-#: ../../../src/ui.cpp:2517
+#: ../../../src/ui.cpp:2627
+#: ../../../src/ui.cpp:2773
+#: ../../../src/ui.cpp:2813
 msgid "Name"
 msgstr "Nombre"
 
-#: ../../../src/ui.cpp:2335
-#: ../../../src/ui.cpp:2480
-#: ../../../src/ui.cpp:2517
+#: ../../../src/ui.cpp:2628
+#: ../../../src/ui.cpp:2773
+#: ../../../src/ui.cpp:2813
 msgid "Address"
 msgstr "Dirección"
 
-#: ../../../src/ui.cpp:2337
-#: ../../../src/ui.cpp:2492
+#: ../../../src/ui.cpp:2630
+#: ../../../src/ui.cpp:2785
 msgid "Label"
 msgstr "Etiqueta"
 
-#: ../../../src/ui.cpp:2338
-#: ../../../src/uibase.cpp:837
+#: ../../../src/ui.cpp:2631
+#: ../../../src/uibase.cpp:847
 msgid "Bitcoin Address"
 msgstr "Dirección Bitcoin"
 
-#: ../../../src/ui.cpp:2462
+#: ../../../src/ui.cpp:2755
 msgid "This is one of your own addresses for receiving payments and cannot be entered in the address book.  "
 msgstr "Esta es una de sus direcciones para recibir pagos y no puede incluirse en la libreta de direcciones.  "
 
-#: ../../../src/ui.cpp:2480
-#: ../../../src/ui.cpp:2486
+#: ../../../src/ui.cpp:2773
+#: ../../../src/ui.cpp:2779
 msgid "Edit Address"
 msgstr "Editar dirección"
 
-#: ../../../src/ui.cpp:2492
+#: ../../../src/ui.cpp:2785
 msgid "Edit Address Label"
 msgstr "Editar etiqueta dirección"
 
-#: ../../../src/ui.cpp:2517
-#: ../../../src/ui.cpp:2523
+#: ../../../src/ui.cpp:2813
+#: ../../../src/ui.cpp:2819
 msgid "Add Address"
 msgstr "Agregar dirección"
 
-#: ../../../src/ui.cpp:2600
+#: ../../../src/ui.cpp:2906
 msgid "Bitcoin"
 msgstr "Bitcoin"
 
-#: ../../../src/ui.cpp:2602
+#: ../../../src/ui.cpp:2908
 msgid "Bitcoin - Generating"
 msgstr "Bitcoin - Generando"
 
-#: ../../../src/ui.cpp:2604
+#: ../../../src/ui.cpp:2910
 msgid "Bitcoin - (not connected)"
 msgstr "Bitcoin - (no conectado)"
 
-#: ../../../src/ui.cpp:2683
+#: ../../../src/ui.cpp:2989
 msgid "&Open Bitcoin"
 msgstr "&Abrir Bitcoin"
 
-#: ../../../src/ui.cpp:2684
+#: ../../../src/ui.cpp:2990
 msgid "&Send Bitcoins"
 msgstr "&Enviar Bitcoin"
 
-#: ../../../src/ui.cpp:2685
+#: ../../../src/ui.cpp:2991
 msgid "O&ptions..."
 msgstr "O&pciones"
 
-#: ../../../src/ui.cpp:2688
+#: ../../../src/ui.cpp:2994
 #: ../../../src/uibase.cpp:25
 msgid "E&xit"
 msgstr "S&alir"
 
-#: ../../../src/ui.cpp:2904
+#: ../../../src/ui.cpp:3220
 msgid "Program has crashed and will terminate.  "
 msgstr "El programa ha detectado un error y va a cerrarse.  "
 
-#: ../../../src/main.cpp:1866
-msgid "Warning: Disk space is low  "
-msgstr "Cuidado: Poco espacio en disco  "
-
-#: ../../../src/main.cpp:3990
-#, c-format
-msgid "Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds  "
-msgstr "Error: Esta transacción requiere de una comisión de al menos %s por su cantidad, complejidad o uso de fondos recibidos recientemente "
-
-#: ../../../src/main.cpp:3992
-msgid "Error: Transaction creation failed  "
-msgstr "Error: La creación de la transacción falló  "
-
-#: ../../../src/main.cpp:4001
-msgid "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."
-msgstr "Error: La transacción fue rechazada. Esto puede haber ocurrido si alguna de las monedas ya fue gastada, o si ha usado un copia de wallet.dat y las monedas fueron gastadas en la copia pero no han sido marcadas como gastadas aqui."
-
-#: ../../../src/main.cpp:4014
-msgid "Invalid amount"
-msgstr "Cantidad erronea"
-
-#: ../../../src/main.cpp:4021
-msgid "Invalid bitcoin address"
-msgstr "Dirección Bitcoin inválida"
-
-#: ../../../src/rpc.cpp:1802
-#: ../../../src/rpc.cpp:1804
-#, c-format
-msgid "To use the %s option"
-msgstr "Para usar la opción %s"
-
-#: ../../../src/rpc.cpp:1806
-#, c-format
-msgid ""
-"Warning: %s, you must set rpcpassword=<password>\n"
-"in the configuration file: %s\n"
-"If the file does not exist, create it with owner-readable-only file permissions.\n"
-msgstr ""
-"Precaución: %s, debes especificar rpcpassword=<password>\n"
-"en el archivo de configuración: %s\n"
-"Si el archivo no existe, debes crearlo con permisos de lectura al autor solamente.\n"
-
-#: ../../../src/rpc.cpp:1974
-#, c-format
-msgid ""
-"You must set rpcpassword=<password> in the configuration file:\n"
-"%s\n"
-"If the file does not exist, create it with owner-readable-only file permissions."
-msgstr ""
-"Debes especificar rpcpassword=<password> en el archivo de configuración:\n"
-"%s\n"
-"Si el archivo no existe, debes crearlo con permisos de lectura al autor solamente."
-
-#: ../../../src/util.cpp:866
-msgid "Warning: Please check that your computer's date and time are correct.  If your clock is wrong Bitcoin will not work properly."
-msgstr "Precaución: Por favor revisa que la fecha y hora de tu computador son correctas. Si tu reloj está mal, Bitcoin no funcionará correctamente."
-
-#: ../../../src/util.cpp:899
-msgid "beta"
-msgstr "beta"
-
 #: ../../../src/uibase.cpp:28
 msgid "&File"
 msgstr "&Archivo"
@@ -532,152 +778,160 @@ msgstr "&Archivo"
 msgid "&Your Receiving Addresses..."
 msgstr "&Tus direcciones de recepción..."
 
-#: ../../../src/uibase.cpp:36
+#: ../../../src/uibase.cpp:35
+msgid "&Encrypt Wallet..."
+msgstr "&Encriptar cartera..."
+
+#: ../../../src/uibase.cpp:38
+msgid "&Change Wallet Encryption Passphrase..."
+msgstr "&Cambiar contraseña de cartera..."
+
+#: ../../../src/uibase.cpp:42
 msgid "&Options..."
 msgstr "&Opciones..."
 
-#: ../../../src/uibase.cpp:39
+#: ../../../src/uibase.cpp:45
 msgid "&Settings"
 msgstr "&Configuración"
 
-#: ../../../src/uibase.cpp:43
+#: ../../../src/uibase.cpp:49
 msgid "&About..."
 msgstr "&Acerca de..."
 
-#: ../../../src/uibase.cpp:46
+#: ../../../src/uibase.cpp:52
 msgid "&Help"
 msgstr "&Ayuda"
 
-#: ../../../src/uibase.cpp:56
+#: ../../../src/uibase.cpp:62
 msgid "Address Book"
 msgstr "Libreta de direcciones"
 
-#: ../../../src/uibase.cpp:69
+#: ../../../src/uibase.cpp:75
 msgid "Your Bitcoin Address:"
 msgstr "Su dirección Bitcoin:"
 
-#: ../../../src/uibase.cpp:76
+#: ../../../src/uibase.cpp:82
 msgid " &New... "
 msgstr " &Nuevo... "
 
-#: ../../../src/uibase.cpp:79
-#: ../../../src/uibase.cpp:780
-#: ../../../src/uibase.cpp:883
+#: ../../../src/uibase.cpp:85
+#: ../../../src/uibase.cpp:790
+#: ../../../src/uibase.cpp:893
 msgid " &Copy to Clipboard "
 msgstr " &Copiar al portapapeles "
 
-#: ../../../src/uibase.cpp:93
+#: ../../../src/uibase.cpp:99
 msgid "Balance:"
 msgstr "Balance:"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " All"
 msgstr " Todo"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " Sent"
 msgstr " Enviado"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " Received"
 msgstr " Recibido"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " In Progress"
 msgstr " En progreso"
 
-#: ../../../src/uibase.cpp:130
+#: ../../../src/uibase.cpp:136
 msgid "All Transactions"
 msgstr "Todas las transacciones"
 
-#: ../../../src/uibase.cpp:141
+#: ../../../src/uibase.cpp:147
 msgid "Sent/Received"
 msgstr "Enviado/Recibido"
 
-#: ../../../src/uibase.cpp:152
+#: ../../../src/uibase.cpp:158
 msgid "Sent"
 msgstr "Enviado"
 
-#: ../../../src/uibase.cpp:163
+#: ../../../src/uibase.cpp:169
 msgid "Received"
 msgstr "Recibido"
 
-#: ../../../src/uibase.cpp:302
-#: ../../../src/uibase.cpp:443
-#: ../../../src/uibase.cpp:542
-#: ../../../src/uibase.cpp:722
-#: ../../../src/uibase.cpp:783
-#: ../../../src/uibase.cpp:892
-#: ../../../src/uibase.cpp:981
+#: ../../../src/uibase.cpp:312
+#: ../../../src/uibase.cpp:453
+#: ../../../src/uibase.cpp:552
+#: ../../../src/uibase.cpp:732
+#: ../../../src/uibase.cpp:793
+#: ../../../src/uibase.cpp:902
+#: ../../../src/uibase.cpp:991
 msgid "OK"
 msgstr "OK"
 
-#: ../../../src/uibase.cpp:345
+#: ../../../src/uibase.cpp:355
 msgid "&Start Bitcoin on system startup"
-msgstr "&Arrancar Bitcoin al iniciar el sistema"
+msgstr "&Arranca Bitcoin al iniciar el sistema"
 
-#: ../../../src/uibase.cpp:348
+#: ../../../src/uibase.cpp:358
 msgid "&Minimize to the tray instead of the taskbar"
-msgstr "&Minimizar a la bandeja en vez de a la barra de tareas"
+msgstr "&Minimiza a la bandeja en vez de a la barra de tareas"
 
-#: ../../../src/uibase.cpp:351
+#: ../../../src/uibase.cpp:361
 msgid "Map port using &UPnP"
-msgstr "Mapear el puerto usando &UPnP"
+msgstr "Mapea el puerto usando &UPnP"
 
-#: ../../../src/uibase.cpp:354
+#: ../../../src/uibase.cpp:364
 msgid "M&inimize to the tray on close"
-msgstr "M&inimizar a la bandeja al cerrar"
+msgstr "M&inimiza a la bandeja al cerrar"
 
-#: ../../../src/uibase.cpp:360
-msgid "&Connect through socks4 proxy: "
-msgstr "&Conectar usando un proxy socks4: "
+#: ../../../src/uibase.cpp:370
+msgid "&Connect through socks4 proxy (requires restart to apply): "
+msgstr "&Conecta usando un proxy socks4 (necesita reinicio): "
 
-#: ../../../src/uibase.cpp:371
+#: ../../../src/uibase.cpp:381
 msgid "Proxy &IP:"
-msgstr "Proxy &IP:"
+msgstr "&IP proxy:"
 
-#: ../../../src/uibase.cpp:379
+#: ../../../src/uibase.cpp:389
 msgid " &Port:"
 msgstr " &Puerto:"
 
-#: ../../../src/uibase.cpp:392
+#: ../../../src/uibase.cpp:402
 msgid "Optional transaction fee per KB that helps make sure your transactions are processed quickly.  Most transactions are 1KB.  Fee 0.01 recommended."
 msgstr "Comisión opcional a las transacciones por KB que ayuda a asegurar que tus transacciones son procesadas rápidamente. La mayoría de las transacciones son de 1KB. Se recomienda una comisión de 0.01."
 
-#: ../../../src/uibase.cpp:399
+#: ../../../src/uibase.cpp:409
 msgid "Pay transaction fee:"
 msgstr "Comisión de la transacción:"
 
-#: ../../../src/uibase.cpp:420
+#: ../../../src/uibase.cpp:430
 msgid "// [don't translate] Test panel 2 for future expansion"
 msgstr ""
 
-#: ../../../src/uibase.cpp:424
+#: ../../../src/uibase.cpp:434
 msgid "// [don't translate] Let's not start multiple pages until the first page is filled up"
 msgstr ""
 
-#: ../../../src/uibase.cpp:446
-#: ../../../src/uibase.cpp:668
-#: ../../../src/uibase.cpp:727
-#: ../../../src/uibase.cpp:786
-#: ../../../src/uibase.cpp:895
-#: ../../../src/uibase.cpp:984
+#: ../../../src/uibase.cpp:456
+#: ../../../src/uibase.cpp:678
+#: ../../../src/uibase.cpp:737
+#: ../../../src/uibase.cpp:796
+#: ../../../src/uibase.cpp:905
+#: ../../../src/uibase.cpp:994
 msgid "Cancel"
 msgstr "Cancelar"
 
-#: ../../../src/uibase.cpp:449
+#: ../../../src/uibase.cpp:459
 msgid "&Apply"
 msgstr "&Aplicar"
 
-#: ../../../src/uibase.cpp:508
+#: ../../../src/uibase.cpp:518
 msgid "Bitcoin "
 msgstr "Bitcoin "
 
-#: ../../../src/uibase.cpp:514
+#: ../../../src/uibase.cpp:524
 msgid "version"
 msgstr "versión"
 
-#: ../../../src/uibase.cpp:525
+#: ../../../src/uibase.cpp:535
 msgid ""
 "Copyright (c) 2009-2011 Bitcoin Developers\n"
 "\n"
@@ -701,39 +955,39 @@ msgstr ""
 "OpenSSL Toolkit (http://www.openssl.org/) y software criptográfico escrito por \n"
 "Eric Young (eay@cryptsoft.com) y UPnP software escrito por Thomas Bernard."
 
-#: ../../../src/uibase.cpp:581
+#: ../../../src/uibase.cpp:591
 msgid "Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
-msgstr "Ponga una dirección Bitcoin (ejemplo: 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
+msgstr "Introduce una dirección Bitcoin (ejemplo: 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
 
-#: ../../../src/uibase.cpp:595
+#: ../../../src/uibase.cpp:605
 msgid "Pay &To:"
 msgstr "Pagar &A:"
 
-#: ../../../src/uibase.cpp:610
+#: ../../../src/uibase.cpp:620
 msgid "&Paste"
 msgstr "&Pegar"
 
-#: ../../../src/uibase.cpp:613
+#: ../../../src/uibase.cpp:623
 msgid " Address &Book..."
 msgstr " Libreta &Direcciones..."
 
-#: ../../../src/uibase.cpp:620
+#: ../../../src/uibase.cpp:630
 msgid "&Amount:"
 msgstr "&Cantidad:"
 
-#: ../../../src/uibase.cpp:630
+#: ../../../src/uibase.cpp:640
 msgid "T&ransfer:"
 msgstr "T&ransferir:"
 
-#: ../../../src/uibase.cpp:636
+#: ../../../src/uibase.cpp:646
 msgid " Standard"
 msgstr " Estándar"
 
-#: ../../../src/uibase.cpp:663
+#: ../../../src/uibase.cpp:673
 msgid "&Send"
-msgstr "&Enviar"
+msgstr "&Envia"
 
-#: ../../../src/uibase.cpp:711
+#: ../../../src/uibase.cpp:721
 msgid ""
 "\n"
 "\n"
@@ -743,225 +997,80 @@ msgstr ""
 "\n"
 "Conenctando..."
 
-#: ../../../src/uibase.cpp:761
+#: ../../../src/uibase.cpp:771
 msgid "These are your Bitcoin addresses for receiving payments.  You may want to give a different one to each sender so you can keep track of who is paying you.  The highlighted address is displayed in the main window."
 msgstr "Estas son tus direcciones Bitcoin para recibir pagos. Puedes darle una diferente a cada emisor para saber quien te está pagando. La dirección resaltada se muestra en la ventana principal."
 
-#: ../../../src/uibase.cpp:774
-#: ../../../src/uibase.cpp:886
+#: ../../../src/uibase.cpp:784
+#: ../../../src/uibase.cpp:896
 msgid "&Edit..."
-msgstr "&Editar..."
+msgstr "&Edita..."
 
-#: ../../../src/uibase.cpp:777
-#: ../../../src/uibase.cpp:889
+#: ../../../src/uibase.cpp:787
+#: ../../../src/uibase.cpp:899
 msgid " &New Address... "
 msgstr " &Nueva dirección... "
 
-#: ../../../src/uibase.cpp:849
+#: ../../../src/uibase.cpp:859
 msgid "Sending"
 msgstr "Enviando"
 
-#: ../../../src/uibase.cpp:857
+#: ../../../src/uibase.cpp:867
 msgid "These are your Bitcoin addresses for receiving payments.  You can give a different one to each sender to keep track of who is paying you.  The highlighted address will be displayed in the main window."
 msgstr "Estas son tus direcciones Bitcoin para recibir pagos. Puedes darle una diferente a cada emisor para saber quien te está pagando. La dirección resaltada se muestra en la ventana principal."
 
-#: ../../../src/uibase.cpp:870
+#: ../../../src/uibase.cpp:880
 msgid "Receiving"
 msgstr "Recibiendo"
 
-#: ../../../src/uibase.cpp:880
+#: ../../../src/uibase.cpp:890
 msgid "&Delete"
-msgstr "&Borrar"
-
-#: ../../../src/init.cpp:142
-msgid "Bitcoin version"
-msgstr "versión Bitcoin"
-
-#: ../../../src/init.cpp:143
-msgid "Usage:"
-msgstr "Uso:"
-
-#: ../../../src/init.cpp:145
-msgid "Send command to -server or bitcoind\n"
-msgstr "Enviar comando a bitcoin corriendo con -server o a bitcoind\n"
-
-#: ../../../src/init.cpp:146
-msgid "List commands\n"
-msgstr "Lista de comandos\n"
-
-#: ../../../src/init.cpp:147
-msgid "Get help for a command\n"
-msgstr "Recibir ayuda para un comando\n"
-
-#: ../../../src/init.cpp:148
-msgid "Options:\n"
-msgstr "Opciones:\n"
-
-#: ../../../src/init.cpp:149
-msgid "Specify configuration file (default: bitcoin.conf)\n"
-msgstr "Especificar archivo de configuración (predeterminado: bitcoin.conf)\n"
-
-#: ../../../src/init.cpp:150
-msgid "Specify pid file (default: bitcoind.pid)\n"
-msgstr "Especificar archivo pid (predeterminado: bitcoin.pid)\n"
-
-#: ../../../src/init.cpp:151
-msgid "Generate coins\n"
-msgstr "Generar monedas\n"
-
-#: ../../../src/init.cpp:152
-msgid "Don't generate coins\n"
-msgstr "No generar monedas\n"
-
-#: ../../../src/init.cpp:153
-msgid "Start minimized\n"
-msgstr "Arrancar minimizado\n"
-
-#: ../../../src/init.cpp:154
-msgid "Specify data directory\n"
-msgstr "Especificar directorio para los datos\n"
-
-#: ../../../src/init.cpp:155
-msgid "Connect through socks4 proxy\n"
-msgstr "Conectar mediante proxy socks4\n"
-
-#: ../../../src/init.cpp:156
-msgid "Allow DNS lookups for addnode and connect\n"
-msgstr "Permitir búsqueda DNS para addnode y connect\n"
-
-#: ../../../src/init.cpp:157
-msgid "Add a node to connect to\n"
-msgstr "Agregar un nodo para conectarse\n"
+msgstr "&Borra"
 
-#: ../../../src/init.cpp:158
-msgid "Connect only to the specified node\n"
-msgstr "Conectar solo al nodo especificado\n"
-
-#: ../../../src/init.cpp:159
-msgid "Don't accept connections from outside\n"
-msgstr "No aceptar conexiones desde el exterior\n"
-
-#: ../../../src/init.cpp:162
-msgid "Don't attempt to use UPnP to map the listening port\n"
-msgstr "No intentar usar UPnP para mapear el puerto de entrada\n"
-
-#: ../../../src/init.cpp:164
-msgid "Attempt to use UPnP to map the listening port\n"
-msgstr "Intentar usar UPnP para mapear el puerto de escucha.\n"
-
-#: ../../../src/init.cpp:167
-msgid "Fee per KB to add to transactions you send\n"
-msgstr "Comisión por KB para agregar a las transacciones que envias\n"
-
-#: ../../../src/init.cpp:169
-msgid "Accept command line and JSON-RPC commands\n"
-msgstr "Aceptar comandos por línea de comandos y JSON-RPC\n"
-
-#: ../../../src/init.cpp:172
-msgid "Run in the background as a daemon and accept commands\n"
-msgstr "Correr en el fondo como demonio y aceptar comandos\n"
-
-#: ../../../src/init.cpp:174
-msgid "Use the test network\n"
-msgstr "Usar la red de pruebas\n"
-
-#: ../../../src/init.cpp:175
-msgid "Username for JSON-RPC connections\n"
-msgstr "Usuario para las conexiones JSON-RPC\n"
-
-#: ../../../src/init.cpp:176
-msgid "Password for JSON-RPC connections\n"
-msgstr "Contraseña para las conexiones JSON-RPC\n"
-
-#: ../../../src/init.cpp:177
-msgid "Listen for JSON-RPC connections on <port> (default: 8332)\n"
-msgstr "Escuchar conexiones JSON-RPC en el puerto <puerto> (predeterminado: 8332)\n"
-
-#: ../../../src/init.cpp:178
-msgid "Allow JSON-RPC connections from specified IP address\n"
-msgstr "Permitir conexiones JSON-RPC desde la dirección IP especificada\n"
-
-#: ../../../src/init.cpp:179
-msgid "Send commands to node running on <ip> (default: 127.0.0.1)\n"
-msgstr "Enviar comando al nodo ejecutándose en <ip> (predeterminado: 127.0.0.1)\n"
-
-#: ../../../src/init.cpp:180
-msgid "Set key pool size to <n> (default: 100)\n"
-msgstr "Ajustar el tamaño de la llave (key) de la piscina (pool) a <n> (predeterminado: 100)\n"
-
-#: ../../../src/init.cpp:181
-msgid "Rescan the block chain for missing wallet transactions\n"
-msgstr "Re-escanear la cadena de bloques para transacciones perdidas de la billetera\n"
-
-#: ../../../src/init.cpp:185
-msgid ""
-"\n"
-"SSL options: (see the Bitcoin Wiki for SSL setup instructions)\n"
-msgstr ""
-"\n"
-"Opciones SSL: (ver la Bitcoin Wiki para instrucciones de configuración SSL)\n"
-
-#: ../../../src/init.cpp:186
-msgid "Use OpenSSL (https) for JSON-RPC connections\n"
-msgstr "Usar OpenSSL (https) para las conexiones JSON-RPC\n"
-
-#: ../../../src/init.cpp:187
-msgid "Server certificate file (default: server.cert)\n"
-msgstr "Archivo de certificado del servidor (Predeterminado: server.cert)\n"
+#: ../../../src/util.cpp:870
+msgid "Warning: Please check that your computer's date and time are correct.  If your clock is wrong Bitcoin will not work properly."
+msgstr "Precaución: Por favor revisa que la fecha y hora de tu ordenador son correctas. Si tu reloj está mal Bitcoin no funcionará correctamente."
 
-#: ../../../src/init.cpp:188
-msgid "Server private key (default: server.pem)\n"
-msgstr "Clave privada del servidor (Predeterminado: server.pem)\n"
+#: ../../../src/util.cpp:904
+msgid "beta"
+msgstr "beta"
 
-#: ../../../src/init.cpp:189
-msgid "Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
-msgstr "Cifrados aceptados (Predeterminado: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
+#: ../../../src/wallet.cpp:1073
+msgid "Error: Wallet locked, unable to create transaction  "
+msgstr "Error: Cartera bloqueada, no se puede crear la transacción"
 
-#: ../../../src/init.cpp:193
-msgid "This help message\n"
-msgstr "Este mensaje de ayuda\n"
-
-#: ../../../src/init.cpp:330
+#: ../../../src/wallet.cpp:1081
 #, c-format
-msgid "Cannot obtain a lock on data directory %s.  Bitcoin is probably already running."
-msgstr "No se puede obtener el bloqueo en el directorio de datos %s. Probablemente el cliente de Bitcoin ya se está ejecutando."
-
-#: ../../../src/init.cpp:356
-msgid "Error loading addr.dat      \n"
-msgstr "Error cargando addr.dat      \n"
-
-#: ../../../src/init.cpp:362
-msgid "Error loading blkindex.dat      \n"
-msgstr "Error cargando blkindex.dat      \n"
-
-#: ../../../src/init.cpp:369
-msgid "Error loading wallet.dat      \n"
-msgstr "Error cargando wallet.dat      \n"
+msgid "Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds  "
+msgstr "Error: Esta transacción requiere de una comisión de al menos %s por su cantidad, complejidad o uso de fondos recibidos recientemente "
 
-#: ../../../src/init.cpp:449
-msgid "Invalid -proxy address"
-msgstr "Dirección proxy - inválida"
+#: ../../../src/wallet.cpp:1083
+msgid "Error: Transaction creation failed  "
+msgstr "Error: La creación de la transacción falló  "
 
-#: ../../../src/init.cpp:472
-msgid "Invalid amount for -paytxfee=<amount>"
-msgstr "Cantidad inválida para -paytxfee=<cantidad>"
+#: ../../../src/wallet.cpp:1092
+msgid "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."
+msgstr "Error: La transacción fue rechazada. Esto puede haber ocurrido si alguna de las monedas ya estaba gastada o si ha usado una copia de wallet.dat y las monedas se gastaron en la copia pero no se han marcado como gastadas aqui."
 
-#: ../../../src/init.cpp:476
-msgid "Warning: -paytxfee is set very high.  This is the transaction fee you will pay if you send a transaction."
-msgstr "Precaución: -paytxfee está configurado muy alto. Esta es la comisión que pagarás si envias una transacción."
+#: ../../../src/wallet.cpp:1104
+msgid "Invalid amount"
+msgstr "Cantidad erronea"
 
-#: ../../../src/uibase.h:147
+#: ../../../src/uibase.h:151
 msgid "Transaction Details"
 msgstr "Detalles de la transacción"
 
-#: ../../../src/uibase.h:199
+#: ../../../src/uibase.h:203
 msgid "Options"
 msgstr "Opciones"
 
-#: ../../../src/uibase.h:228
+#: ../../../src/uibase.h:232
 msgid "About Bitcoin"
 msgstr "Acerca de Bitcoin"
 
-#: ../../../src/uibase.h:337
+#: ../../../src/uibase.h:341
 msgid "Your Bitcoin Addresses"
 msgstr "Sus direcciones Bitcoin"
+
+#~ msgid "Invalid bitcoin address"
+#~ msgstr "Dirección Bitcoin inválida"
index 836e91d..13467f2 100644 (file)
Binary files a/locale/nl/LC_MESSAGES/bitcoin.mo and b/locale/nl/LC_MESSAGES/bitcoin.mo differ
index 986a1e5..5074f21 100644 (file)
@@ -2,9 +2,9 @@ msgid ""
 msgstr ""
 "Project-Id-Version: \n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2011-05-15 18:23+0100\n"
-"PO-Revision-Date: 2011-05-15 18:23+0100\n"
-"Last-Translator: Pieter Wuille <sipa@ulyssis.org>\n"
+"POT-Creation-Date: 2011-09-22 19:03+0100\n"
+"PO-Revision-Date: 2011-09-22 19:19+0100\n"
+"Last-Translator: Pieter Wuille <pieter.wuille@gmail.com>\n"
 "Language-Team: \n"
 "Language: \n"
 "MIME-Version: 1.0\n"
@@ -12,116 +12,488 @@ msgstr ""
 "Content-Transfer-Encoding: 8bit\n"
 "X-Poedit-KeywordsList: _;gettext;gettext_noop\n"
 "X-Poedit-Basepath: .\n"
+"X-Poedit-Language: Dutch\n"
 "X-Poedit-SearchPath-0: ../../..\n"
 
-#: ../../../src/net.cpp:1499
+#: ../../../src/init.cpp:163
+msgid "Bitcoin version"
+msgstr "Bitcoin versie"
+
+#: ../../../src/init.cpp:164
+msgid "Usage:"
+msgstr "Mededeling:"
+
+#: ../../../src/init.cpp:166
+msgid "Send command to -server or bitcoind\n"
+msgstr "Zend commando naar -server of bitcoind\n"
+
+#: ../../../src/init.cpp:167
+msgid "List commands\n"
+msgstr "List van commando's\n"
+
+#: ../../../src/init.cpp:168
+msgid "Get help for a command\n"
+msgstr "Toon hulp voor een commando\n"
+
+#: ../../../src/init.cpp:169
+msgid "Options:\n"
+msgstr "Opties:\n"
+
+#: ../../../src/init.cpp:170
+msgid "Specify configuration file (default: bitcoin.conf)\n"
+msgstr "Specifieer configuratiebestand (standaard: bitcoin.conf)\n"
+
+#: ../../../src/init.cpp:171
+msgid "Specify pid file (default: bitcoind.pid)\n"
+msgstr "Specifieer pid-bestand (standaard: bitcoind.pid)\n"
+
+#: ../../../src/init.cpp:172
+msgid "Generate coins\n"
+msgstr "Genereer coins\n"
+
+#: ../../../src/init.cpp:173
+msgid "Don't generate coins\n"
+msgstr "Genereer geen coins\n"
+
+#: ../../../src/init.cpp:174
+msgid "Start minimized\n"
+msgstr "Geminimaliseerd starten\n"
+
+#: ../../../src/init.cpp:175
+msgid "Specify data directory\n"
+msgstr "Stel datamap in\n"
+
+#: ../../../src/init.cpp:176
+msgid "Specify connection timeout (in milliseconds)\n"
+msgstr "Gelieve de time-out tijd te specifieren (in milliseconden)\n"
+
+#: ../../../src/init.cpp:177
+msgid "Connect through socks4 proxy\n"
+msgstr "Verbind via socks4 proxy\n"
+
+#: ../../../src/init.cpp:178
+msgid "Allow DNS lookups for addnode and connect\n"
+msgstr "Sta DNS-opzoeking toe voor addnode en connect\n"
+
+#: ../../../src/init.cpp:179
+msgid "Add a node to connect to\n"
+msgstr "Voeg een node toe om mee te verbinden\n"
+
+#: ../../../src/init.cpp:180
+msgid "Connect only to the specified node\n"
+msgstr "Verbind alleen met deze node\n"
+
+#: ../../../src/init.cpp:181
+msgid "Don't accept connections from outside\n"
+msgstr "Sta geen verbindingen van buitenaf toe\n"
+
+#: ../../../src/init.cpp:184
+msgid "Don't attempt to use UPnP to map the listening port\n"
+msgstr "Probeer geen UPnP te gebruiken om de poort waarop geluisterd wordt te mappen\n"
+
+#: ../../../src/init.cpp:186
+msgid "Attempt to use UPnP to map the listening port\n"
+msgstr "Probeer UPnP te gebruiken om de poort waarop geluisterd wordt te mappen\n"
+
+#: ../../../src/init.cpp:189
+msgid "Fee per KB to add to transactions you send\n"
+msgstr "Fooi per KB om aan transacties die gezonden worden toe te voegen\n"
+
+#: ../../../src/init.cpp:191
+msgid "Accept command line and JSON-RPC commands\n"
+msgstr "Aanvaard commandolijn en JSON-RPC commando's\n"
+
+#: ../../../src/init.cpp:194
+msgid "Run in the background as a daemon and accept commands\n"
+msgstr "Draai in de achtergrond als daemon en aanvaard commando's\n"
+
+#: ../../../src/init.cpp:196
+msgid "Use the test network\n"
+msgstr "Gebruik het test-netwerk\n"
+
+#: ../../../src/init.cpp:197
+msgid "Username for JSON-RPC connections\n"
+msgstr "Gebruikersnaam voor JSON-RPC verbindingen\n"
+
+#: ../../../src/init.cpp:198
+msgid "Password for JSON-RPC connections\n"
+msgstr "Wachtwoord voor JSON-RPC verbindingen\n"
+
+#: ../../../src/init.cpp:199
+msgid "Listen for JSON-RPC connections on <port> (default: 8332)\n"
+msgstr "Luister voor JSON-RPC verbindingen op <poort> (standaard: 8332)\n"
+
+#: ../../../src/init.cpp:200
+msgid "Allow JSON-RPC connections from specified IP address\n"
+msgstr "Enkel JSON-RPC verbindingen van opgegeven IP adres toestaan\n"
+
+#: ../../../src/init.cpp:201
+msgid "Send commands to node running on <ip> (default: 127.0.0.1)\n"
+msgstr "Zend commando's naar proces dat op <ip> draait (standaard: 127.0.0.1)\n"
+
+#: ../../../src/init.cpp:202
+msgid "Set key pool size to <n> (default: 100)\n"
+msgstr "Stel sleutelpoelgrootte in op <n> (standaard: 100)\n"
+
+#: ../../../src/init.cpp:203
+msgid "Rescan the block chain for missing wallet transactions\n"
+msgstr "Doorzoek de blokken database voor ontbrekende portefeuille-transacties\n"
+
+#: ../../../src/init.cpp:207
+msgid ""
+"\n"
+"SSL options: (see the Bitcoin Wiki for SSL setup instructions)\n"
+msgstr ""
+"\n"
+"SSL opties: (zie de Bitcoin wiki voor SSL instructies)\n"
+
+#: ../../../src/init.cpp:208
+msgid "Use OpenSSL (https) for JSON-RPC connections\n"
+msgstr "Gebruik OpenSSL (https) voor JSON-RPC verbindingen\n"
+
+#: ../../../src/init.cpp:209
+msgid "Server certificate file (default: server.cert)\n"
+msgstr "Certificaat-bestand voor server (standaard: server.cert)\n"
+
+#: ../../../src/init.cpp:210
+msgid "Server private key (default: server.pem)\n"
+msgstr "Geheime sleutel voor server (standaard: server.pem)\n"
+
+#: ../../../src/init.cpp:211
+msgid "Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
+msgstr "Aanvaardbare ciphers (standaard: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
+
+#: ../../../src/init.cpp:215
+msgid "This help message\n"
+msgstr "Dit helpbericht\n"
+
+#: ../../../src/init.cpp:353
+#, c-format
+msgid "Cannot obtain a lock on data directory %s.  Bitcoin is probably already running."
+msgstr "Kan geen lock op de gegevensdirectory %s verkrijgen. Bitcoin draait vermoedelijk reeds."
+
+#: ../../../src/init.cpp:379
+msgid "Error loading addr.dat      \n"
+msgstr "Fout bij laden van bestand addr.dat      \n"
+
+#: ../../../src/init.cpp:385
+msgid "Error loading blkindex.dat      \n"
+msgstr "Fout bij laden van bestand blkindex.dat      \n"
+
+#: ../../../src/init.cpp:396
+msgid "Error loading wallet.dat: Wallet corrupted      \n"
+msgstr "Fout bij laden van bestand wallet.dat: portefeuille beschadigd      \n"
+
+#: ../../../src/init.cpp:398
+msgid "Error loading wallet.dat: Wallet requires newer version of Bitcoin      \n"
+msgstr "Fout bij laden van bestand wallet.dat: portefeuille vereist nieuwere versie van Bitcoin\n"
+
+#: ../../../src/init.cpp:400
+msgid "Error loading wallet.dat      \n"
+msgstr "Fout bij laden van bestand wallet.dat      \n"
+
+#: ../../../src/init.cpp:489
+msgid "Invalid -proxy address"
+msgstr "Foutief -proxy adres"
+
+#: ../../../src/init.cpp:514
+msgid "Invalid amount for -paytxfee=<amount>"
+msgstr "Ongeldig bedrag voor -paytxfee=<bedrag>"
+
+#: ../../../src/init.cpp:518
+msgid "Warning: -paytxfee is set very high.  This is the transaction fee you will pay if you send a transaction."
+msgstr "Waarschuwing: -paytxfee is zeer hoog ingesteld.  Dit is de fooi die betaald wordt bij het zenden van een transactie."
+
+#: ../../../src/rpc.cpp:2035
+#: ../../../src/rpc.cpp:2037
+#, c-format
+msgid "To use the %s option"
+msgstr "Om de %s optie te gebruiken"
+
+#: ../../../src/rpc.cpp:2039
+#, c-format
+msgid ""
+"Warning: %s, you must set rpcpassword=<password>\n"
+"in the configuration file: %s\n"
+"If the file does not exist, create it with owner-readable-only file permissions.\n"
+msgstr ""
+"Waarschuwing: %s, rpcpassword=<password> moet ingesteld zijn\n"
+"in het configuratie bestand: %s\n"
+"Als het bestand nog niet bestaat, maak het dan aan met enkel-leesbaar-door-eigenaar rechten.\n"
+
+#: ../../../src/rpc.cpp:2215
+#, c-format
+msgid ""
+"You must set rpcpassword=<password> in the configuration file:\n"
+"%s\n"
+"If the file does not exist, create it with owner-readable-only file permissions."
+msgstr ""
+"rpcpassword=<password> moet ingesteld in het configuratie bestand:\n"
+"%s\n"
+"Als het bestand nog niet bestaat, maak het dan aan met enkel-leesbaar-door-eigenaar rechten."
+
+#: ../../../src/net.cpp:1616
 #, c-format
 msgid "Unable to bind to port %d on this computer.  Bitcoin is probably already running."
 msgstr "Kan niet binden met poort %d op deze computer. Bitcoin draait vermoedelijk reeds."
 
-#: ../../../src/ui.cpp:202
+#: ../../../src/util.cpp:1008
+msgid "Warning: Please check that your computer's date and time are correct.  If your clock is wrong Bitcoin will not work properly."
+msgstr "Waarschuwing: Controleer of uw computers datum en tijd correct ingesteld zijn. Als uw klok fout staat zal Bitcoin niet correct werken."
+
+#: ../../../src/util.cpp:1042
+msgid "beta"
+msgstr "beta"
+
+#: ../../../src/wallet.cpp:1073
+msgid "Error: Wallet locked, unable to create transaction  "
+msgstr "Fout: portefeuille is op slot, kan geen transactie aanmaken"
+
+#: ../../../src/wallet.cpp:1081
+#, c-format
+msgid "Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds  "
+msgstr "Fout: Deze transactie vergt een fooi van ten minste %s omwille van zijn bedrag, complexiteit, of gebruik van recent ontvangen fonden  "
+
+#: ../../../src/wallet.cpp:1083
+msgid "Error: Transaction creation failed  "
+msgstr "Fout: Aanmaken van transactie mislukt  "
+
+#: ../../../src/wallet.cpp:1088
+msgid "Sending..."
+msgstr "Versturen..."
+
+#: ../../../src/wallet.cpp:1092
+msgid "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."
+msgstr "Fout: De transactie is afgekeurd.  Dit kan gebeuren als bepaalde coins in je Portefeuille al zijn uitgegeven. Dit kan veroorzaakt worden doordat je een kopie van wallet.dat gebruikt hebt en enkel daar je uitgave geregistreerd is."
+
+#: ../../../src/wallet.cpp:1104
+msgid "Invalid amount"
+msgstr "Foutieve hoeveelheid"
+
+#: ../../../src/wallet.cpp:1106
+msgid "Insufficient funds"
+msgstr "Onvoldoende saldo"
+
+#: ../../../src/main.cpp:1398
+#: ../../../src/bak/main.cpp:1414
+msgid "Warning: Disk space is low  "
+msgstr "Waarschuwing: Weinig schijfruimte over  "
+
+#: ../../../src/ui.cpp:217
+#: ../../../src/bak/ui.cpp:216
 #, c-format
 msgid "This transaction is over the size limit.  You can still send it for a fee of %s, which goes to the nodes that process your transaction and helps to support the network.  Do you want to pay the fee?"
 msgstr "Deze transactie overschrijdt de limiet.  Om de transactie alsnog te verwerken kun je een fooi betalen van %s. Deze zal betaald worden aan de node die uw transactie verwerkt. Wil je doorgaan en deze fooi betalen?"
 
-#: ../../../src/ui.cpp:301
+#: ../../../src/ui.cpp:261
+#: ../../../src/ui.cpp:1247
+msgid "Enter the current passphrase to the wallet."
+msgstr "Geef het huidige wachtwoord voor de portefeuille."
+
+#: ../../../src/ui.cpp:262
+#: ../../../src/ui.cpp:1183
+#: ../../../src/ui.cpp:1200
+#: ../../../src/ui.cpp:1248
+#: ../../../src/ui.cpp:1272
+#: ../../../src/ui.cpp:1292
+msgid "Passphrase"
+msgstr "Wachtwoord"
+
+#: ../../../src/ui.cpp:268
+msgid "Please supply the current wallet decryption passphrase."
+msgstr "Geef het huidige wachtwoord voor de portefeille"
+
+#: ../../../src/ui.cpp:276
+#: ../../../src/ui.cpp:1257
+#: ../../../src/ui.cpp:1314
+msgid "The passphrase entered for the wallet decryption was incorrect."
+msgstr "Het wachtwoord voor het openen van de portefeulle is foutief."
+
+#: ../../../src/ui.cpp:353
+#: ../../../src/bak/ui.cpp:316
 msgid "Status"
 msgstr "Status"
 
-#: ../../../src/ui.cpp:302
+#: ../../../src/ui.cpp:354
+#: ../../../src/bak/ui.cpp:317
 msgid "Date"
 msgstr "Datum"
 
-#: ../../../src/ui.cpp:303
+#: ../../../src/ui.cpp:355
+#: ../../../src/bak/ui.cpp:318
 msgid "Description"
 msgstr "Beschrijving"
 
-#: ../../../src/ui.cpp:304
+#: ../../../src/ui.cpp:356
+#: ../../../src/bak/ui.cpp:319
 msgid "Debit"
 msgstr "Debet"
 
-#: ../../../src/ui.cpp:305
+#: ../../../src/ui.cpp:357
+#: ../../../src/bak/ui.cpp:320
 msgid "Credit"
 msgstr "Credit"
 
-#: ../../../src/ui.cpp:511
+#: ../../../src/ui.cpp:568
+#: ../../../src/bak/ui.cpp:526
 #, c-format
 msgid "Open for %d blocks"
 msgstr "Open gedurende %d blokken"
 
-#: ../../../src/ui.cpp:513
+#: ../../../src/ui.cpp:570
+#: ../../../src/bak/ui.cpp:528
 #, c-format
 msgid "Open until %s"
 msgstr "Open tot %s"
 
-#: ../../../src/ui.cpp:519
+#: ../../../src/ui.cpp:576
+#: ../../../src/bak/ui.cpp:534
 #, c-format
 msgid "%d/offline?"
 msgstr "%d/offline?"
 
-#: ../../../src/ui.cpp:521
+#: ../../../src/ui.cpp:578
+#: ../../../src/bak/ui.cpp:536
 #, c-format
 msgid "%d/unconfirmed"
 msgstr "%d/niet bevestigd"
 
-#: ../../../src/ui.cpp:523
+#: ../../../src/ui.cpp:580
+#: ../../../src/bak/ui.cpp:538
 #, c-format
 msgid "%d confirmations"
 msgstr "%d bevestigingen"
 
-#: ../../../src/ui.cpp:608
+#: ../../../src/ui.cpp:665
+#: ../../../src/bak/ui.cpp:623
 msgid "Generated"
 msgstr "Gegenereerd"
 
-#: ../../../src/ui.cpp:616
+#: ../../../src/ui.cpp:673
+#: ../../../src/bak/ui.cpp:631
 #, c-format
 msgid "Generated (%s matures in %d more blocks)"
 msgstr "Gegenereerd (%s wordt volwassen over %d blokken)"
 
-#: ../../../src/ui.cpp:620
+#: ../../../src/ui.cpp:677
+#: ../../../src/bak/ui.cpp:635
 msgid "Generated - Warning: This block was not received by any other nodes and will probably not be accepted!"
 msgstr "Gegenereerd - Waarschuwing: Dit blok is niet ontvangen door andere nodes en zal waarschijnlijk niet geaccepteerd worden!"
 
-#: ../../../src/ui.cpp:624
+#: ../../../src/ui.cpp:681
+#: ../../../src/bak/ui.cpp:639
 msgid "Generated (not accepted)"
 msgstr "Gegenereerd (niet geaccepteerd)"
 
-#: ../../../src/ui.cpp:634
+#: ../../../src/ui.cpp:691
+#: ../../../src/bak/ui.cpp:649
 msgid "From: "
 msgstr "Van: "
 
-#: ../../../src/ui.cpp:658
+#: ../../../src/ui.cpp:715
+#: ../../../src/bak/ui.cpp:673
 msgid "Received with: "
-msgstr "Ontvangen op: "
+msgstr "Ontvangen met: "
 
-#: ../../../src/ui.cpp:704
+#: ../../../src/ui.cpp:760
+#: ../../../src/bak/ui.cpp:719
 msgid "Payment to yourself"
 msgstr "Betaling aan uzelf"
 
-#: ../../../src/ui.cpp:738
+#: ../../../src/ui.cpp:794
+#: ../../../src/bak/ui.cpp:753
 msgid "To: "
 msgstr "Naar: "
 
-#: ../../../src/ui.cpp:1053
+#: ../../../src/ui.cpp:1109
+#: ../../../src/bak/ui.cpp:1068
 msgid "    Generating"
 msgstr "    Genereren..."
 
-#: ../../../src/ui.cpp:1055
+#: ../../../src/ui.cpp:1111
+#: ../../../src/bak/ui.cpp:1070
 msgid "(not connected)"
 msgstr "(niet verbonden)"
 
-#: ../../../src/ui.cpp:1058
+#: ../../../src/ui.cpp:1114
+#: ../../../src/bak/ui.cpp:1073
 #, c-format
 msgid "     %d connections     %d blocks     %d transactions"
 msgstr "     %d verbindingen     %d blokken     %d transacties"
 
-#: ../../../src/ui.cpp:1163
-#: ../../../src/ui.cpp:2527
+#: ../../../src/ui.cpp:1171
+msgid "Wallet already encrypted."
+msgstr "Portefeuille reeds versleuteld."
+
+#: ../../../src/ui.cpp:1182
+msgid ""
+"Enter the new passphrase to the wallet.\n"
+"Please use a passphrase of 10 or more random characters, or eight or more words."
+msgstr ""
+"Geef het nieuwe wachtwoord voor de portefeuille.\n"
+"Gebruik een wachtwoord van 10 of meer willekeurige characters, of 8 of meer woorden."
+
+#: ../../../src/ui.cpp:1189
+#: ../../../src/ui.cpp:1280
+msgid "Error: The supplied passphrase was too short."
+msgstr "Fout: het wachtwoord is kort."
+
+#: ../../../src/ui.cpp:1193
+msgid ""
+"WARNING: If you encrypt your wallet and lose your passphrase, you will LOSE ALL OF YOUR BITCOINS!\n"
+"Are you sure you wish to encrypt your wallet?"
+msgstr ""
+"WAARSCHUWING: Indien u uw portefeuille versleutelt en het wachtwoord verliest, zal u AL UW BITCOINS VERLIEZEN!\n"
+"Bent u zeker dat u de portfeuille wenst te versleutelen?"
+
+#: ../../../src/ui.cpp:1199
+msgid "Please re-enter your new wallet passphrase."
+msgstr "Voer uw portefeuille-wachtwoord opnieuw in."
+
+#: ../../../src/ui.cpp:1208
+#: ../../../src/ui.cpp:1302
+msgid "Error: the supplied passphrases didn't match."
+msgstr "Fout: de ingevoerde wachtwoorden komen niet overeen."
+
+#: ../../../src/ui.cpp:1218
+msgid "Wallet encryption failed."
+msgstr "Versleutelen van de portefeuille mislukt."
+
+#: ../../../src/ui.cpp:1225
+msgid ""
+"Wallet Encrypted.\n"
+"Remember that encrypting your wallet cannot fully protect your bitcoins from being stolen by malware infecting your computer."
+msgstr ""
+"Portefeuille versleuteld.\n"
+"Denk eraan dat uw portefeuille versleutelen geen volledige bescherming biedt tegen malware die uw computer zou geinfecteerd hebben."
+
+#: ../../../src/ui.cpp:1236
+msgid "Wallet is unencrypted, please encrypt it first."
+msgstr "Portefeuille is onversleuteld. Versleutel ze eerst."
+
+#: ../../../src/ui.cpp:1271
+msgid "Enter the new passphrase for the wallet."
+msgstr "Voer nieuw wachtwoord voor de portefeuille in."
+
+#: ../../../src/ui.cpp:1291
+msgid "Re-enter the new passphrase for the wallet."
+msgstr "Voer nieuw wachtwoord voor de portefeuille opnieuw in."
+
+#: ../../../src/ui.cpp:1323
+msgid "Wallet Passphrase Changed."
+msgstr "Portefeuille-wachtwoord gewijzigd."
+
+#: ../../../src/ui.cpp:1379
+#: ../../../src/ui.cpp:2825
+#: ../../../src/bak/ui.cpp:1178
+#: ../../../src/bak/ui.cpp:2571
 msgid "New Receiving Address"
 msgstr "Nieuw Ontvangstadres"
 
-#: ../../../src/ui.cpp:1164
-#: ../../../src/ui.cpp:2528
+#: ../../../src/ui.cpp:1380
+#: ../../../src/ui.cpp:2826
+#: ../../../src/bak/ui.cpp:1179
+#: ../../../src/bak/ui.cpp:2572
 msgid ""
 "You should use a new address for each payment you receive.\n"
 "\n"
@@ -131,248 +503,299 @@ msgstr ""
 "\n"
 "Label"
 
-#: ../../../src/ui.cpp:1233
+#: ../../../src/ui.cpp:1464
+#: ../../../src/bak/ui.cpp:1251
 msgid "<b>Status:</b> "
 msgstr "<b>Status:</b> "
 
-#: ../../../src/ui.cpp:1238
+#: ../../../src/ui.cpp:1469
+#: ../../../src/bak/ui.cpp:1256
 msgid ", has not been successfully broadcast yet"
 msgstr ", is nog niet succesvol verstuurd naar het netwerk"
 
-#: ../../../src/ui.cpp:1240
+#: ../../../src/ui.cpp:1471
+#: ../../../src/bak/ui.cpp:1258
 #, c-format
 msgid ", broadcast through %d node"
 msgstr ", verstuurd via %d node"
 
-#: ../../../src/ui.cpp:1242
+#: ../../../src/ui.cpp:1473
+#: ../../../src/bak/ui.cpp:1260
 #, c-format
 msgid ", broadcast through %d nodes"
 msgstr ", verstuurd via %d nodes"
 
-#: ../../../src/ui.cpp:1246
+#: ../../../src/ui.cpp:1477
+#: ../../../src/bak/ui.cpp:1264
 msgid "<b>Date:</b> "
 msgstr "<b>Datum:</b> "
 
-#: ../../../src/ui.cpp:1254
+#: ../../../src/ui.cpp:1485
+#: ../../../src/bak/ui.cpp:1272
 msgid "<b>Source:</b> Generated<br>"
 msgstr "<b>Bron:</b> Gegenereerd<br>"
 
-#: ../../../src/ui.cpp:1260
-#: ../../../src/ui.cpp:1278
+#: ../../../src/ui.cpp:1491
+#: ../../../src/ui.cpp:1508
+#: ../../../src/bak/ui.cpp:1278
+#: ../../../src/bak/ui.cpp:1296
 msgid "<b>From:</b> "
 msgstr "<b>Van:</b> "
 
-#: ../../../src/ui.cpp:1278
+#: ../../../src/ui.cpp:1508
+#: ../../../src/bak/ui.cpp:1296
 msgid "unknown"
 msgstr "onbekend"
 
-#: ../../../src/ui.cpp:1279
-#: ../../../src/ui.cpp:1303
-#: ../../../src/ui.cpp:1362
+#: ../../../src/ui.cpp:1509
+#: ../../../src/ui.cpp:1533
+#: ../../../src/ui.cpp:1592
+#: ../../../src/bak/ui.cpp:1297
+#: ../../../src/bak/ui.cpp:1321
+#: ../../../src/bak/ui.cpp:1380
 msgid "<b>To:</b> "
 msgstr "<b>Naar:</b> "
 
-#: ../../../src/ui.cpp:1282
+#: ../../../src/ui.cpp:1512
+#: ../../../src/bak/ui.cpp:1300
 msgid " (yours, label: "
 msgstr " (van jou, label: "
 
-#: ../../../src/ui.cpp:1284
+#: ../../../src/ui.cpp:1514
+#: ../../../src/bak/ui.cpp:1302
 msgid " (yours)"
 msgstr " (van jou)"
 
-#: ../../../src/ui.cpp:1321
-#: ../../../src/ui.cpp:1333
-#: ../../../src/ui.cpp:1379
-#: ../../../src/ui.cpp:1396
+#: ../../../src/ui.cpp:1551
+#: ../../../src/ui.cpp:1563
+#: ../../../src/ui.cpp:1609
+#: ../../../src/ui.cpp:1626
+#: ../../../src/bak/ui.cpp:1339
+#: ../../../src/bak/ui.cpp:1351
+#: ../../../src/bak/ui.cpp:1397
+#: ../../../src/bak/ui.cpp:1414
 msgid "<b>Credit:</b> "
 msgstr "<b>Credit:</b>"
 
-#: ../../../src/ui.cpp:1323
+#: ../../../src/ui.cpp:1553
+#: ../../../src/bak/ui.cpp:1341
 #, c-format
 msgid "(%s matures in %d more blocks)"
 msgstr "(%s wordt volwassen over %d blokken)"
 
-#: ../../../src/ui.cpp:1325
+#: ../../../src/ui.cpp:1555
+#: ../../../src/bak/ui.cpp:1343
 msgid "(not accepted)"
 msgstr "(niet geaccepteerd)"
 
-#: ../../../src/ui.cpp:1370
-#: ../../../src/ui.cpp:1378
-#: ../../../src/ui.cpp:1393
+#: ../../../src/ui.cpp:1600
+#: ../../../src/ui.cpp:1608
+#: ../../../src/ui.cpp:1623
+#: ../../../src/bak/ui.cpp:1388
+#: ../../../src/bak/ui.cpp:1396
+#: ../../../src/bak/ui.cpp:1411
 msgid "<b>Debit:</b> "
 msgstr "<b>Debet:</b>"
 
-#: ../../../src/ui.cpp:1384
+#: ../../../src/ui.cpp:1614
+#: ../../../src/bak/ui.cpp:1402
 msgid "<b>Transaction fee:</b> "
 msgstr "<b>Transactiefooi:</b> "
 
-#: ../../../src/ui.cpp:1400
+#: ../../../src/ui.cpp:1630
+#: ../../../src/bak/ui.cpp:1418
 msgid "<b>Net amount:</b> "
 msgstr "<b>Nettobedrag:</b> "
 
-#: ../../../src/ui.cpp:1407
+#: ../../../src/ui.cpp:1637
+#: ../../../src/bak/ui.cpp:1425
 msgid "Message:"
 msgstr "Mededeling:"
 
-#: ../../../src/ui.cpp:1409
+#: ../../../src/ui.cpp:1639
+#: ../../../src/bak/ui.cpp:1427
 msgid "Comment:"
 msgstr "Commentaar:"
 
-#: ../../../src/ui.cpp:1412
+#: ../../../src/ui.cpp:1642
+#: ../../../src/bak/ui.cpp:1430
 msgid "Generated coins must wait 120 blocks before they can be spent.  When you generated this block, it was broadcast to the network to be added to the block chain.  If it fails to get into the chain, it will change to \"not accepted\" and not be spendable.  This may occasionally happen if another node generates a block within a few seconds of yours."
 msgstr "Gegenereerde coins mogen pas na een wachttijd van 120 blokken uitgegeven worden. Op het moment dat dit blok gegenereerd werd, is het naar het netwerk verzonden om aan de blokkenreeks toegevoegd te worden. Als het niet succesvol in de blokkenreeks opgenomen kan worden verandert de status in \"niet geaccepteerd\" en kan het niet uitegegeven worden. Dit kan soms gebeuren als een andere node op ongeveer hetzelfde moment een blok genereert."
 
-#: ../../../src/ui.cpp:1592
+#: ../../../src/ui.cpp:1826
+#: ../../../src/bak/ui.cpp:1610
 msgid "Cannot write autostart/bitcoin.desktop file"
 msgstr "Kan niet schrijven naar het bestand autostart/bitcoin.desktop"
 
-#: ../../../src/ui.cpp:1628
+#: ../../../src/ui.cpp:1862
+#: ../../../src/bak/ui.cpp:1646
 msgid "Main"
 msgstr "Algemeen"
 
-#: ../../../src/ui.cpp:1636
+#: ../../../src/ui.cpp:1872
+#: ../../../src/bak/ui.cpp:1656
 msgid "&Start Bitcoin on window system startup"
 msgstr "&Start Bitcoin wanneer het systeem opstart"
 
-#: ../../../src/ui.cpp:1643
+#: ../../../src/ui.cpp:1879
+#: ../../../src/bak/ui.cpp:1663
 msgid "&Minimize on close"
 msgstr "&Minimaliseer bij sluiten van het venster"
 
-#: ../../../src/ui.cpp:1785
+#: ../../../src/ui.cpp:2021
+#: ../../../src/bak/ui.cpp:1805
 #, c-format
 msgid "version %s"
 msgstr "versie %s"
 
-#: ../../../src/ui.cpp:1897
+#: ../../../src/ui.cpp:2144
+#: ../../../src/bak/ui.cpp:1928
 msgid "Error in amount  "
 msgstr "Fout in hoeveelheid  "
 
-#: ../../../src/ui.cpp:1897
-#: ../../../src/ui.cpp:1902
-#: ../../../src/ui.cpp:1907
-#: ../../../src/ui.cpp:1942
-#: ../../../src/uibase.cpp:55
+#: ../../../src/ui.cpp:2144
+#: ../../../src/ui.cpp:2149
+#: ../../../src/ui.cpp:2154
+#: ../../../src/ui.cpp:2207
+#: ../../../src/uibase.cpp:61
+#: ../../../src/bak/ui.cpp:1928
+#: ../../../src/bak/ui.cpp:1933
+#: ../../../src/bak/ui.cpp:1938
+#: ../../../src/bak/ui.cpp:1973
 msgid "Send Coins"
 msgstr "Verstuur coins"
 
-#: ../../../src/ui.cpp:1902
+#: ../../../src/ui.cpp:2149
+#: ../../../src/bak/ui.cpp:1933
 msgid "Amount exceeds your balance  "
 msgstr "Hoeveelheid overschrijdt uw huidige balans  "
 
-#: ../../../src/ui.cpp:1907
+#: ../../../src/ui.cpp:2154
+#: ../../../src/bak/ui.cpp:1938
 msgid "Total exceeds your balance when the "
 msgstr "Totaal overschrijdt uw huidige balans wanneer de "
 
-#: ../../../src/ui.cpp:1907
+#: ../../../src/ui.cpp:2154
+#: ../../../src/bak/ui.cpp:1938
 msgid " transaction fee is included  "
 msgstr " transactiefooi is meegerekend  "
 
-#: ../../../src/ui.cpp:1925
+#: ../../../src/ui.cpp:2181
+#: ../../../src/bak/ui.cpp:1956
 msgid "Payment sent  "
 msgstr "Betaling verzonden  "
 
-#: ../../../src/ui.cpp:1925
-#: ../../../src/ui.cpp:1930
-#: ../../../src/ui.cpp:2074
-#: ../../../src/ui.cpp:2227
-#: ../../../src/main.cpp:3999
-msgid "Sending..."
-msgstr "Versturen..."
-
-#: ../../../src/ui.cpp:1942
+#: ../../../src/ui.cpp:2207
+#: ../../../src/bak/ui.cpp:1973
 msgid "Invalid address  "
 msgstr "Foutief adres  "
 
-#: ../../../src/ui.cpp:1995
+#: ../../../src/ui.cpp:2262
+#: ../../../src/bak/ui.cpp:2028
 #, c-format
 msgid "Sending %s to %s"
 msgstr "%s versturen naar %s"
 
-#: ../../../src/ui.cpp:2068
-#: ../../../src/ui.cpp:2101
+#: ../../../src/ui.cpp:2335
+#: ../../../src/ui.cpp:2368
+#: ../../../src/bak/ui.cpp:2101
+#: ../../../src/bak/ui.cpp:2134
 msgid "CANCELLED"
 msgstr "GEANNULEERD"
 
-#: ../../../src/ui.cpp:2072
+#: ../../../src/ui.cpp:2339
+#: ../../../src/bak/ui.cpp:2105
 msgid "Cancelled"
 msgstr "Geannuleerd"
 
-#: ../../../src/ui.cpp:2074
+#: ../../../src/ui.cpp:2341
+#: ../../../src/bak/ui.cpp:2107
 msgid "Transfer cancelled  "
 msgstr "Transactie geannuleerd  "
 
-#: ../../../src/ui.cpp:2127
+#: ../../../src/ui.cpp:2394
+#: ../../../src/bak/ui.cpp:2160
 msgid "Error: "
 msgstr "Fout: "
 
-#: ../../../src/ui.cpp:2141
-#: ../../../src/ui.cpp:2212
-#: ../../../src/main.cpp:4018
-msgid "Insufficient funds"
-msgstr "Onvoldoende saldo"
-
-#: ../../../src/ui.cpp:2146
+#: ../../../src/ui.cpp:2413
+#: ../../../src/bak/ui.cpp:2179
 msgid "Connecting..."
 msgstr "Verbinden..."
 
-#: ../../../src/ui.cpp:2151
+#: ../../../src/ui.cpp:2418
+#: ../../../src/bak/ui.cpp:2184
 msgid "Unable to connect"
 msgstr "Kan niet verbinden"
 
-#: ../../../src/ui.cpp:2156
+#: ../../../src/ui.cpp:2423
+#: ../../../src/bak/ui.cpp:2189
 msgid "Requesting public key..."
 msgstr "Aanvragen van publieke sleutel..."
 
-#: ../../../src/ui.cpp:2168
+#: ../../../src/ui.cpp:2435
+#: ../../../src/bak/ui.cpp:2201
 msgid "Received public key..."
 msgstr "Publieke sleutel ontvangen..."
 
-#: ../../../src/ui.cpp:2182
+#: ../../../src/ui.cpp:2449
+#: ../../../src/bak/ui.cpp:2215
 msgid "Recipient is not accepting transactions sent by IP address"
 msgstr "Ontvanger aanvaardt geen transacties via IP adres"
 
-#: ../../../src/ui.cpp:2184
+#: ../../../src/ui.cpp:2451
+#: ../../../src/bak/ui.cpp:2217
 msgid "Transfer was not accepted"
 msgstr "Transactie niet geaccepteerd"
 
-#: ../../../src/ui.cpp:2193
+#: ../../../src/ui.cpp:2460
+#: ../../../src/bak/ui.cpp:2226
 msgid "Invalid response received"
 msgstr "Foutief antwoord ontvangen"
 
-#: ../../../src/ui.cpp:2208
+#: ../../../src/ui.cpp:2473
+#: ../../../src/bak/ui.cpp:2241
 msgid "Creating transaction..."
 msgstr "Transactie aanmaken..."
 
-#: ../../../src/ui.cpp:2220
+#: ../../../src/ui.cpp:2496
+#: ../../../src/bak/ui.cpp:2253
 #, c-format
 msgid "This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds"
 msgstr "Deze transactie vergt een fooi van ten minste %s omwille van zijn bedrag, complexiteit, of gebruik van recent ontvangen fonden"
 
-#: ../../../src/ui.cpp:2222
+#: ../../../src/ui.cpp:2498
+#: ../../../src/bak/ui.cpp:2255
 msgid "Transaction creation failed"
 msgstr "Aanmaken van transactie mislukt"
 
-#: ../../../src/ui.cpp:2229
+#: ../../../src/ui.cpp:2508
+#: ../../../src/bak/ui.cpp:2262
 msgid "Transaction aborted"
 msgstr "Transactie geannuleerd"
 
-#: ../../../src/ui.cpp:2237
+#: ../../../src/ui.cpp:2516
+#: ../../../src/bak/ui.cpp:2270
 msgid "Lost connection, transaction cancelled"
 msgstr "Verbinding verloren, transactie geannuleerd"
 
-#: ../../../src/ui.cpp:2253
+#: ../../../src/ui.cpp:2532
+#: ../../../src/bak/ui.cpp:2286
 msgid "Sending payment..."
 msgstr "Betaling versturen..."
 
-#: ../../../src/ui.cpp:2259
+#: ../../../src/ui.cpp:2544
+#: ../../../src/bak/ui.cpp:2292
 msgid "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."
 msgstr "Fout: De transactie is afgekeurd.  Dit kan gebeuren als bepaalde coins in je Portefeuille al zijn uitgegeven. Dit kan veroorzaakt worden doordat je een kopie van wallet.dat gebruikt hebt en enkel daar je uitgave geregistreerd is."
 
-#: ../../../src/ui.cpp:2268
+#: ../../../src/ui.cpp:2553
+#: ../../../src/bak/ui.cpp:2301
 msgid "Waiting for confirmation..."
 msgstr "Wachten op bevestiging..."
 
-#: ../../../src/ui.cpp:2286
+#: ../../../src/ui.cpp:2570
+#: ../../../src/bak/ui.cpp:2319
 msgid ""
 "The payment was sent, but the recipient was unable to verify it.\n"
 "The transaction is recorded and will credit to the recipient,\n"
@@ -382,149 +805,112 @@ msgstr ""
 "De transactie is opgenomen en wordt uitbetaald aan de ontvanger,\n"
 "maar het mededelings-veld blijft blanco."
 
-#: ../../../src/ui.cpp:2295
+#: ../../../src/ui.cpp:2579
+#: ../../../src/bak/ui.cpp:2328
 msgid "Payment was sent, but an invalid response was received"
 msgstr "Betaling is verstuurd, maar een foutief antword is ontvangen."
 
-#: ../../../src/ui.cpp:2301
+#: ../../../src/ui.cpp:2585
+#: ../../../src/bak/ui.cpp:2334
 msgid "Payment completed"
 msgstr "Betaling voltooid"
 
-#: ../../../src/ui.cpp:2332
-#: ../../../src/ui.cpp:2478
-#: ../../../src/ui.cpp:2515
+#: ../../../src/ui.cpp:2627
+#: ../../../src/ui.cpp:2773
+#: ../../../src/ui.cpp:2813
+#: ../../../src/bak/ui.cpp:2376
+#: ../../../src/bak/ui.cpp:2522
+#: ../../../src/bak/ui.cpp:2559
 msgid "Name"
 msgstr "Naam"
 
-#: ../../../src/ui.cpp:2333
-#: ../../../src/ui.cpp:2478
-#: ../../../src/ui.cpp:2515
+#: ../../../src/ui.cpp:2628
+#: ../../../src/ui.cpp:2773
+#: ../../../src/ui.cpp:2813
+#: ../../../src/bak/ui.cpp:2377
+#: ../../../src/bak/ui.cpp:2522
+#: ../../../src/bak/ui.cpp:2559
 msgid "Address"
 msgstr "Adres"
 
-#: ../../../src/ui.cpp:2335
-#: ../../../src/ui.cpp:2490
+#: ../../../src/ui.cpp:2630
+#: ../../../src/ui.cpp:2785
+#: ../../../src/bak/ui.cpp:2379
+#: ../../../src/bak/ui.cpp:2534
 msgid "Label"
 msgstr "Label"
 
-#: ../../../src/ui.cpp:2336
-#: ../../../src/uibase.cpp:837
+#: ../../../src/ui.cpp:2631
+#: ../../../src/uibase.cpp:847
+#: ../../../src/bak/ui.cpp:2380
 msgid "Bitcoin Address"
 msgstr "Bitcoin-adres"
 
-#: ../../../src/ui.cpp:2460
+#: ../../../src/ui.cpp:2755
+#: ../../../src/bak/ui.cpp:2504
 msgid "This is one of your own addresses for receiving payments and cannot be entered in the address book.  "
 msgstr "Dit is een van uw eigen adressen voor het ontvangen van betalingen, en kan niet worden toegevoegd aan uw adresboek.  "
 
-#: ../../../src/ui.cpp:2478
-#: ../../../src/ui.cpp:2484
+#: ../../../src/ui.cpp:2773
+#: ../../../src/ui.cpp:2779
+#: ../../../src/bak/ui.cpp:2522
+#: ../../../src/bak/ui.cpp:2528
 msgid "Edit Address"
 msgstr "Bewerk adres"
 
-#: ../../../src/ui.cpp:2490
+#: ../../../src/ui.cpp:2785
+#: ../../../src/bak/ui.cpp:2534
 msgid "Edit Address Label"
 msgstr "Bewerk adreslabel"
 
-#: ../../../src/ui.cpp:2515
-#: ../../../src/ui.cpp:2521
+#: ../../../src/ui.cpp:2813
+#: ../../../src/ui.cpp:2819
+#: ../../../src/bak/ui.cpp:2559
+#: ../../../src/bak/ui.cpp:2565
 msgid "Add Address"
 msgstr "Adres toevoegen"
 
-#: ../../../src/ui.cpp:2598
+#: ../../../src/ui.cpp:2906
+#: ../../../src/bak/ui.cpp:2642
 msgid "Bitcoin"
 msgstr "Bitcoin"
 
-#: ../../../src/ui.cpp:2600
+#: ../../../src/ui.cpp:2908
+#: ../../../src/bak/ui.cpp:2644
 msgid "Bitcoin - Generating"
 msgstr "Bitcoin - Genereren..."
 
-#: ../../../src/ui.cpp:2602
+#: ../../../src/ui.cpp:2910
+#: ../../../src/bak/ui.cpp:2646
 msgid "Bitcoin - (not connected)"
 msgstr "Bitcoin - (niet verbonden)"
 
-#: ../../../src/ui.cpp:2681
+#: ../../../src/ui.cpp:2989
+#: ../../../src/bak/ui.cpp:2725
 msgid "&Open Bitcoin"
 msgstr "&Open Bitcoin"
 
-#: ../../../src/ui.cpp:2682
+#: ../../../src/ui.cpp:2990
+#: ../../../src/bak/ui.cpp:2726
 msgid "&Send Bitcoins"
 msgstr "&Verstuur Bitcoins"
 
-#: ../../../src/ui.cpp:2683
+#: ../../../src/ui.cpp:2991
+#: ../../../src/bak/ui.cpp:2727
 msgid "O&ptions..."
 msgstr "O&pties"
 
-#: ../../../src/ui.cpp:2686
+#: ../../../src/ui.cpp:2994
 #: ../../../src/uibase.cpp:25
+#: ../../../src/bak/ui.cpp:2730
 msgid "E&xit"
 msgstr "A&fsluiten"
 
-#: ../../../src/ui.cpp:2902
+#: ../../../src/ui.cpp:3220
+#: ../../../src/bak/ui.cpp:2956
 msgid "Program has crashed and will terminate.  "
 msgstr "Het programma is gecrasht en wordt afgesloten.  "
 
-#: ../../../src/main.cpp:1868
-msgid "Warning: Disk space is low  "
-msgstr "Waarschuwing: Weinig schijfruimte over  "
-
-#: ../../../src/main.cpp:3992
-#, c-format
-msgid "Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds  "
-msgstr "Fout: Deze transactie vergt een fooi van ten minste %s omwille van zijn bedrag, complexiteit, of gebruik van recent ontvangen fonden  "
-
-#: ../../../src/main.cpp:3994
-msgid "Error: Transaction creation failed  "
-msgstr "Fout: Aanmaken van transactie mislukt  "
-
-#: ../../../src/main.cpp:4003
-msgid "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."
-msgstr "Fout: De transactie is afgekeurd.  Dit kan gebeuren als bepaalde coins in je Portefeuille al zijn uitgegeven. Dit kan veroorzaakt worden doordat je een kopie van wallet.dat gebruikt hebt en enkel daar je uitgave geregistreerd is."
-
-#: ../../../src/main.cpp:4016
-msgid "Invalid amount"
-msgstr "Foutieve hoeveelheid"
-
-#: ../../../src/main.cpp:4023
-msgid "Invalid bitcoin address"
-msgstr "Foutief bitcoin-adres"
-
-#: ../../../src/rpc.cpp:1800
-#: ../../../src/rpc.cpp:1802
-#, c-format
-msgid "To use the %s option"
-msgstr "Om de %s optie te gebruiken"
-
-#: ../../../src/rpc.cpp:1804
-#, c-format
-msgid ""
-"Warning: %s, you must set rpcpassword=<password>\n"
-"in the configuration file: %s\n"
-"If the file does not exist, create it with owner-readable-only file permissions.\n"
-msgstr ""
-"Waarschuwing: %s, rpcpassword=<password> moet ingesteld zijn\n"
-"in het configuratie bestand: %s\n"
-"Als het bestand nog niet bestaat, maak het dan aan met enkel-leesbaar-door-eigenaar rechten.\n"
-
-
-#: ../../../src/rpc.cpp:1972
-#, c-format
-msgid ""
-"You must set rpcpassword=<password> in the configuration file:\n"
-"%s\n"
-"If the file does not exist, create it with owner-readable-only file permissions."
-msgstr ""
-"rpcpassword=<password> moet ingesteld in het configuratie bestand:\n"
-"%s\n"
-"Als het bestand nog niet bestaat, maak het dan aan met enkel-leesbaar-door-eigenaar rechten."
-
-#: ../../../src/util.cpp:865
-msgid "Warning: Please check that your computer's date and time are correct.  If your clock is wrong Bitcoin will not work properly."
-msgstr "Waarschuwing: Controleer of uw computers datum en tijd correct ingesteld zijn. Als uw klok fout staat zal Bitcoin niet correct werken."
-
-#: ../../../src/util.cpp:898
-msgid "beta"
-msgstr "beta"
-
 #: ../../../src/uibase.cpp:28
 msgid "&File"
 msgstr "&Bestand"
@@ -533,152 +919,160 @@ msgstr "&Bestand"
 msgid "&Your Receiving Addresses..."
 msgstr "&Uw ontvangstadressen..."
 
-#: ../../../src/uibase.cpp:36
+#: ../../../src/uibase.cpp:35
+msgid "&Encrypt Wallet..."
+msgstr "&Versleutel portefeuille..."
+
+#: ../../../src/uibase.cpp:38
+msgid "&Change Wallet Encryption Passphrase..."
+msgstr "&Wijzig portefeuille-wachtwoord..."
+
+#: ../../../src/uibase.cpp:42
 msgid "&Options..."
 msgstr "&Opties..."
 
-#: ../../../src/uibase.cpp:39
+#: ../../../src/uibase.cpp:45
 msgid "&Settings"
 msgstr "&Eigenschappen"
 
-#: ../../../src/uibase.cpp:43
+#: ../../../src/uibase.cpp:49
 msgid "&About..."
 msgstr "&Over..."
 
-#: ../../../src/uibase.cpp:46
+#: ../../../src/uibase.cpp:52
 msgid "&Help"
 msgstr "&Help"
 
-#: ../../../src/uibase.cpp:56
+#: ../../../src/uibase.cpp:62
 msgid "Address Book"
 msgstr "Adresboek"
 
-#: ../../../src/uibase.cpp:69
+#: ../../../src/uibase.cpp:75
 msgid "Your Bitcoin Address:"
 msgstr "Uw bitcoin-adres:"
 
-#: ../../../src/uibase.cpp:76
+#: ../../../src/uibase.cpp:82
 msgid " &New... "
 msgstr " &Nieuw... "
 
-#: ../../../src/uibase.cpp:79
-#: ../../../src/uibase.cpp:780
-#: ../../../src/uibase.cpp:883
+#: ../../../src/uibase.cpp:85
+#: ../../../src/uibase.cpp:790
+#: ../../../src/uibase.cpp:893
 msgid " &Copy to Clipboard "
 msgstr " &Kopieer naar plakbord "
 
-#: ../../../src/uibase.cpp:93
+#: ../../../src/uibase.cpp:99
 msgid "Balance:"
 msgstr "Balans:"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " All"
 msgstr " Alles"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " Sent"
 msgstr " Verstuurd"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " Received"
 msgstr " Ontvangen"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " In Progress"
 msgstr " Wordt verwerkt"
 
-#: ../../../src/uibase.cpp:130
+#: ../../../src/uibase.cpp:136
 msgid "All Transactions"
 msgstr "Alle transacties"
 
-#: ../../../src/uibase.cpp:141
+#: ../../../src/uibase.cpp:147
 msgid "Sent/Received"
 msgstr "Verstuurd/Ontvangen"
 
-#: ../../../src/uibase.cpp:152
+#: ../../../src/uibase.cpp:158
 msgid "Sent"
 msgstr "Verstuurd"
 
-#: ../../../src/uibase.cpp:163
+#: ../../../src/uibase.cpp:169
 msgid "Received"
 msgstr "Ontvangen"
 
-#: ../../../src/uibase.cpp:302
-#: ../../../src/uibase.cpp:443
-#: ../../../src/uibase.cpp:542
-#: ../../../src/uibase.cpp:722
-#: ../../../src/uibase.cpp:783
-#: ../../../src/uibase.cpp:892
-#: ../../../src/uibase.cpp:981
+#: ../../../src/uibase.cpp:312
+#: ../../../src/uibase.cpp:453
+#: ../../../src/uibase.cpp:552
+#: ../../../src/uibase.cpp:732
+#: ../../../src/uibase.cpp:793
+#: ../../../src/uibase.cpp:902
+#: ../../../src/uibase.cpp:991
 msgid "OK"
 msgstr "OK"
 
-#: ../../../src/uibase.cpp:345
+#: ../../../src/uibase.cpp:355
 msgid "&Start Bitcoin on system startup"
 msgstr "&Start Bitcoin wanneer het systeem opstart"
 
-#: ../../../src/uibase.cpp:348
+#: ../../../src/uibase.cpp:358
 msgid "&Minimize to the tray instead of the taskbar"
 msgstr "&Minimaliseer tot systeemvak in plaats van de taakbalk"
 
-#: ../../../src/uibase.cpp:351
+#: ../../../src/uibase.cpp:361
 msgid "Map port using &UPnP"
 msgstr "Portmapping via &UPnP"
 
-#: ../../../src/uibase.cpp:354
+#: ../../../src/uibase.cpp:364
 msgid "M&inimize to the tray on close"
 msgstr "M&inimaliseer tot taakbalk bij sluiten"
 
-#: ../../../src/uibase.cpp:360
-msgid "&Connect through socks4 proxy: "
-msgstr "&Verbind via socks4 proxy: "
+#: ../../../src/uibase.cpp:370
+msgid "&Connect through socks4 proxy (requires restart to apply): "
+msgstr "&Verbind via socks4 proxy (vereist herstart):"
 
-#: ../../../src/uibase.cpp:371
+#: ../../../src/uibase.cpp:381
 msgid "Proxy &IP:"
 msgstr "Proxy &IP:"
 
-#: ../../../src/uibase.cpp:379
+#: ../../../src/uibase.cpp:389
 msgid " &Port:"
 msgstr " &Poort:"
 
-#: ../../../src/uibase.cpp:392
+#: ../../../src/uibase.cpp:402
 msgid "Optional transaction fee per KB that helps make sure your transactions are processed quickly.  Most transactions are 1KB.  Fee 0.01 recommended."
 msgstr "Optionele transactiefooi per KB die helpt ervoor zorgen dat uw transacties snel verwerkt worden. De meeste transacties zijn 1KB. Fooi 0.01 is aangeraden."
 
-#: ../../../src/uibase.cpp:399
+#: ../../../src/uibase.cpp:409
 msgid "Pay transaction fee:"
 msgstr "Transactiefooi:"
 
-#: ../../../src/uibase.cpp:420
+#: ../../../src/uibase.cpp:430
 msgid "// [don't translate] Test panel 2 for future expansion"
 msgstr ""
 
-#: ../../../src/uibase.cpp:424
+#: ../../../src/uibase.cpp:434
 msgid "// [don't translate] Let's not start multiple pages until the first page is filled up"
 msgstr ""
 
-#: ../../../src/uibase.cpp:446
-#: ../../../src/uibase.cpp:668
-#: ../../../src/uibase.cpp:727
-#: ../../../src/uibase.cpp:786
-#: ../../../src/uibase.cpp:895
-#: ../../../src/uibase.cpp:984
+#: ../../../src/uibase.cpp:456
+#: ../../../src/uibase.cpp:678
+#: ../../../src/uibase.cpp:737
+#: ../../../src/uibase.cpp:796
+#: ../../../src/uibase.cpp:905
+#: ../../../src/uibase.cpp:994
 msgid "Cancel"
 msgstr "Annuleren"
 
-#: ../../../src/uibase.cpp:449
+#: ../../../src/uibase.cpp:459
 msgid "&Apply"
 msgstr "&Toepassen"
 
-#: ../../../src/uibase.cpp:508
+#: ../../../src/uibase.cpp:518
 msgid "Bitcoin "
 msgstr "Bitcoin "
 
-#: ../../../src/uibase.cpp:514
+#: ../../../src/uibase.cpp:524
 msgid "version"
 msgstr "versie"
 
-#: ../../../src/uibase.cpp:525
+#: ../../../src/uibase.cpp:535
 msgid ""
 "Copyright (c) 2009-2011 Bitcoin Developers\n"
 "\n"
@@ -703,39 +1097,39 @@ msgstr ""
 "software geschreven door Eric Young (eay@cryptsoft.com)) en UPnP software geschreven\n"
 "door Thomas Bernard."
 
-#: ../../../src/uibase.cpp:581
+#: ../../../src/uibase.cpp:591
 msgid "Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
 msgstr "Voer een bitcoin-adres (bijvoorbeeld: 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
 
-#: ../../../src/uibase.cpp:595
+#: ../../../src/uibase.cpp:605
 msgid "Pay &To:"
 msgstr "Betaal &aan:"
 
-#: ../../../src/uibase.cpp:610
+#: ../../../src/uibase.cpp:620
 msgid "&Paste"
 msgstr "&Plakken"
 
-#: ../../../src/uibase.cpp:613
+#: ../../../src/uibase.cpp:623
 msgid " Address &Book..."
 msgstr " Adres&boek..."
 
-#: ../../../src/uibase.cpp:620
+#: ../../../src/uibase.cpp:630
 msgid "&Amount:"
 msgstr "&Hoeveelheid:"
 
-#: ../../../src/uibase.cpp:630
+#: ../../../src/uibase.cpp:640
 msgid "T&ransfer:"
 msgstr "O&verdracht:"
 
-#: ../../../src/uibase.cpp:636
+#: ../../../src/uibase.cpp:646
 msgid " Standard"
 msgstr " Standaard"
 
-#: ../../../src/uibase.cpp:663
+#: ../../../src/uibase.cpp:673
 msgid "&Send"
 msgstr "&Versturen"
 
-#: ../../../src/uibase.cpp:711
+#: ../../../src/uibase.cpp:721
 msgid ""
 "\n"
 "\n"
@@ -745,229 +1139,57 @@ msgstr ""
 "\n"
 "Verbinden..."
 
-#: ../../../src/uibase.cpp:761
+#: ../../../src/uibase.cpp:771
 msgid "These are your Bitcoin addresses for receiving payments.  You may want to give a different one to each sender so you can keep track of who is paying you.  The highlighted address is displayed in the main window."
 msgstr "Dit zijn je bitcoin-adressen voor het ontvangen van betalingen.  Het is een goed idee iedere afzender een ander adres te geven zodat je bij kunt houden wie je een betaling stuurt. Het geselecteerde adres is zichtbaar in het hoofdscherm."
 
-#: ../../../src/uibase.cpp:774
-#: ../../../src/uibase.cpp:886
+#: ../../../src/uibase.cpp:784
+#: ../../../src/uibase.cpp:896
 msgid "&Edit..."
 msgstr "&Bewerken..."
 
-#: ../../../src/uibase.cpp:777
-#: ../../../src/uibase.cpp:889
+#: ../../../src/uibase.cpp:787
+#: ../../../src/uibase.cpp:899
 msgid " &New Address... "
 msgstr " &Nieuw adres... "
 
-#: ../../../src/uibase.cpp:849
+#: ../../../src/uibase.cpp:859
 msgid "Sending"
 msgstr "Versturen..."
 
-#: ../../../src/uibase.cpp:857
+#: ../../../src/uibase.cpp:867
 msgid "These are your Bitcoin addresses for receiving payments.  You can give a different one to each sender to keep track of who is paying you.  The highlighted address will be displayed in the main window."
 msgstr "Dit zijn je bitcoin-adressen voor het ontvangen van betalingen.  Het is een goed idee iedere afzender een ander adres te geven zodat je bij kunt houden wie je een betaling stuurt. Het geselecteerde adres is zichtbaar in het hoofdscherm."
 
-#: ../../../src/uibase.cpp:870
+#: ../../../src/uibase.cpp:880
 msgid "Receiving"
 msgstr "Ontvangen..."
 
-#: ../../../src/uibase.cpp:880
+#: ../../../src/uibase.cpp:890
 msgid "&Delete"
 msgstr "&Verwijderen"
 
-#: ../../../src/init.cpp:147
-msgid "Bitcoin version"
-msgstr "Bitcoin "
-
-#: ../../../src/init.cpp:148
-msgid "Usage:"
-msgstr "Mededeling:"
-
-#: ../../../src/init.cpp:150
-msgid "Send command to -server or bitcoind\n"
-msgstr "Zend commando naar -server of bitcoind\n"
-
-#: ../../../src/init.cpp:151
-msgid "List commands\n"
-msgstr "List van commando's\n"
-
-#: ../../../src/init.cpp:152
-msgid "Get help for a command\n"
-msgstr "Toon hulp voor een commando\n"
-
-#: ../../../src/init.cpp:153
-msgid "Options:\n"
-msgstr "Opties:\n"
-
-#: ../../../src/init.cpp:154
-msgid "Specify configuration file (default: bitcoin.conf)\n"
-msgstr "Specifieer configuratiebestand (standaard: bitcoin.conf)\n"
-
-#: ../../../src/init.cpp:155
-msgid "Specify pid file (default: bitcoind.pid)\n"
-msgstr "Specifieer pid-bestand (standaard: bitcoind.pid)\n"
-
-#: ../../../src/init.cpp:156
-msgid "Generate coins\n"
-msgstr "Genereer coins\n"
-
-#: ../../../src/init.cpp:157
-msgid "Don't generate coins\n"
-msgstr "Genereer geen coins\n"
-
-#: ../../../src/init.cpp:158
-msgid "Start minimized\n"
-msgstr "Geminimaliseerd starten\n"
-
-#: ../../../src/init.cpp:159
-msgid "Specify data directory\n"
-msgstr "Stel datamap in\n"
-
-#: ../../../src/init.cpp:161
-msgid "Specify connection timeout (in milliseconds)\n"
-msgstr "Gelieve de time-out tijd te specifieren (in milliseconden)\n"
-
-#: ../../../src/init.cpp:160
-msgid "Connect through socks4 proxy\n"
-msgstr "Verbind via socks4 proxy\n"
-
-#: ../../../src/init.cpp:161
-msgid "Allow DNS lookups for addnode and connect\n"
-msgstr "Sta DNS-opzoeking toe voor addnode en connect\n"
-
-#: ../../../src/init.cpp:162
-msgid "Add a node to connect to\n"
-msgstr "Voeg een node toe om mee te verbinden\n"
-
-#: ../../../src/init.cpp:163
-msgid "Connect only to the specified node\n"
-msgstr "Verbind alleen met deze node\n"
-
-#: ../../../src/init.cpp:164
-msgid "Don't accept connections from outside\n"
-msgstr "Sta geen verbindingen van buitenaf toe\n"
-
-#: ../../../src/init.cpp:167
-msgid "Don't attempt to use UPnP to map the listening port\n"
-msgstr "Probeer geen UPnP te gebruiken om de poort waarop geluisterd wordt te mappen\n"
-
-#: ../../../src/init.cpp:169
-msgid "Attempt to use UPnP to map the listening port\n"
-msgstr "Probeer UPnP te gebruiken om de poort waarop geluisterd wordt te mappen\n"
-
-#: ../../../src/init.cpp:172
-msgid "Fee per KB to add to transactions you send\n"
-msgstr "Fooi per KB om aan transacties die gezonden worden toe te voegen\n"
-
-#: ../../../src/init.cpp:174
-msgid "Accept command line and JSON-RPC commands\n"
-msgstr "Aanvaard commandolijn en JSON-RPC commando's\n"
-
-#: ../../../src/init.cpp:177
-msgid "Run in the background as a daemon and accept commands\n"
-msgstr "Draai in de achtergrond als daemon en aanvaard commando's\n"
-
-#: ../../../src/init.cpp:179
-msgid "Use the test network\n"
-msgstr "Gebruik het test-netwerk\n"
-
-#: ../../../src/init.cpp:180
-msgid "Username for JSON-RPC connections\n"
-msgstr "Gebruikersnaam voor JSON-RPC verbindingen\n"
-
-#: ../../../src/init.cpp:181
-msgid "Password for JSON-RPC connections\n"
-msgstr "Wachtwoord voor JSON-RPC verbindingen\n"
-
-#: ../../../src/init.cpp:182
-msgid "Listen for JSON-RPC connections on <port> (default: 8332)\n"
-msgstr "Luister voor JSON-RPC verbindingen op <poort> (standaard: 8332)\n"
-
-#: ../../../src/init.cpp:183
-msgid "Allow JSON-RPC connections from specified IP address\n"
-msgstr "Enkel JSON-RPC verbindingen van opgegeven IP adres toestaan\n"
-
-#: ../../../src/init.cpp:184
-msgid "Send commands to node running on <ip> (default: 127.0.0.1)\n"
-msgstr "Zend commando's naar proces dat op <ip> draait (standaard: 127.0.0.1)\n"
-
-#: ../../../src/init.cpp:185
-msgid "Set key pool size to <n> (default: 100)\n"
-msgstr "Stel sleutelpoelgrootte in op <n> (standaard: 100)\n"
-
-#: ../../../src/init.cpp:186
-msgid "Rescan the block chain for missing wallet transactions\n"
-msgstr "Doorzoek de blokken database voor ontbrekende portefeuille-transacties\n"
-
-#: ../../../src/init.cpp:190
-msgid ""
-"\n"
-"SSL options: (see the Bitcoin Wiki for SSL setup instructions)\n"
-msgstr ""
-"\n"
-"SSL opties: (zie de Bitcoin wiki voor SSL instructies)\n"
-
-#: ../../../src/init.cpp:191
-msgid "Use OpenSSL (https) for JSON-RPC connections\n"
-msgstr "Gebruik OpenSSL (https) voor JSON-RPC verbindingen\n"
-
-#: ../../../src/init.cpp:192
-msgid "Server certificate file (default: server.cert)\n"
-msgstr "Certificaat-bestand voor server (standaard: server.cert)\n"
-
-#: ../../../src/init.cpp:193
-msgid "Server private key (default: server.pem)\n"
-msgstr "Geheime sleutel voor server (standaard: server.pem)\n"
-
-#: ../../../src/init.cpp:194
-msgid "Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
-msgstr "Aanvaardbare ciphers (standaard: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
-
-#: ../../../src/init.cpp:198
-msgid "This help message\n"
-msgstr "Dit helpbericht\n"
-
-#: ../../../src/init.cpp:335
-#, c-format
-msgid "Cannot obtain a lock on data directory %s.  Bitcoin is probably already running."
-msgstr "Kan geen lock op de gegevensdirectory %s verkrijgen. Bitcoin draait vermoedelijk reeds."
-
-#: ../../../src/init.cpp:361
-msgid "Error loading addr.dat      \n"
-msgstr "Fout bij laden van bestand addr.dat      \n"
-
-#: ../../../src/init.cpp:367
-msgid "Error loading blkindex.dat      \n"
-msgstr "Fout bij laden van bestand blkindex.dat      \n"
-
-#: ../../../src/init.cpp:374
-msgid "Error loading wallet.dat      \n"
-msgstr "Fout bij laden van bestand wallet.dat      \n"
-
-#: ../../../src/init.cpp:454
-msgid "Invalid -proxy address"
-msgstr "Foutief -proxy adres"
-
-#: ../../../src/init.cpp:477
-msgid "Invalid amount for -paytxfee=<amount>"
-msgstr "Ongeldig bedrag voor -paytxfee=<bedrag>"
+#: ../../../src/bak/wallet.cpp:957
+msgid "Invalid bitcoin address"
+msgstr "Foutief bitcoin-adres"
 
-#: ../../../src/init.cpp:481
-msgid "Warning: -paytxfee is set very high.  This is the transaction fee you will pay if you send a transaction."
-msgstr "Waarschuwing: -paytxfee is zeer hoog ingesteld.  Dit is de fooi die betaald wordt bij het zenden van een transactie."
+#: ../../../src/bak/uibase.cpp:360
+msgid "&Connect through socks4 proxy: "
+msgstr "&Verbind via socks4 proxy: "
 
-#: ../../../src/uibase.h:147
+#: ../../../src/uibase.h:151
 msgid "Transaction Details"
 msgstr "Transactiedetails"
 
-#: ../../../src/uibase.h:199
+#: ../../../src/uibase.h:203
 msgid "Options"
 msgstr "Opties"
 
-#: ../../../src/uibase.h:228
+#: ../../../src/uibase.h:232
 msgid "About Bitcoin"
 msgstr "Over Bitcoin"
 
-#: ../../../src/uibase.h:337
+#: ../../../src/uibase.h:341
 msgid "Your Bitcoin Addresses"
 msgstr "Uw bitcoin-adressen"
+
index e870a16..f53367e 100644 (file)
@@ -2,8 +2,8 @@ msgid ""
 msgstr ""
 "Project-Id-Version: \n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2011-05-21 14:19+0800\n"
-"PO-Revision-Date: 2011-05-28 17:08+0800\n"
+"POT-Creation-Date: 2011-09-06 21:58+0100\n"
+"PO-Revision-Date: 2011-09-17 19:08+0800\n"
 "Last-Translator: Dean Lee <xslidian@gmail.com>\n"
 "Language-Team: \n"
 "MIME-Version: 1.0\n"
@@ -17,127 +17,131 @@ msgstr ""
 "X-Poedit-Bookmarks: 77,-1,-1,-1,-1,-1,-1,-1,-1,-1\n"
 "X-Poedit-SearchPath-0: ../../..\n"
 
-#: ../../../src/init.cpp:142
+#: ../../../src/init.cpp:163
 msgid "Bitcoin version"
 msgstr "Bitcoin 版本"
 
-#: ../../../src/init.cpp:143
+#: ../../../src/init.cpp:164
 msgid "Usage:"
 msgstr "用法:"
 
-#: ../../../src/init.cpp:145
+#: ../../../src/init.cpp:166
 msgid "Send command to -server or bitcoind\n"
 msgstr "发送命令给 -server 或 bitcoin\n"
 
-#: ../../../src/init.cpp:146
+#: ../../../src/init.cpp:167
 msgid "List commands\n"
 msgstr "列出命令\n"
 
-#: ../../../src/init.cpp:147
+#: ../../../src/init.cpp:168
 msgid "Get help for a command\n"
 msgstr "获取命令的帮助\n"
 
-#: ../../../src/init.cpp:148
+#: ../../../src/init.cpp:169
 msgid "Options:\n"
 msgstr "选项:\n"
 
-#: ../../../src/init.cpp:149
+#: ../../../src/init.cpp:170
 msgid "Specify configuration file (default: bitcoin.conf)\n"
 msgstr "指定配置文件 (默认: bitcoin.conf)\n"
 
-#: ../../../src/init.cpp:150
+#: ../../../src/init.cpp:171
 msgid "Specify pid file (default: bitcoind.pid)\n"
 msgstr "指定 pid 文件 (默认: bitcoin.pid)\n"
 
-#: ../../../src/init.cpp:151
+#: ../../../src/init.cpp:172
 msgid "Generate coins\n"
 msgstr "生成货币\n"
 
-#: ../../../src/init.cpp:152
+#: ../../../src/init.cpp:173
 msgid "Don't generate coins\n"
 msgstr "不要生成货币\n"
 
-#: ../../../src/init.cpp:153
+#: ../../../src/init.cpp:174
 msgid "Start minimized\n"
 msgstr "启动时最小化\n"
 
-#: ../../../src/init.cpp:154
+#: ../../../src/init.cpp:175
 msgid "Specify data directory\n"
 msgstr "指定数据目录\n"
 
-#: ../../../src/init.cpp:155
+#: ../../../src/init.cpp:176
+msgid "Specify connection timeout (in milliseconds)\n"
+msgstr "指定连接超时时间 (毫秒)\n"
+
+#: ../../../src/init.cpp:177
 msgid "Connect through socks4 proxy\n"
 msgstr "通过 socks4 代理连接\n"
 
-#: ../../../src/init.cpp:156
+#: ../../../src/init.cpp:178
 msgid "Allow DNS lookups for addnode and connect\n"
 msgstr "允许 DNS 查找新增结点和连接\n"
 
-#: ../../../src/init.cpp:157
+#: ../../../src/init.cpp:179
 msgid "Add a node to connect to\n"
 msgstr "添加一个连接结点\n"
 
-#: ../../../src/init.cpp:158
+#: ../../../src/init.cpp:180
 msgid "Connect only to the specified node\n"
 msgstr "只连接特定结点\n"
 
-#: ../../../src/init.cpp:159
+#: ../../../src/init.cpp:181
 msgid "Don't accept connections from outside\n"
 msgstr "不要接受外部传来的连接\n"
 
-#: ../../../src/init.cpp:162
+#: ../../../src/init.cpp:184
 msgid "Don't attempt to use UPnP to map the listening port\n"
 msgstr "不要尝试使用 UPnP 映射监听端口\n"
 
-#: ../../../src/init.cpp:164
+#: ../../../src/init.cpp:186
 msgid "Attempt to use UPnP to map the listening port\n"
 msgstr "尝试使用 UPnP 映射监听端口\n"
 
-#: ../../../src/init.cpp:167
+#: ../../../src/init.cpp:189
 msgid "Fee per KB to add to transactions you send\n"
 msgstr "您为每 KB 支付所增加的交易佣金\n"
 
-#: ../../../src/init.cpp:169
+#: ../../../src/init.cpp:191
 msgid "Accept command line and JSON-RPC commands\n"
 msgstr "允许命令行和 JSON-RPC 控制\n"
 
-#: ../../../src/init.cpp:172
+#: ../../../src/init.cpp:194
 msgid "Run in the background as a daemon and accept commands\n"
 msgstr "在后台运行并接收命令\n"
 
-#: ../../../src/init.cpp:174
+#: ../../../src/init.cpp:196
 msgid "Use the test network\n"
 msgstr "使用测试网络\n"
 
-#: ../../../src/init.cpp:175
+#: ../../../src/init.cpp:197
 msgid "Username for JSON-RPC connections\n"
 msgstr "JSON-RPC 连接的用户名\n"
 
-#: ../../../src/init.cpp:176
+#: ../../../src/init.cpp:198
 msgid "Password for JSON-RPC connections\n"
 msgstr "JSON-RPC 连接的密码\n"
 
-#: ../../../src/init.cpp:177
+#: ../../../src/init.cpp:199
 msgid "Listen for JSON-RPC connections on <port> (default: 8332)\n"
 msgstr "在端口 <port> 监听 JSON-RPC 连接 (默认: 8332)\n"
 
-#: ../../../src/init.cpp:178
+#: ../../../src/init.cpp:200
 msgid "Allow JSON-RPC connections from specified IP address\n"
 msgstr "允许来自特定 IP 地址的 JSON-RPC 连接\n"
 
-#: ../../../src/init.cpp:179
+#: ../../../src/init.cpp:201
 msgid "Send commands to node running on <ip> (default: 127.0.0.1)\n"
 msgstr "发送命令给运行的结点,IP 地址 <ip> (默认: 127.0.0.1)\n"
 
-#: ../../../src/init.cpp:180
+#: ../../../src/init.cpp:202
 msgid "Set key pool size to <n> (default: 100)\n"
 msgstr "设置密钥池大小为 <n> (默认: 100)\n"
 
-#: ../../../src/init.cpp:181
+#: ../../../src/init.cpp:203
 msgid "Rescan the block chain for missing wallet transactions\n"
-msgstr "重新扫描货币包链来检测丢失的货币交易\n"
+msgstr "重新扫描货币包链来检测丢失的钱包交易\n"
 
-#: ../../../src/init.cpp:185
+#: ../../../src/init.cpp:207
 msgid ""
 "\n"
 "SSL options: (see the Bitcoin Wiki for SSL setup instructions)\n"
@@ -145,106 +149,79 @@ msgstr ""
 "\n"
 "SSL 选项: (SSL 设置步骤请参见 Bitcoin Wiki)\n"
 
-#: ../../../src/init.cpp:186
+#: ../../../src/init.cpp:208
 msgid "Use OpenSSL (https) for JSON-RPC connections\n"
 msgstr "使用 OpenSSL (https) 进行 JSON-RPC 连接\n"
 
-#: ../../../src/init.cpp:187
+#: ../../../src/init.cpp:209
 msgid "Server certificate file (default: server.cert)\n"
 msgstr "服务器证书 (默认: server.cert)\n"
 
-#: ../../../src/init.cpp:188
+#: ../../../src/init.cpp:210
 msgid "Server private key (default: server.pem)\n"
 msgstr "服务器私有密钥 (默认: server.pem)\n"
 
-#: ../../../src/init.cpp:189
+#: ../../../src/init.cpp:211
 msgid "Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
 msgstr "许可密码 (默认: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
 
-#: ../../../src/init.cpp:193
+#: ../../../src/init.cpp:215
 msgid "This help message\n"
 msgstr "本帮助信息\n"
 
-#: ../../../src/init.cpp:330
+#: ../../../src/init.cpp:353
 #, c-format
 msgid "Cannot obtain a lock on data directory %s.  Bitcoin is probably already running."
 msgstr "无法获取数据目录 %s 的锁。 Bitcoin 可能已经启动。"
 
-#: ../../../src/init.cpp:356
+#: ../../../src/init.cpp:379
 msgid "Error loading addr.dat      \n"
 msgstr "加载 addr.dat 出错      \n"
 
-#: ../../../src/init.cpp:362
+#: ../../../src/init.cpp:385
 msgid "Error loading blkindex.dat      \n"
 msgstr "加载 blkindex.dat 出错      \n"
 
-#: ../../../src/init.cpp:369
+#: ../../../src/init.cpp:396
+msgid "Error loading wallet.dat: Wallet corrupted      \n"
+msgstr "加载 wallet.dat 出错: 钱包已损坏      \n"
+
+#: ../../../src/init.cpp:398
+msgid "Error loading wallet.dat: Wallet requires newer version of Bitcoin      \n"
+msgstr "加载 wallet.dat 出错: 钱包要求更高版本的 Bitcoin      \n"
+
+#: ../../../src/init.cpp:400
 msgid "Error loading wallet.dat      \n"
 msgstr "加载 wallet.dat 出错      \n"
 
-#: ../../../src/init.cpp:449
+#: ../../../src/init.cpp:489
 msgid "Invalid -proxy address"
 msgstr "无效 -proxy 地址"
 
-#: ../../../src/init.cpp:472
+#: ../../../src/init.cpp:514
 msgid "Invalid amount for -paytxfee=<amount>"
 msgstr "无效的金额 -paytxfee=<amount>"
 
-#: ../../../src/init.cpp:476
+#: ../../../src/init.cpp:518
 msgid "Warning: -paytxfee is set very high.  This is the transaction fee you will pay if you send a transaction."
 msgstr "警告: -paytxfee 设置得过高。 这个参数是您发送一笔交易要支付的佣金。"
 
-#: ../../../src/main.cpp:1866
+#: ../../../src/main.cpp:1398
 msgid "Warning: Disk space is low  "
 msgstr "警告: 磁盘空间不足"
 
-#: ../../../src/main.cpp:3990
-#, c-format
-msgid "Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds  "
-msgstr "错误: 这个交易因为近期收到支付的数量,难度或者使用而需要支付至少 %s 交易佣金 "
-
-#: ../../../src/main.cpp:3992
-msgid "Error: Transaction creation failed  "
-msgstr "错误: 交易创建失败"
-
-#: ../../../src/main.cpp:3997
-#: ../../../src/ui.cpp:1927
-#: ../../../src/ui.cpp:1932
-#: ../../../src/ui.cpp:2076
-#: ../../../src/ui.cpp:2229
-msgid "Sending..."
-msgstr "正在发送..."
-
-#: ../../../src/main.cpp:4001
-msgid "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."
-msgstr "错误: 交易被拒绝。 这可能是因为您账户里的一些货币应经被使用,比如您使用了一个复制的 wallet.dat 文件,一些货币在另一个复件里支付了但是没有在这里更新。"
-
-#: ../../../src/main.cpp:4014
-msgid "Invalid amount"
-msgstr "无效金额"
-
-#: ../../../src/main.cpp:4016
-#: ../../../src/ui.cpp:2143
-#: ../../../src/ui.cpp:2214
-msgid "Insufficient funds"
-msgstr "余额不足"
-
-#: ../../../src/main.cpp:4021
-msgid "Invalid bitcoin address"
-msgstr "无效 bitcoin 地址"
-
-#: ../../../src/net.cpp:1503
+#: ../../../src/net.cpp:1610
 #, c-format
 msgid "Unable to bind to port %d on this computer.  Bitcoin is probably already running."
 msgstr "无法在这台电脑上绑定 %d 端口。 Bitcoin 可能已经在运行。"
 
-#: ../../../src/rpc.cpp:1802
-#: ../../../src/rpc.cpp:1804
+#: ../../../src/rpc.cpp:2005
+#: ../../../src/rpc.cpp:2007
 #, c-format
 msgid "To use the %s option"
 msgstr "使用 %s 选项"
 
-#: ../../../src/rpc.cpp:1806
+#: ../../../src/rpc.cpp:2009
 #, c-format
 msgid ""
 "Warning: %s, you must set rpcpassword=<password>\n"
@@ -255,7 +232,7 @@ msgstr ""
 "配置文件为: %s\n"
 "如果文件不存在,请创建文件并只给创建者提供只读访问权限。\n"
 
-#: ../../../src/rpc.cpp:1974
+#: ../../../src/rpc.cpp:2185
 #, c-format
 msgid ""
 "You must set rpcpassword=<password> in the configuration file:\n"
@@ -266,109 +243,195 @@ msgstr ""
 "%s\n"
 "如果文件不存在,请创建文件并只给创建者提供只读访问权限。"
 
-#: ../../../src/ui.cpp:204
+#: ../../../src/ui.cpp:217
 #, c-format
 msgid "This transaction is over the size limit.  You can still send it for a fee of %s, which goes to the nodes that process your transaction and helps to support the network.  Do you want to pay the fee?"
 msgstr "这笔交易超过了大小限制。 您依然可以通过支付 %s 的佣金来进行,佣金用来支付为您的交易计算的结点来帮助支撑网络。 您是否要支付佣金?"
 
-#: ../../../src/ui.cpp:303
+#: ../../../src/ui.cpp:261
+#: ../../../src/ui.cpp:1247
+msgid "Enter the current passphrase to the wallet."
+msgstr "输入钱包当前的口令。"
+
+#: ../../../src/ui.cpp:262
+#: ../../../src/ui.cpp:1183
+#: ../../../src/ui.cpp:1200
+#: ../../../src/ui.cpp:1248
+#: ../../../src/ui.cpp:1272
+#: ../../../src/ui.cpp:1292
+msgid "Passphrase"
+msgstr "口令"
+
+#: ../../../src/ui.cpp:268
+msgid "Please supply the current wallet decryption passphrase."
+msgstr "请输入钱包当前的解密口令。"
+
+#: ../../../src/ui.cpp:276
+#: ../../../src/ui.cpp:1257
+#: ../../../src/ui.cpp:1314
+msgid "The passphrase entered for the wallet decryption was incorrect."
+msgstr "钱包解密口令不正确。"
+
+#: ../../../src/ui.cpp:353
 msgid "Status"
 msgstr "状态"
 
-#: ../../../src/ui.cpp:304
+#: ../../../src/ui.cpp:354
 msgid "Date"
 msgstr "日期"
 
-#: ../../../src/ui.cpp:305
+#: ../../../src/ui.cpp:355
 msgid "Description"
 msgstr "描述"
 
-#: ../../../src/ui.cpp:306
+#: ../../../src/ui.cpp:356
 msgid "Debit"
 msgstr "付款人"
 
-#: ../../../src/ui.cpp:307
+#: ../../../src/ui.cpp:357
 msgid "Credit"
 msgstr "信用"
 
-#: ../../../src/ui.cpp:513
+#: ../../../src/ui.cpp:568
 #, c-format
 msgid "Open for %d blocks"
 msgstr "%d 个货币包开放"
 
-#: ../../../src/ui.cpp:515
+#: ../../../src/ui.cpp:570
 #, c-format
 msgid "Open until %s"
 msgstr "开放直到 %s"
 
-#: ../../../src/ui.cpp:521
+#: ../../../src/ui.cpp:576
 #, c-format
 msgid "%d/offline?"
 msgstr "%d/离线?"
 
-#: ../../../src/ui.cpp:523
+#: ../../../src/ui.cpp:578
 #, c-format
 msgid "%d/unconfirmed"
 msgstr "%d/未确认"
 
-#: ../../../src/ui.cpp:525
+#: ../../../src/ui.cpp:580
 #, c-format
 msgid "%d confirmations"
 msgstr "%d 确认"
 
-#: ../../../src/ui.cpp:610
+#: ../../../src/ui.cpp:665
 msgid "Generated"
 msgstr "已生成"
 
-#: ../../../src/ui.cpp:618
+#: ../../../src/ui.cpp:673
 #, c-format
 msgid "Generated (%s matures in %d more blocks)"
 msgstr "已生成 (%s 成熟 %d 新增货币包)"
 
-#: ../../../src/ui.cpp:622
+#: ../../../src/ui.cpp:677
 msgid "Generated - Warning: This block was not received by any other nodes and will probably not be accepted!"
 msgstr "已生成 - 警告: 这个货币包没有被任何其他结点收到,因此很可能不会被接受!"
 
-#: ../../../src/ui.cpp:626
+#: ../../../src/ui.cpp:681
 msgid "Generated (not accepted)"
 msgstr "已生成 (未被接受)"
 
-#: ../../../src/ui.cpp:636
+#: ../../../src/ui.cpp:691
 msgid "From: "
 msgstr "来自: "
 
-#: ../../../src/ui.cpp:660
+#: ../../../src/ui.cpp:715
 msgid "Received with: "
 msgstr "伴随接收: "
 
-#: ../../../src/ui.cpp:706
+#: ../../../src/ui.cpp:760
 msgid "Payment to yourself"
 msgstr "支付给您自己"
 
-#: ../../../src/ui.cpp:740
+#: ../../../src/ui.cpp:794
 msgid "To: "
 msgstr "到: "
 
-#: ../../../src/ui.cpp:1055
+#: ../../../src/ui.cpp:1109
 msgid "    Generating"
 msgstr "    生成中"
 
-#: ../../../src/ui.cpp:1057
+#: ../../../src/ui.cpp:1111
 msgid "(not connected)"
 msgstr "(未连接)"
 
-#: ../../../src/ui.cpp:1060
+#: ../../../src/ui.cpp:1114
 #, c-format
 msgid "     %d connections     %d blocks     %d transactions"
 msgstr "     %d 个连接     %d 个货币包     %d 个交易 "
 
-#: ../../../src/ui.cpp:1165
-#: ../../../src/ui.cpp:2529
+#: ../../../src/ui.cpp:1171
+msgid "Wallet already encrypted."
+msgstr "钱包已加密。"
+
+#: ../../../src/ui.cpp:1182
+msgid ""
+"Enter the new passphrase to the wallet.\n"
+"Please use a passphrase of 10 or more random characters, or eight or more words."
+msgstr ""
+"输入钱包的新口令。\n"
+"请使用 10 个或更多字符,或 8 个或更多单词的口令。"
+
+#: ../../../src/ui.cpp:1189
+#: ../../../src/ui.cpp:1280
+msgid "Error: The supplied passphrase was too short."
+msgstr "错误: 所输口令太短。"
+
+#: ../../../src/ui.cpp:1193
+msgid ""
+"WARNING: If you encrypt your wallet and lose your passphrase, you will LOSE ALL OF YOUR BITCOINS!\n"
+"Are you sure you wish to encrypt your wallet?"
+msgstr ""
+"警告: 如果您加密钱包又丢失口令,将失去全部 BITCOINS!\n"
+"是否确实想加密钱包?"
+
+#: ../../../src/ui.cpp:1199
+msgid "Please re-enter your new wallet passphrase."
+msgstr "请重新输入新的钱包口令。"
+
+#: ../../../src/ui.cpp:1208
+#: ../../../src/ui.cpp:1302
+msgid "Error: the supplied passphrases didn't match."
+msgstr "错误: 所输口令不匹配。"
+
+#: ../../../src/ui.cpp:1218
+msgid "Wallet encryption failed."
+msgstr "钱包加密失败。"
+
+#: ../../../src/ui.cpp:1225
+msgid ""
+"Wallet Encrypted.\n"
+"Remember that encrypting your wallet cannot fully protect your bitcoins from being stolen by malware infecting your computer."
+msgstr ""
+"钱包已加密。\n"
+"请记住,加密钱包无法完全保护您的 bitcoins 不被计算机感染的恶意软件窃取。"
+
+#: ../../../src/ui.cpp:1236
+msgid "Wallet is unencrypted, please encrypt it first."
+msgstr "钱包未加密,请先加密。"
+
+#: ../../../src/ui.cpp:1271
+msgid "Enter the new passphrase for the wallet."
+msgstr "输入钱包的新口令。"
+
+#: ../../../src/ui.cpp:1291
+msgid "Re-enter the new passphrase for the wallet."
+msgstr "重新输入钱包的新口令。"
+
+#: ../../../src/ui.cpp:1323
+msgid "Wallet Passphrase Changed."
+msgstr "钱包口令已更改。"
+
+#: ../../../src/ui.cpp:1379
+#: ../../../src/ui.cpp:2825
 msgid "New Receiving Address"
 msgstr "新建接收地址"
 
-#: ../../../src/ui.cpp:1166
-#: ../../../src/ui.cpp:2530
+#: ../../../src/ui.cpp:1380
+#: ../../../src/ui.cpp:2826
 msgid ""
 "You should use a new address for each payment you receive.\n"
 "\n"
@@ -378,234 +441,248 @@ msgstr ""
 "\n"
 "标签"
 
-#: ../../../src/ui.cpp:1235
+#: ../../../src/ui.cpp:1464
 msgid "<b>Status:</b> "
 msgstr "<b>状态:</b> "
 
-#: ../../../src/ui.cpp:1240
+#: ../../../src/ui.cpp:1469
 msgid ", has not been successfully broadcast yet"
 msgstr ",尚未被成功广播"
 
-#: ../../../src/ui.cpp:1242
+#: ../../../src/ui.cpp:1471
 #, c-format
 msgid ", broadcast through %d node"
 msgstr ",通过 %d 个结点广播"
 
-#: ../../../src/ui.cpp:1244
+#: ../../../src/ui.cpp:1473
 #, c-format
 msgid ", broadcast through %d nodes"
 msgstr ",通过 %d 个结点广播"
 
-#: ../../../src/ui.cpp:1248
+#: ../../../src/ui.cpp:1477
 msgid "<b>Date:</b> "
 msgstr "<b>日期:</b>"
 
-#: ../../../src/ui.cpp:1256
+#: ../../../src/ui.cpp:1485
 msgid "<b>Source:</b> Generated<br>"
 msgstr "<b>来源:</b> 生成<br>"
 
-#: ../../../src/ui.cpp:1262
-#: ../../../src/ui.cpp:1280
+#: ../../../src/ui.cpp:1491
+#: ../../../src/ui.cpp:1508
 msgid "<b>From:</b> "
 msgstr "<b>从:</b> "
 
-#: ../../../src/ui.cpp:1280
+#: ../../../src/ui.cpp:1508
 msgid "unknown"
 msgstr "未知"
 
-#: ../../../src/ui.cpp:1281
-#: ../../../src/ui.cpp:1305
-#: ../../../src/ui.cpp:1364
+#: ../../../src/ui.cpp:1509
+#: ../../../src/ui.cpp:1533
+#: ../../../src/ui.cpp:1592
 msgid "<b>To:</b> "
 msgstr "<b>到:</b> "
 
-#: ../../../src/ui.cpp:1284
+#: ../../../src/ui.cpp:1512
 msgid " (yours, label: "
 msgstr " (您的标签: "
 
-#: ../../../src/ui.cpp:1286
+#: ../../../src/ui.cpp:1514
 msgid " (yours)"
 msgstr " (您的)"
 
-#: ../../../src/ui.cpp:1323
-#: ../../../src/ui.cpp:1335
-#: ../../../src/ui.cpp:1381
-#: ../../../src/ui.cpp:1398
+#: ../../../src/ui.cpp:1551
+#: ../../../src/ui.cpp:1563
+#: ../../../src/ui.cpp:1609
+#: ../../../src/ui.cpp:1626
 msgid "<b>Credit:</b> "
 msgstr "<b>信用:</b> "
 
-#: ../../../src/ui.cpp:1325
+#: ../../../src/ui.cpp:1553
 #, c-format
 msgid "(%s matures in %d more blocks)"
 msgstr "(%s 收获在 %d 更多的货币包)"
 
-#: ../../../src/ui.cpp:1327
+#: ../../../src/ui.cpp:1555
 msgid "(not accepted)"
 msgstr "(未被接受)"
 
-#: ../../../src/ui.cpp:1372
-#: ../../../src/ui.cpp:1380
-#: ../../../src/ui.cpp:1395
+#: ../../../src/ui.cpp:1600
+#: ../../../src/ui.cpp:1608
+#: ../../../src/ui.cpp:1623
 msgid "<b>Debit:</b> "
 msgstr "<b>付款人:</b> "
 
-#: ../../../src/ui.cpp:1386
+#: ../../../src/ui.cpp:1614
 msgid "<b>Transaction fee:</b> "
 msgstr "<b>交易佣金:</b> "
 
-#: ../../../src/ui.cpp:1402
+#: ../../../src/ui.cpp:1630
 msgid "<b>Net amount:</b> "
 msgstr "<b>网络金额:</b> "
 
-#: ../../../src/ui.cpp:1409
+#: ../../../src/ui.cpp:1637
 msgid "Message:"
 msgstr "消息:"
 
-#: ../../../src/ui.cpp:1411
+#: ../../../src/ui.cpp:1639
 msgid "Comment:"
 msgstr "评论"
 
-#: ../../../src/ui.cpp:1414
+#: ../../../src/ui.cpp:1642
 msgid "Generated coins must wait 120 blocks before they can be spent.  When you generated this block, it was broadcast to the network to be added to the block chain.  If it fails to get into the chain, it will change to \"not accepted\" and not be spendable.  This may occasionally happen if another node generates a block within a few seconds of yours."
 msgstr "生成的货币必须等待 120 个货币包之后才能够使用。 当您生成了一个货币包后,它被广播给网络来加入货币包链中。 如果它无法加入货币包链中,他将会标记为\"不被接受\"且不能被支付。 这种情况可能因为在您生成这个货币包之后的几秒钟内有别人也生成了货币包而发生。"
 
-#: ../../../src/ui.cpp:1594
+#: ../../../src/ui.cpp:1826
 msgid "Cannot write autostart/bitcoin.desktop file"
 msgstr "无法写入 autostart/bitcoin.desktop 文件"
 
-#: ../../../src/ui.cpp:1630
+#: ../../../src/ui.cpp:1862
 msgid "Main"
 msgstr "主要"
 
-#: ../../../src/ui.cpp:1638
+#: ../../../src/ui.cpp:1872
 msgid "&Start Bitcoin on window system startup"
 msgstr "开机自动启动 Bitcoin(&S)"
 
-#: ../../../src/ui.cpp:1645
+#: ../../../src/ui.cpp:1879
 msgid "&Minimize on close"
 msgstr "关闭时最小化(&M)"
 
-#: ../../../src/ui.cpp:1787
+#: ../../../src/ui.cpp:2021
 #, c-format
 msgid "version %s"
 msgstr "版本 %s"
 
-#: ../../../src/ui.cpp:1899
+#: ../../../src/ui.cpp:2144
 msgid "Error in amount  "
 msgstr "金额有误  "
 
-#: ../../../src/ui.cpp:1899
-#: ../../../src/ui.cpp:1904
-#: ../../../src/ui.cpp:1909
-#: ../../../src/ui.cpp:1944
-#: ../../../src/uibase.cpp:55
+#: ../../../src/ui.cpp:2144
+#: ../../../src/ui.cpp:2149
+#: ../../../src/ui.cpp:2154
+#: ../../../src/ui.cpp:2207
+#: ../../../src/uibase.cpp:61
 msgid "Send Coins"
 msgstr "发送货币"
 
-#: ../../../src/ui.cpp:1904
+#: ../../../src/ui.cpp:2149
 msgid "Amount exceeds your balance  "
 msgstr "金额超出您的账户余额"
 
-#: ../../../src/ui.cpp:1909
+#: ../../../src/ui.cpp:2154
 msgid "Total exceeds your balance when the "
 msgstr "总费用超出您的账户余额当 "
 
-#: ../../../src/ui.cpp:1909
+#: ../../../src/ui.cpp:2154
 msgid " transaction fee is included  "
 msgstr " 交易佣金已包括"
 
-#: ../../../src/ui.cpp:1927
+#: ../../../src/ui.cpp:2181
 msgid "Payment sent  "
 msgstr "付款已发送"
 
-#: ../../../src/ui.cpp:1944
+#: ../../../src/ui.cpp:2181
+#: ../../../src/ui.cpp:2191
+#: ../../../src/ui.cpp:2341
+#: ../../../src/ui.cpp:2506
+#: ../../../src/wallet.cpp:1088
+msgid "Sending..."
+msgstr "正在发送..."
+
+#: ../../../src/ui.cpp:2207
 msgid "Invalid address  "
 msgstr "无效地址  "
 
-#: ../../../src/ui.cpp:1997
+#: ../../../src/ui.cpp:2262
 #, c-format
 msgid "Sending %s to %s"
 msgstr "发送 %s 给 %s"
 
-#: ../../../src/ui.cpp:2070
-#: ../../../src/ui.cpp:2103
+#: ../../../src/ui.cpp:2335
+#: ../../../src/ui.cpp:2368
 msgid "CANCELLED"
 msgstr "已取消"
 
-#: ../../../src/ui.cpp:2074
+#: ../../../src/ui.cpp:2339
 msgid "Cancelled"
 msgstr "已取消"
 
-#: ../../../src/ui.cpp:2076
+#: ../../../src/ui.cpp:2341
 msgid "Transfer cancelled  "
 msgstr "传输已取消  "
 
-#: ../../../src/ui.cpp:2129
+#: ../../../src/ui.cpp:2394
 msgid "Error: "
 msgstr "错误: "
 
-#: ../../../src/ui.cpp:2148
+#: ../../../src/ui.cpp:2408
+#: ../../../src/ui.cpp:2477
+#: ../../../src/wallet.cpp:1106
+msgid "Insufficient funds"
+msgstr "余额不足"
+
+#: ../../../src/ui.cpp:2413
 msgid "Connecting..."
 msgstr "正在连接..."
 
-#: ../../../src/ui.cpp:2153
+#: ../../../src/ui.cpp:2418
 msgid "Unable to connect"
 msgstr "无法连接"
 
-#: ../../../src/ui.cpp:2158
+#: ../../../src/ui.cpp:2423
 msgid "Requesting public key..."
 msgstr "正在请求公共密钥..."
 
-#: ../../../src/ui.cpp:2170
+#: ../../../src/ui.cpp:2435
 msgid "Received public key..."
 msgstr "收到公共密钥..."
 
-#: ../../../src/ui.cpp:2184
+#: ../../../src/ui.cpp:2449
 msgid "Recipient is not accepting transactions sent by IP address"
 msgstr "收款人不接受来自 IP 地址的交易"
 
-#: ../../../src/ui.cpp:2186
+#: ../../../src/ui.cpp:2451
 msgid "Transfer was not accepted"
 msgstr "传输没有被接受"
 
-#: ../../../src/ui.cpp:2195
+#: ../../../src/ui.cpp:2460
 msgid "Invalid response received"
 msgstr "接收到无效回复"
 
-#: ../../../src/ui.cpp:2210
+#: ../../../src/ui.cpp:2473
 msgid "Creating transaction..."
 msgstr "正在创建交易..."
 
-#: ../../../src/ui.cpp:2222
+#: ../../../src/ui.cpp:2496
 #, c-format
 msgid "This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds"
 msgstr "这笔交易因为它最近收到的付款的数量,交易难度或者使用情况,需要至少 %s 交易佣金"
 
-#: ../../../src/ui.cpp:2224
+#: ../../../src/ui.cpp:2498
 msgid "Transaction creation failed"
 msgstr "交易创建失败"
 
-#: ../../../src/ui.cpp:2231
+#: ../../../src/ui.cpp:2508
 msgid "Transaction aborted"
 msgstr "交易中止"
 
-#: ../../../src/ui.cpp:2239
+#: ../../../src/ui.cpp:2516
 msgid "Lost connection, transaction cancelled"
 msgstr "失去连接,交易已取消"
 
-#: ../../../src/ui.cpp:2255
+#: ../../../src/ui.cpp:2532
 msgid "Sending payment..."
 msgstr "正在发送付款..."
 
-#: ../../../src/ui.cpp:2261
+#: ../../../src/ui.cpp:2544
 msgid "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."
-msgstr "交易被拒绝。 这可能是因为您账户中的一部分货币已经被使用,比如您使用了一个复制的 wallet.dat 文件,而且货币在另一个副本里使用但没有在这里标记。"
+msgstr "交易被拒绝。 这可能是因为您账户中的一部分货币已经被使用,比如您使用了一个复制的 wallet.dat 文件,而且货币在另一个副本里支付但没有在这里标记。"
 
-#: ../../../src/ui.cpp:2270
+#: ../../../src/ui.cpp:2553
 msgid "Waiting for confirmation..."
 msgstr "正在等待确认..."
 
-#: ../../../src/ui.cpp:2288
+#: ../../../src/ui.cpp:2570
 msgid ""
 "The payment was sent, but the recipient was unable to verify it.\n"
 "The transaction is recorded and will credit to the recipient,\n"
@@ -615,84 +692,84 @@ msgstr ""
 "交易已经被记录,并且支付给收款人,\n"
 "但是评论信息可能是空的。"
 
-#: ../../../src/ui.cpp:2297
+#: ../../../src/ui.cpp:2579
 msgid "Payment was sent, but an invalid response was received"
 msgstr "支付已发送,但是收到无效回复"
 
-#: ../../../src/ui.cpp:2303
+#: ../../../src/ui.cpp:2585
 msgid "Payment completed"
 msgstr "付款完成"
 
-#: ../../../src/ui.cpp:2334
-#: ../../../src/ui.cpp:2480
-#: ../../../src/ui.cpp:2517
+#: ../../../src/ui.cpp:2627
+#: ../../../src/ui.cpp:2773
+#: ../../../src/ui.cpp:2813
 msgid "Name"
 msgstr "姓名"
 
-#: ../../../src/ui.cpp:2335
-#: ../../../src/ui.cpp:2480
-#: ../../../src/ui.cpp:2517
+#: ../../../src/ui.cpp:2628
+#: ../../../src/ui.cpp:2773
+#: ../../../src/ui.cpp:2813
 msgid "Address"
 msgstr "地址"
 
-#: ../../../src/ui.cpp:2337
-#: ../../../src/ui.cpp:2492
+#: ../../../src/ui.cpp:2630
+#: ../../../src/ui.cpp:2785
 msgid "Label"
 msgstr "标签"
 
-#: ../../../src/ui.cpp:2338
-#: ../../../src/uibase.cpp:837
+#: ../../../src/ui.cpp:2631
+#: ../../../src/uibase.cpp:847
 msgid "Bitcoin Address"
 msgstr "Bitcoin 地址"
 
-#: ../../../src/ui.cpp:2462
+#: ../../../src/ui.cpp:2755
 msgid "This is one of your own addresses for receiving payments and cannot be entered in the address book.  "
 msgstr "这是您拥有的接收付款的地址之一,它不能够进入这个地址簿。 "
 
-#: ../../../src/ui.cpp:2480
-#: ../../../src/ui.cpp:2486
+#: ../../../src/ui.cpp:2773
+#: ../../../src/ui.cpp:2779
 msgid "Edit Address"
 msgstr "编辑地址"
 
-#: ../../../src/ui.cpp:2492
+#: ../../../src/ui.cpp:2785
 msgid "Edit Address Label"
 msgstr "编辑地址标签"
 
-#: ../../../src/ui.cpp:2517
-#: ../../../src/ui.cpp:2523
+#: ../../../src/ui.cpp:2813
+#: ../../../src/ui.cpp:2819
 msgid "Add Address"
 msgstr "添加地址"
 
-#: ../../../src/ui.cpp:2600
+#: ../../../src/ui.cpp:2906
 msgid "Bitcoin"
 msgstr "Bitcoin"
 
-#: ../../../src/ui.cpp:2602
+#: ../../../src/ui.cpp:2908
 msgid "Bitcoin - Generating"
 msgstr "Bitcoin - 生成中"
 
-#: ../../../src/ui.cpp:2604
+#: ../../../src/ui.cpp:2910
 msgid "Bitcoin - (not connected)"
 msgstr "Bitcoin - (未连接)"
 
-#: ../../../src/ui.cpp:2683
+#: ../../../src/ui.cpp:2989
 msgid "&Open Bitcoin"
 msgstr "打开 Bitcoin(&O)"
 
-#: ../../../src/ui.cpp:2684
+#: ../../../src/ui.cpp:2990
 msgid "&Send Bitcoins"
 msgstr "发送 Bitcoins(&S)"
 
-#: ../../../src/ui.cpp:2685
+#: ../../../src/ui.cpp:2991
 msgid "O&ptions..."
 msgstr "选项(&P)..."
 
-#: ../../../src/ui.cpp:2688
+#: ../../../src/ui.cpp:2994
 #: ../../../src/uibase.cpp:25
 msgid "E&xit"
 msgstr "退出(&X)"
 
-#: ../../../src/ui.cpp:2904
+#: ../../../src/ui.cpp:3220
 msgid "Program has crashed and will terminate.  "
 msgstr "程序崩溃,即将关闭。 "
 
@@ -704,152 +781,160 @@ msgstr "文件(&F)"
 msgid "&Your Receiving Addresses..."
 msgstr "您的接收地址(&Y)..."
 
-#: ../../../src/uibase.cpp:36
+#: ../../../src/uibase.cpp:35
+msgid "&Encrypt Wallet..."
+msgstr "加密钱包(&E)..."
+
+#: ../../../src/uibase.cpp:38
+msgid "&Change Wallet Encryption Passphrase..."
+msgstr "更改钱包加密口令(&C)..."
+
+#: ../../../src/uibase.cpp:42
 msgid "&Options..."
 msgstr "选项(&O)..."
 
-#: ../../../src/uibase.cpp:39
+#: ../../../src/uibase.cpp:45
 msgid "&Settings"
 msgstr "设置(&S)"
 
-#: ../../../src/uibase.cpp:43
+#: ../../../src/uibase.cpp:49
 msgid "&About..."
 msgstr "关于(&A)..."
 
-#: ../../../src/uibase.cpp:46
+#: ../../../src/uibase.cpp:52
 msgid "&Help"
 msgstr "帮助(&H)"
 
-#: ../../../src/uibase.cpp:56
+#: ../../../src/uibase.cpp:62
 msgid "Address Book"
 msgstr "地址簿"
 
-#: ../../../src/uibase.cpp:69
+#: ../../../src/uibase.cpp:75
 msgid "Your Bitcoin Address:"
 msgstr "您的 Bitcoin 地址:"
 
-#: ../../../src/uibase.cpp:76
+#: ../../../src/uibase.cpp:82
 msgid " &New... "
 msgstr " 新建(&N)... "
 
-#: ../../../src/uibase.cpp:79
-#: ../../../src/uibase.cpp:780
-#: ../../../src/uibase.cpp:883
+#: ../../../src/uibase.cpp:85
+#: ../../../src/uibase.cpp:790
+#: ../../../src/uibase.cpp:893
 msgid " &Copy to Clipboard "
 msgstr " 复制到剪贴板(&C)"
 
-#: ../../../src/uibase.cpp:93
+#: ../../../src/uibase.cpp:99
 msgid "Balance:"
 msgstr "账户余额:"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " All"
 msgstr "全部"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " Sent"
 msgstr " 已发送"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " Received"
 msgstr " 已接收"
 
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
 msgid " In Progress"
 msgstr "处理中"
 
-#: ../../../src/uibase.cpp:130
+#: ../../../src/uibase.cpp:136
 msgid "All Transactions"
 msgstr "所有交易"
 
-#: ../../../src/uibase.cpp:141
+#: ../../../src/uibase.cpp:147
 msgid "Sent/Received"
 msgstr "已发送/已接收"
 
-#: ../../../src/uibase.cpp:152
+#: ../../../src/uibase.cpp:158
 msgid "Sent"
 msgstr "已发送"
 
-#: ../../../src/uibase.cpp:163
+#: ../../../src/uibase.cpp:169
 msgid "Received"
 msgstr "已接收"
 
-#: ../../../src/uibase.cpp:302
-#: ../../../src/uibase.cpp:443
-#: ../../../src/uibase.cpp:542
-#: ../../../src/uibase.cpp:722
-#: ../../../src/uibase.cpp:783
-#: ../../../src/uibase.cpp:892
-#: ../../../src/uibase.cpp:981
+#: ../../../src/uibase.cpp:312
+#: ../../../src/uibase.cpp:453
+#: ../../../src/uibase.cpp:552
+#: ../../../src/uibase.cpp:732
+#: ../../../src/uibase.cpp:793
+#: ../../../src/uibase.cpp:902
+#: ../../../src/uibase.cpp:991
 msgid "OK"
 msgstr "确定"
 
-#: ../../../src/uibase.cpp:345
+#: ../../../src/uibase.cpp:355
 msgid "&Start Bitcoin on system startup"
 msgstr "开机自动启动(&S)"
 
-#: ../../../src/uibase.cpp:348
+#: ../../../src/uibase.cpp:358
 msgid "&Minimize to the tray instead of the taskbar"
 msgstr "最小化到系统托盘(&M)"
 
-#: ../../../src/uibase.cpp:351
+#: ../../../src/uibase.cpp:361
 msgid "Map port using &UPnP"
 msgstr "使用 &UPnP 映射端口"
 
-#: ../../../src/uibase.cpp:354
+#: ../../../src/uibase.cpp:364
 msgid "M&inimize to the tray on close"
 msgstr "关闭时最小化到托盘(&I)"
 
-#: ../../../src/uibase.cpp:360
-msgid "&Connect through socks4 proxy: "
-msgstr "通过 socks4 代理连接(&C): "
+#: ../../../src/uibase.cpp:370
+msgid "&Connect through socks4 proxy (requires restart to apply): "
+msgstr "通过 socks4 代理连接 (重启生效) (&C): "
 
-#: ../../../src/uibase.cpp:371
+#: ../../../src/uibase.cpp:381
 msgid "Proxy &IP:"
 msgstr "代理服务器(&I):"
 
-#: ../../../src/uibase.cpp:379
+#: ../../../src/uibase.cpp:389
 msgid " &Port:"
 msgstr " 端口(&P):"
 
-#: ../../../src/uibase.cpp:392
+#: ../../../src/uibase.cpp:402
 msgid "Optional transaction fee per KB that helps make sure your transactions are processed quickly.  Most transactions are 1KB.  Fee 0.01 recommended."
 msgstr "可以选择按照KB支付交易佣金来确保您的交易得到迅速处理。 大多数交易需要 1KB。 建议支付 0.01。"
 
-#: ../../../src/uibase.cpp:399
+#: ../../../src/uibase.cpp:409
 msgid "Pay transaction fee:"
 msgstr "支付交易佣金:"
 
-#: ../../../src/uibase.cpp:420
+#: ../../../src/uibase.cpp:430
 msgid "// [don't translate] Test panel 2 for future expansion"
 msgstr ""
 
-#: ../../../src/uibase.cpp:424
+#: ../../../src/uibase.cpp:434
 msgid "// [don't translate] Let's not start multiple pages until the first page is filled up"
 msgstr ""
 
-#: ../../../src/uibase.cpp:446
-#: ../../../src/uibase.cpp:668
-#: ../../../src/uibase.cpp:727
-#: ../../../src/uibase.cpp:786
-#: ../../../src/uibase.cpp:895
-#: ../../../src/uibase.cpp:984
+#: ../../../src/uibase.cpp:456
+#: ../../../src/uibase.cpp:678
+#: ../../../src/uibase.cpp:737
+#: ../../../src/uibase.cpp:796
+#: ../../../src/uibase.cpp:905
+#: ../../../src/uibase.cpp:994
 msgid "Cancel"
 msgstr "取消"
 
-#: ../../../src/uibase.cpp:449
+#: ../../../src/uibase.cpp:459
 msgid "&Apply"
 msgstr "应用(&A)"
 
-#: ../../../src/uibase.cpp:508
+#: ../../../src/uibase.cpp:518
 msgid "Bitcoin "
 msgstr "Bitcoin "
 
-#: ../../../src/uibase.cpp:514
+#: ../../../src/uibase.cpp:524
 msgid "version"
 msgstr "版本"
 
-#: ../../../src/uibase.cpp:525
+#: ../../../src/uibase.cpp:535
 msgid ""
 "Copyright (c) 2009-2011 Bitcoin Developers\n"
 "\n"
@@ -870,39 +955,39 @@ msgstr ""
 "(http://www.openssl.org/),以及 Eric Young(eay@cryptsoft.com)\n"
 "编写的加密软件和 Thomas Bernard 编写的 UPnP 软件。"
 
-#: ../../../src/uibase.cpp:581
+#: ../../../src/uibase.cpp:591
 msgid "Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
 msgstr "输入 Bitcoin 地址 (比如 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
 
-#: ../../../src/uibase.cpp:595
+#: ../../../src/uibase.cpp:605
 msgid "Pay &To:"
 msgstr "付款给(&T):"
 
-#: ../../../src/uibase.cpp:610
+#: ../../../src/uibase.cpp:620
 msgid "&Paste"
 msgstr "粘贴(&P)"
 
-#: ../../../src/uibase.cpp:613
+#: ../../../src/uibase.cpp:623
 msgid " Address &Book..."
 msgstr " 地址簿(&B)..."
 
-#: ../../../src/uibase.cpp:620
+#: ../../../src/uibase.cpp:630
 msgid "&Amount:"
 msgstr "数量(&A):"
 
-#: ../../../src/uibase.cpp:630
+#: ../../../src/uibase.cpp:640
 msgid "T&ransfer:"
 msgstr "传输(&R):"
 
-#: ../../../src/uibase.cpp:636
+#: ../../../src/uibase.cpp:646
 msgid " Standard"
 msgstr "标准"
 
-#: ../../../src/uibase.cpp:663
+#: ../../../src/uibase.cpp:673
 msgid "&Send"
 msgstr "发送(&S)"
 
-#: ../../../src/uibase.cpp:711
+#: ../../../src/uibase.cpp:721
 msgid ""
 "\n"
 "\n"
@@ -912,56 +997,80 @@ msgstr ""
 "\n"
 "正在连接..."
 
-#: ../../../src/uibase.cpp:761
+#: ../../../src/uibase.cpp:771
 msgid "These are your Bitcoin addresses for receiving payments.  You may want to give a different one to each sender so you can keep track of who is paying you.  The highlighted address is displayed in the main window."
 msgstr "这些是您用来接收付款的 Bitcoin 地址。 您可能需要给每一个付款人一个不同的地址从而可以最终每一笔交易是谁支付的。 下面高亮的地址是您的主窗口正在使用的地址。"
 
-#: ../../../src/uibase.cpp:774
-#: ../../../src/uibase.cpp:886
+#: ../../../src/uibase.cpp:784
+#: ../../../src/uibase.cpp:896
 msgid "&Edit..."
 msgstr "编辑(&E)..."
 
-#: ../../../src/uibase.cpp:777
-#: ../../../src/uibase.cpp:889
+#: ../../../src/uibase.cpp:787
+#: ../../../src/uibase.cpp:899
 msgid " &New Address... "
 msgstr " 新建地址(&N)..."
 
-#: ../../../src/uibase.cpp:849
+#: ../../../src/uibase.cpp:859
 msgid "Sending"
 msgstr "发送人地址"
 
-#: ../../../src/uibase.cpp:857
+#: ../../../src/uibase.cpp:867
 msgid "These are your Bitcoin addresses for receiving payments.  You can give a different one to each sender to keep track of who is paying you.  The highlighted address will be displayed in the main window."
 msgstr "这些是您用来接收付款的 Bitcoin 地址。 您可以给每一个付款人一个不同的地址从而可以最终每一笔交易是谁支付的。 下面高亮的地址是您的主窗口正在使用的地址。"
 
-#: ../../../src/uibase.cpp:870
+#: ../../../src/uibase.cpp:880
 msgid "Receiving"
 msgstr "我的接收地址"
 
-#: ../../../src/uibase.cpp:880
+#: ../../../src/uibase.cpp:890
 msgid "&Delete"
 msgstr "删除(&D)"
 
-#: ../../../src/util.cpp:866
+#: ../../../src/util.cpp:870
 msgid "Warning: Please check that your computer's date and time are correct.  If your clock is wrong Bitcoin will not work properly."
 msgstr "警告: 请检查您的电脑日期和时间是否正确。 如果您的时钟不正确 Bitcoin 将无法正常工作。"
 
-#: ../../../src/util.cpp:899
+#: ../../../src/util.cpp:904
 msgid "beta"
 msgstr "测试版"
 
-#: ../../../src/uibase.h:147
+#: ../../../src/wallet.cpp:1073
+msgid "Error: Wallet locked, unable to create transaction  "
+msgstr "错误: 钱包已锁定,无法创建交易  "
+
+#: ../../../src/wallet.cpp:1081
+#, c-format
+msgid "Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds  "
+msgstr "错误: 这个交易因为近期收到支付的数量,难度或者使用而需要支付至少 %s 交易佣金 "
+
+#: ../../../src/wallet.cpp:1083
+msgid "Error: Transaction creation failed  "
+msgstr "错误: 交易创建失败"
+
+#: ../../../src/wallet.cpp:1092
+msgid "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."
+msgstr "错误: 交易被拒绝。 这可能是因为您账户里的一些货币应经被使用,比如您使用了一个复制的 wallet.dat 文件,一些货币在另一个副本里支付了但是没有在这里更新。"
+
+#: ../../../src/wallet.cpp:1104
+msgid "Invalid amount"
+msgstr "无效金额"
+
+#: ../../../src/uibase.h:151
 msgid "Transaction Details"
 msgstr "交易详情"
 
-#: ../../../src/uibase.h:199
+#: ../../../src/uibase.h:203
 msgid "Options"
 msgstr "选项"
 
-#: ../../../src/uibase.h:228
+#: ../../../src/uibase.h:232
 msgid "About Bitcoin"
 msgstr "关于 Bitcoin"
 
-#: ../../../src/uibase.h:337
+#: ../../../src/uibase.h:341
 msgid "Your Bitcoin Addresses"
 msgstr "您的 Bitcoin 地址"
+
+#~ msgid "Invalid bitcoin address"
+#~ msgstr "无效 bitcoin 地址"
diff --git a/scripts/qt/extract_strings_qt.py b/scripts/qt/extract_strings_qt.py
new file mode 100755 (executable)
index 0000000..6627de4
--- /dev/null
@@ -0,0 +1,63 @@
+#!/usr/bin/python
+'''
+Extract _("...") strings for translation and convert to Qt4 stringdefs so that
+they can be picked up by Qt linguist.
+'''
+from subprocess import Popen, PIPE
+
+OUT_CPP="src/qt/bitcoinstrings.cpp"
+EMPTY=['""']
+
+def parse_po(text):
+    """
+    Parse 'po' format produced by xgettext.
+    Return a list of (msgid,msgstr) tuples.
+    """
+    messages = []
+    msgid = []
+    msgstr = []
+    in_msgid = False
+    in_msgstr = False
+
+    for line in text.split('\n'):
+        line = line.rstrip('\r')
+        if line.startswith('msgid '):
+            if in_msgstr:
+                messages.append((msgid, msgstr))
+                in_msgstr = False
+            # message start
+            in_msgid = True
+            
+            msgid = [line[6:]]
+        elif line.startswith('msgstr '):
+            in_msgid = False
+            in_msgstr = True
+            msgstr = [line[7:]]
+        elif line.startswith('"'):
+            if in_msgid:
+                msgid.append(line)
+            if in_msgstr:
+                msgstr.append(line)
+
+    if in_msgstr:
+        messages.append((msgid, msgstr))
+
+    return messages
+
+files = ['src/base58.h', 'src/bignum.h', 'src/db.cpp', 'src/db.h', 'src/headers.h', 'src/init.cpp', 'src/init.h', 'src/irc.cpp', 'src/irc.h', 'src/key.h', 'src/main.cpp', 'src/main.h', 'src/net.cpp', 'src/net.h', 'src/noui.h', 'src/script.cpp', 'src/script.h', 'src/serialize.h', 'src/strlcpy.h', 'src/uint256.h', 'src/util.cpp', 'src/util.h']
+
+# xgettext -n --keyword=_ $FILES
+child = Popen(['xgettext','--output=-','-n','--keyword=_'] + files, stdout=PIPE)
+(out, err) = child.communicate()
+
+messages = parse_po(out) 
+
+f = open(OUT_CPP, 'w')
+f.write('#include <QtGlobal>\n')
+f.write('// Automatically generated by extract_strings.py\n')
+f.write('static const char *bitcoin_strings[] = {')
+for (msgid, msgstr) in messages:
+    if msgid != EMPTY:
+        f.write('QT_TRANSLATE_NOOP("bitcoin-core", %s),\n' % ('\n'.join(msgid)))
+f.write('};')
+f.close()
diff --git a/scripts/qt/img/reload.xcf b/scripts/qt/img/reload.xcf
new file mode 100644 (file)
index 0000000..dc8be62
Binary files /dev/null and b/scripts/qt/img/reload.xcf differ
diff --git a/scripts/qt/make_spinner.py b/scripts/qt/make_spinner.py
new file mode 100755 (executable)
index 0000000..136aff3
--- /dev/null
@@ -0,0 +1,43 @@
+#!/usr/bin/env python
+# W.J. van der Laan, 2011
+# Make spinning .mng animation from a .png
+# Requires imagemagick 6.7+
+from __future__ import division
+from os import path
+from PIL import Image
+from subprocess import Popen
+
+SRC='img/reload_scaled.png'
+DST='../../src/qt/res/movies/update_spinner.mng'
+TMPDIR='/tmp'
+TMPNAME='tmp-%03i.png'
+NUMFRAMES=35
+FRAMERATE=10.0
+CONVERT='convert'
+CLOCKWISE=True
+DSIZE=(16,16)
+
+im_src = Image.open(SRC)
+
+if CLOCKWISE:
+    im_src = im_src.transpose(Image.FLIP_LEFT_RIGHT)
+
+def frame_to_filename(frame):
+    return path.join(TMPDIR, TMPNAME % frame)
+
+frame_files = []
+for frame in xrange(NUMFRAMES):
+    rotation = (frame + 0.5) / NUMFRAMES * 360.0
+    if CLOCKWISE:
+        rotation = -rotation
+    im_new = im_src.rotate(rotation, Image.BICUBIC)
+    im_new.thumbnail(DSIZE, Image.ANTIALIAS)
+    outfile = frame_to_filename(frame)
+    im_new.save(outfile, 'png')
+    frame_files.append(outfile)
+
+p = Popen([CONVERT, "-delay", str(FRAMERATE), "-dispose", "2"] + frame_files + [DST])
+p.communicate()
+
+
+
diff --git a/scripts/qt/make_windows_icon.py b/scripts/qt/make_windows_icon.py
new file mode 100755 (executable)
index 0000000..bf607b1
--- /dev/null
@@ -0,0 +1,9 @@
+#!/bin/bash
+# create multiresolution windows icon
+ICON_SRC=../../src/qt/res/icons/bitcoin.png
+ICON_DST=../../src/qt/res/icons/bitcoin.ico
+convert ${ICON_SRC} -resize 16x16 bitcoin-16.png
+convert ${ICON_SRC} -resize 32x32 bitcoin-32.png
+convert ${ICON_SRC} -resize 48x48 bitcoin-48.png
+convert bitcoin-16.png bitcoin-32.png bitcoin-48.png ${ICON_DST}
+
index 734d217..6192680 100644 (file)
Binary files a/share/pixmaps/bitcoin.ico and b/share/pixmaps/bitcoin.ico differ
similarity index 99%
rename from src/rpc.cpp
rename to src/bitcoinrpc.cpp
index 4f43427..f111ad2 100644 (file)
@@ -50,13 +50,13 @@ Object JSONRPCError(int code, const string& message)
 }
 
 
-void PrintConsole(const char* format, ...)
+void PrintConsole(const std::string &format, ...)
 {
     char buffer[50000];
     int limit = sizeof(buffer);
     va_list arg_ptr;
     va_start(arg_ptr, format);
-    int ret = _vsnprintf(buffer, limit, format, arg_ptr);
+    int ret = _vsnprintf(buffer, limit, format.c_str(), arg_ptr);
     va_end(arg_ptr);
     if (ret < 0 || ret >= limit)
     {
@@ -1498,7 +1498,8 @@ Value getwork(const Array& params, bool fHelp)
     if (IsInitialBlockDownload())
         throw JSONRPCError(-10, "Bitcoin is downloading blocks...");
 
-    static map<uint256, pair<CBlock*, unsigned int> > mapNewBlock;
+    typedef map<uint256, pair<CBlock*, CScript> > mapNewBlock_t;
+    static mapNewBlock_t mapNewBlock;
     static vector<CBlock*> vNewBlock;
     static CReserveKey reservekey(pwalletMain);
 
@@ -1537,11 +1538,10 @@ Value getwork(const Array& params, bool fHelp)
 
         // Update nExtraNonce
         static unsigned int nExtraNonce = 0;
-        static int64 nPrevTime = 0;
-        IncrementExtraNonce(pblock, pindexPrev, nExtraNonce, nPrevTime);
+        IncrementExtraNonce(pblock, pindexPrev, nExtraNonce);
 
         // Save
-        mapNewBlock[pblock->hashMerkleRoot] = make_pair(pblock, nExtraNonce);
+        mapNewBlock[pblock->hashMerkleRoot] = make_pair(pblock, pblock->vtx[0].vin[0].scriptSig);
 
         // Prebuild hash buffers
         char pmidstate[32];
@@ -1574,11 +1574,10 @@ Value getwork(const Array& params, bool fHelp)
         if (!mapNewBlock.count(pdata->hashMerkleRoot))
             return false;
         CBlock* pblock = mapNewBlock[pdata->hashMerkleRoot].first;
-        unsigned int nExtraNonce = mapNewBlock[pdata->hashMerkleRoot].second;
 
         pblock->nTime = pdata->nTime;
         pblock->nNonce = pdata->nNonce;
-        pblock->vtx[0].vin[0].scriptSig = CScript() << pblock->nBits << CBigNum(nExtraNonce);
+        pblock->vtx[0].vin[0].scriptSig = mapNewBlock[pdata->hashMerkleRoot].second;
         pblock->hashMerkleRoot = pblock->BuildMerkleTree();
 
         return CheckWork(pblock, *pwalletMain, reservekey);
similarity index 100%
rename from src/rpc.h
rename to src/bitcoinrpc.h
index d0c7434..5e39ecc 100644 (file)
 #include "uibase.h"
 #include "ui.h"
 #else
+#ifdef QT_GUI
+#include "qtui.h"
+#else
 #include "noui.h"
 #endif
+#endif
 
 #ifdef GUI
 #include "xpm/addressbook16.xpm"
index dbc2c41..a1835c9 100644 (file)
@@ -4,7 +4,7 @@
 // file license.txt or http://www.opensource.org/licenses/mit-license.php.
 #include "headers.h"
 #include "db.h"
-#include "rpc.h"
+#include "bitcoinrpc.h"
 #include "net.h"
 #include "init.h"
 #include "strlcpy.h"
@@ -80,7 +80,7 @@ void HandleSIGTERM(int)
 //
 // Start
 //
-#ifndef GUI
+#if !defined(QT_GUI) && !defined(GUI)
 int main(int argc, char* argv[])
 {
     bool fRet = false;
@@ -179,6 +179,8 @@ bool AppInit2(int argc, char* argv[])
             "  -addnode=<ip>    \t  "   + _("Add a node to connect to\n") +
             "  -connect=<ip>    \t\t  " + _("Connect only to the specified node\n") +
             "  -nolisten        \t  "   + _("Don't accept connections from outside\n") +
+            "  -banscore=<n>    \t  "   + _("Threshold for disconnecting misbehaving peers (default: 100)\n") +
+            "  -bantime=<n>     \t  "   + _("Number of seconds to keep misbehaving peers from reconnecting (default: 86400)\n") +
 #ifdef USE_UPNP
 #if USE_UPNP
             "  -noupnp          \t  "   + _("Don't attempt to use UPnP to map the listening port\n") +
@@ -240,10 +242,9 @@ bool AppInit2(int argc, char* argv[])
         fServer = GetBoolArg("-server");
 
     /* force fServer when running without GUI */
-#ifndef GUI
+#if !defined(QT_GUI) && !defined(GUI)
     fServer = true;
 #endif
-
     fPrintToConsole = GetBoolArg("-printtoconsole");
     fPrintToDebugger = GetBoolArg("-printtodebugger");
 
@@ -252,6 +253,7 @@ bool AppInit2(int argc, char* argv[])
     fNoListen = GetBoolArg("-nolisten") || fTOR;
     fLogTimestamps = GetBoolArg("-logtimestamps");
 
+#ifndef QT_GUI
     for (int i = 1; i < argc; i++)
         if (!IsSwitchChar(argv[i][0]))
             fCommandLine = true;
@@ -261,6 +263,7 @@ bool AppInit2(int argc, char* argv[])
         int ret = CommandLineRPC(argc, argv);
         exit(ret);
     }
+#endif
 
 #ifndef __WXMSW__
     if (fDaemon)
@@ -373,18 +376,21 @@ bool AppInit2(int argc, char* argv[])
     strErrors = "";
     int64 nStart;
 
+    InitMessage(_("Loading addresses..."));
     printf("Loading addresses...\n");
     nStart = GetTimeMillis();
     if (!LoadAddresses())
         strErrors += _("Error loading addr.dat      \n");
     printf(" addresses   %15"PRI64d"ms\n", GetTimeMillis() - nStart);
 
+    InitMessage(_("Loading block index..."));
     printf("Loading block index...\n");
     nStart = GetTimeMillis();
     if (!LoadBlockIndex())
         strErrors += _("Error loading blkindex.dat      \n");
     printf(" block index %15"PRI64d"ms\n", GetTimeMillis() - nStart);
 
+    InitMessage(_("Loading wallet..."));
     printf("Loading wallet...\n");
     nStart = GetTimeMillis();
     bool fFirstRun;
@@ -415,12 +421,14 @@ bool AppInit2(int argc, char* argv[])
     }
     if (pindexBest != pindexRescan)
     {
+        InitMessage(_("Rescanning..."));
         printf("Rescanning last %i blocks (from block %i)...\n", pindexBest->nHeight - pindexRescan->nHeight, pindexRescan->nHeight);
         nStart = GetTimeMillis();
         pwalletMain->ScanForWalletTransactions(pindexRescan, true);
         printf(" rescan      %15"PRI64d"ms\n", GetTimeMillis() - nStart);
     }
 
+    InitMessage(_("Done loading"));
     printf("Done loading\n");
 
         //// debug print
@@ -543,7 +551,7 @@ bool AppInit2(int argc, char* argv[])
     RandAddSeedPerfmon();
 
     if (!CreateThread(StartNode, NULL))
-        wxMessageBox("Error: CreateThread(StartNode) failed", "Bitcoin");
+        wxMessageBox(_("Error: CreateThread(StartNode) failed"), "Bitcoin");
 
     if (fServer)
         CreateThread(ThreadRPCServer, NULL);
@@ -553,7 +561,7 @@ bool AppInit2(int argc, char* argv[])
         SetStartOnSystemStartup(true);
 #endif
 
-#ifndef GUI
+#if !defined(QT_GUI) && !defined(GUI)
     while (1)
         Sleep(5000);
 #endif
index dce26d3..434c8e8 100644 (file)
@@ -32,6 +32,7 @@ uint256 hashGenesisBlock("0x000000000019d6689c085ae165831e934ff763ae46a2a6c172b3
 static CBigNum bnProofOfWorkLimit(~uint256(0) >> 32);
 const int nTotalBlocksEstimate = 140700; // Conservative estimate of total nr of blocks on main chain
 const int nInitialBlockThreshold = 120; // Regard blocks up until N-threshold as "initial download"
+int nMaxBlocksOfPeers = 0; // Amount of blocks that other nodes claim to have
 CBlockIndex* pindexGenesisBlock = NULL;
 int nBestHeight = -1;
 CBigNum bnBestChainWork = 0;
@@ -296,24 +297,24 @@ bool CTransaction::CheckTransaction() const
 {
     // Basic checks that don't depend on any context
     if (vin.empty())
-        return error("CTransaction::CheckTransaction() : vin empty");
+        return DoS(10, error("CTransaction::CheckTransaction() : vin empty"));
     if (vout.empty())
-        return error("CTransaction::CheckTransaction() : vout empty");
+        return DoS(10, error("CTransaction::CheckTransaction() : vout empty"));
     // Size limits
     if (::GetSerializeSize(*this, SER_NETWORK) > MAX_BLOCK_SIZE)
-        return error("CTransaction::CheckTransaction() : size limits failed");
+        return DoS(100, error("CTransaction::CheckTransaction() : size limits failed"));
 
     // Check for negative or overflow output values
     int64 nValueOut = 0;
     BOOST_FOREACH(const CTxOut& txout, vout)
     {
         if (txout.nValue < 0)
-            return error("CTransaction::CheckTransaction() : txout.nValue negative");
+            return DoS(100, error("CTransaction::CheckTransaction() : txout.nValue negative"));
         if (txout.nValue > MAX_MONEY)
-            return error("CTransaction::CheckTransaction() : txout.nValue too high");
+            return DoS(100, error("CTransaction::CheckTransaction() : txout.nValue too high"));
         nValueOut += txout.nValue;
         if (!MoneyRange(nValueOut))
-            return error("CTransaction::CheckTransaction() : txout total out of range");
+            return DoS(100, error("CTransaction::CheckTransaction() : txout total out of range"));
     }
 
     // Check for duplicate inputs
@@ -328,13 +329,13 @@ bool CTransaction::CheckTransaction() const
     if (IsCoinBase())
     {
         if (vin[0].scriptSig.size() < 2 || vin[0].scriptSig.size() > 100)
-            return error("CTransaction::CheckTransaction() : coinbase script size");
+            return DoS(100, error("CTransaction::CheckTransaction() : coinbase script size"));
     }
     else
     {
         BOOST_FOREACH(const CTxIn& txin, vin)
             if (txin.prevout.IsNull())
-                return error("CTransaction::CheckTransaction() : prevout is null");
+                return DoS(10, error("CTransaction::CheckTransaction() : prevout is null"));
     }
 
     return true;
@@ -350,7 +351,7 @@ bool CTransaction::AcceptToMemoryPool(CTxDB& txdb, bool fCheckInputs, bool* pfMi
 
     // Coinbase is only valid in a block, not as a loose transaction
     if (IsCoinBase())
-        return error("AcceptToMemoryPool() : coinbase as individual tx");
+        return DoS(100, error("AcceptToMemoryPool() : coinbase as individual tx"));
 
     // To help v0.1.5 clients who would see it as a negative number
     if ((int64)nLockTime > INT_MAX)
@@ -363,7 +364,7 @@ bool CTransaction::AcceptToMemoryPool(CTxDB& txdb, bool fCheckInputs, bool* pfMi
     // 34 bytes because a TxOut is:
     //   20-byte address + 8 byte bitcoin amount + 5 bytes of ops + 1 byte script length
     if (GetSigOpCount() > nSize / 34 || nSize < 100)
-        return error("AcceptToMemoryPool() : nonstandard transaction");
+        return DoS(10, error("AcceptToMemoryPool() : transaction with out-of-bounds SigOpCount"));
 
     // Rather not work on nonstandard transactions (unless -testnet)
     if (!fTestNet && !IsStandard())
@@ -726,6 +727,12 @@ int GetTotalBlocksEstimate()
     }
 }
 
+// Return maximum amount of blocks that other nodes claim to have
+int GetNumBlocksOfPeers()
+{
+    return std::max(nMaxBlocksOfPeers, GetTotalBlocksEstimate());
+}
+
 bool IsInitialBlockDownload()
 {
     if (pindexBest == NULL || nBestHeight < (GetTotalBlocksEstimate()-nInitialBlockThreshold))
@@ -848,26 +855,28 @@ bool CTransaction::ConnectInputs(CTxDB& txdb, map<uint256, CTxIndex>& mapTestPoo
             }
 
             if (prevout.n >= txPrev.vout.size() || prevout.n >= txindex.vSpent.size())
-                return error("ConnectInputs() : %s prevout.n out of range %d %d %d prev tx %s\n%s", GetHash().ToString().substr(0,10).c_str(), prevout.n, txPrev.vout.size(), txindex.vSpent.size(), prevout.hash.ToString().substr(0,10).c_str(), txPrev.ToString().c_str());
+                return DoS(100, error("ConnectInputs() : %s prevout.n out of range %d %d %d prev tx %s\n%s", GetHash().ToString().substr(0,10).c_str(), prevout.n, txPrev.vout.size(), txindex.vSpent.size(), prevout.hash.ToString().substr(0,10).c_str(), txPrev.ToString().c_str()));
 
             // If prev is coinbase, check that it's matured
             if (txPrev.IsCoinBase())
                 for (CBlockIndex* pindex = pindexBlock; pindex && pindexBlock->nHeight - pindex->nHeight < COINBASE_MATURITY; pindex = pindex->pprev)
                     if (pindex->nBlockPos == txindex.pos.nBlockPos && pindex->nFile == txindex.pos.nFile)
-                        return error("ConnectInputs() : tried to spend coinbase at depth %d", pindexBlock->nHeight - pindex->nHeight);
+                        return DoS(10, error("ConnectInputs() : tried to spend coinbase at depth %d", pindexBlock->nHeight - pindex->nHeight));
 
             // Verify signature
             if (!VerifySignature(txPrev, *this, i))
-                return error("ConnectInputs() : %s VerifySignature failed", GetHash().ToString().substr(0,10).c_str());
+                return DoS(100,error("ConnectInputs() : %s VerifySignature failed", GetHash().ToString().substr(0,10).c_str()));
 
-            // Check for conflicts
+            // Check for conflicts (double-spend)
+            // This doesn't trigger the DoS code on purpose; if it did, it would make it easier
+            // for an attacker to attempt to split the network.
             if (!txindex.vSpent[prevout.n].IsNull())
                 return fMiner ? false : error("ConnectInputs() : %s prev tx already used at %s", GetHash().ToString().substr(0,10).c_str(), txindex.vSpent[prevout.n].ToString().c_str());
 
             // Check for negative or overflow input values
             nValueIn += txPrev.vout[prevout.n].nValue;
             if (!MoneyRange(txPrev.vout[prevout.n].nValue) || !MoneyRange(nValueIn))
-                return error("ConnectInputs() : txin values out of range");
+                return DoS(100, error("ConnectInputs() : txin values out of range"));
 
             // Mark outpoints as spent
             txindex.vSpent[prevout.n] = posThisTx;
@@ -880,17 +889,17 @@ bool CTransaction::ConnectInputs(CTxDB& txdb, map<uint256, CTxIndex>& mapTestPoo
         }
 
         if (nValueIn < GetValueOut())
-            return error("ConnectInputs() : %s value in < value out", GetHash().ToString().substr(0,10).c_str());
+            return DoS(100, error("ConnectInputs() : %s value in < value out", GetHash().ToString().substr(0,10).c_str()));
 
         // Tally transaction fees
         int64 nTxFee = nValueIn - GetValueOut();
         if (nTxFee < 0)
-            return error("ConnectInputs() : %s nTxFee < 0", GetHash().ToString().substr(0,10).c_str());
+            return DoS(100, error("ConnectInputs() : %s nTxFee < 0", GetHash().ToString().substr(0,10).c_str()));
         if (nTxFee < nMinFee)
             return false;
         nFees += nTxFee;
         if (!MoneyRange(nFees))
-            return error("ConnectInputs() : nFees out of range");
+            return DoS(100, error("ConnectInputs() : nFees out of range"));
     }
 
     if (fBlock)
@@ -1233,11 +1242,11 @@ bool CBlock::CheckBlock() const
 
     // Size limits
     if (vtx.empty() || vtx.size() > MAX_BLOCK_SIZE || ::GetSerializeSize(*this, SER_NETWORK) > MAX_BLOCK_SIZE)
-        return error("CheckBlock() : size limits failed");
+        return DoS(100, error("CheckBlock() : size limits failed"));
 
     // Check proof of work matches claimed amount
     if (!CheckProofOfWork(GetHash(), nBits))
-        return error("CheckBlock() : proof of work failed");
+        return DoS(50, error("CheckBlock() : proof of work failed"));
 
     // Check timestamp
     if (GetBlockTime() > GetAdjustedTime() + 2 * 60 * 60)
@@ -1245,23 +1254,23 @@ bool CBlock::CheckBlock() const
 
     // First transaction must be coinbase, the rest must not be
     if (vtx.empty() || !vtx[0].IsCoinBase())
-        return error("CheckBlock() : first tx is not coinbase");
+        return DoS(100, error("CheckBlock() : first tx is not coinbase"));
     for (int i = 1; i < vtx.size(); i++)
         if (vtx[i].IsCoinBase())
-            return error("CheckBlock() : more than one coinbase");
+            return DoS(100, error("CheckBlock() : more than one coinbase"));
 
     // Check transactions
     BOOST_FOREACH(const CTransaction& tx, vtx)
         if (!tx.CheckTransaction())
-            return error("CheckBlock() : CheckTransaction failed");
+            return DoS(tx.nDoS, error("CheckBlock() : CheckTransaction failed"));
 
     // Check that it's not full of nonstandard transactions
     if (GetSigOpCount() > MAX_BLOCK_SIGOPS)
-        return error("CheckBlock() : too many nonstandard transactions");
+        return DoS(100, error("CheckBlock() : out-of-bounds SigOpCount"));
 
     // Check merkleroot
     if (hashMerkleRoot != BuildMerkleTree())
-        return error("CheckBlock() : hashMerkleRoot mismatch");
+        return DoS(100, error("CheckBlock() : hashMerkleRoot mismatch"));
 
     return true;
 }
@@ -1276,13 +1285,13 @@ bool CBlock::AcceptBlock()
     // Get prev block index
     map<uint256, CBlockIndex*>::iterator mi = mapBlockIndex.find(hashPrevBlock);
     if (mi == mapBlockIndex.end())
-        return error("AcceptBlock() : prev block not found");
+        return DoS(10, error("AcceptBlock() : prev block not found"));
     CBlockIndex* pindexPrev = (*mi).second;
     int nHeight = pindexPrev->nHeight+1;
 
     // Check proof of work
     if (nBits != GetNextWorkRequired(pindexPrev))
-        return error("AcceptBlock() : incorrect proof of work");
+        return DoS(100, error("AcceptBlock() : incorrect proof of work"));
 
     // Check timestamp against prev
     if (GetBlockTime() <= pindexPrev->GetMedianTimePast())
@@ -1291,7 +1300,7 @@ bool CBlock::AcceptBlock()
     // Check that all transactions are finalized
     BOOST_FOREACH(const CTransaction& tx, vtx)
         if (!tx.IsFinal(nHeight, GetBlockTime()))
-            return error("AcceptBlock() : contains a non-final transaction");
+            return DoS(10, error("AcceptBlock() : contains a non-final transaction"));
 
     // Check that the block chain matches the known block chain up to a checkpoint
     if (!fTestNet)
@@ -1304,7 +1313,7 @@ bool CBlock::AcceptBlock()
             (nHeight == 118000 && hash != uint256("0x000000000000774a7f8a7a12dc906ddb9e17e75d684f15e00f8767f9e8f36553")) ||
             (nHeight == 134444 && hash != uint256("0x00000000000005b12ffd4cd315cd34ffd4a594f430ac814c91184a0d42d2b0fe")) ||
             (nHeight == 140700 && hash != uint256("0x000000000000033b512028abb90e1626d8b346fd0ed598ac0a3c371138dce2bd")))
-            return error("AcceptBlock() : rejected by checkpoint lockin at %d", nHeight);
+            return DoS(100, error("AcceptBlock() : rejected by checkpoint lockin at %d", nHeight));
 
     // Write block to history file
     if (!CheckDiskSpace(::GetSerializeSize(*this, SER_DISK)))
@@ -1744,9 +1753,10 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
 {
     static map<unsigned int, vector<unsigned char> > mapReuseKey;
     RandAddSeedPerfmon();
-    if (fDebug)
+    if (fDebug) {
         printf("%s ", DateTimeStrFormat("%x %H:%M:%S", GetTime()).c_str());
-    printf("received: %s (%d bytes)\n", strCommand.c_str(), vRecv.size());
+        printf("received: %s (%d bytes)\n", strCommand.c_str(), vRecv.size());
+    }
     if (mapArgs.count("-dropmessagestest") && GetRand(atoi(mapArgs["-dropmessagestest"])) == 0)
     {
         printf("dropmessagestest DROPPING RECV MESSAGE\n");
@@ -1761,7 +1771,10 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
     {
         // Each connection can only send one version message
         if (pfrom->nVersion != 0)
+        {
+            pfrom->Misbehaving(1);
             return false;
+        }
 
         int64 nTime;
         CAddress addrMe;
@@ -1839,12 +1852,17 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
         pfrom->fSuccessfullyConnected = true;
 
         printf("version message: version %d, blocks=%d\n", pfrom->nVersion, pfrom->nStartingHeight);
+        if(pfrom->nStartingHeight > nMaxBlocksOfPeers)
+        {
+            nMaxBlocksOfPeers = pfrom->nStartingHeight;
+        }
     }
 
 
     else if (pfrom->nVersion == 0)
     {
         // Must have a version message before anything else
+        pfrom->Misbehaving(1);
         return false;
     }
 
@@ -1866,7 +1884,10 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
         if (pfrom->nVersion < 31402 && mapAddresses.size() > 1000)
             return true;
         if (vAddr.size() > 1000)
+        {
+            pfrom->Misbehaving(20);
             return error("message addr size() = %d", vAddr.size());
+        }
 
         // Store the new addresses
         CAddrDB addrDB;
@@ -1924,7 +1945,10 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
         vector<CInv> vInv;
         vRecv >> vInv;
         if (vInv.size() > 50000)
+        {
+            pfrom->Misbehaving(20);
             return error("message inv size() = %d", vInv.size());
+        }
 
         CTxDB txdb("r");
         BOOST_FOREACH(const CInv& inv, vInv)
@@ -1934,7 +1958,8 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
             pfrom->AddInventoryKnown(inv);
 
             bool fAlreadyHave = AlreadyHave(txdb, inv);
-            printf("  got inventory: %s  %s\n", inv.ToString().c_str(), fAlreadyHave ? "have" : "new");
+            if (fDebug)
+                printf("  got inventory: %s  %s\n", inv.ToString().c_str(), fAlreadyHave ? "have" : "new");
 
             if (!fAlreadyHave)
                 pfrom->AskFor(inv);
@@ -1952,7 +1977,10 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
         vector<CInv> vInv;
         vRecv >> vInv;
         if (vInv.size() > 50000)
+        {
+            pfrom->Misbehaving(20);
             return error("message getdata size() = %d", vInv.size());
+        }
 
         BOOST_FOREACH(const CInv& inv, vInv)
         {
@@ -2124,6 +2152,7 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
             printf("storing orphan tx %s\n", inv.hash.ToString().substr(0,10).c_str());
             AddOrphanTx(vMsg);
         }
+        if (tx.nDoS) pfrom->Misbehaving(tx.nDoS);
     }
 
 
@@ -2140,6 +2169,7 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
 
         if (ProcessBlock(pfrom, &block))
             mapAlreadyAskedFor.erase(inv);
+        if (block.nDoS) pfrom->Misbehaving(block.nDoS);
     }
 
 
@@ -2798,16 +2828,17 @@ CBlock* CreateNewBlock(CReserveKey& reservekey)
 }
 
 
-void IncrementExtraNonce(CBlock* pblock, CBlockIndex* pindexPrev, unsigned int& nExtraNonce, int64& nPrevTime)
+void IncrementExtraNonce(CBlock* pblock, CBlockIndex* pindexPrev, unsigned int& nExtraNonce)
 {
     // Update nExtraNonce
-    int64 nNow = max(pindexPrev->GetMedianTimePast()+1, GetAdjustedTime());
-    if (++nExtraNonce >= 0x7f && nNow > nPrevTime+1)
+    static uint256 hashPrevBlock;
+    if (hashPrevBlock != pblock->hashPrevBlock)
     {
-        nExtraNonce = 1;
-        nPrevTime = nNow;
+        nExtraNonce = 0;
+        hashPrevBlock = pblock->hashPrevBlock;
     }
-    pblock->vtx[0].vin[0].scriptSig = CScript() << pblock->nBits << CBigNum(nExtraNonce);
+    ++nExtraNonce;
+    pblock->vtx[0].vin[0].scriptSig = CScript() << pblock->nTime << CBigNum(nExtraNonce);
     pblock->hashMerkleRoot = pblock->BuildMerkleTree();
 }
 
@@ -2905,7 +2936,6 @@ void static BitcoinMiner(CWallet *pwallet)
     // Each thread has its own key and counter
     CReserveKey reservekey(pwallet);
     unsigned int nExtraNonce = 0;
-    int64 nPrevTime = 0;
 
     while (fGenerateBitcoins)
     {
@@ -2932,7 +2962,7 @@ void static BitcoinMiner(CWallet *pwallet)
         auto_ptr<CBlock> pblock(CreateNewBlock(reservekey));
         if (!pblock.get())
             return;
-        IncrementExtraNonce(pblock.get(), pindexPrev, nExtraNonce, nPrevTime);
+        IncrementExtraNonce(pblock.get(), pindexPrev, nExtraNonce);
 
         printf("Running BitcoinMiner with %d transactions in block\n", pblock->vtx.size());
 
index 427067b..1106bb9 100644 (file)
@@ -94,11 +94,12 @@ bool ProcessMessages(CNode* pfrom);
 bool SendMessages(CNode* pto, bool fSendTrickle);
 void GenerateBitcoins(bool fGenerate, CWallet* pwallet);
 CBlock* CreateNewBlock(CReserveKey& reservekey);
-void IncrementExtraNonce(CBlock* pblock, CBlockIndex* pindexPrev, unsigned int& nExtraNonce, int64& nPrevTime);
+void IncrementExtraNonce(CBlock* pblock, CBlockIndex* pindexPrev, unsigned int& nExtraNonce);
 void FormatHashBuffers(CBlock* pblock, char* pmidstate, char* pdata, char* phash1);
 bool CheckWork(CBlock* pblock, CWallet& wallet, CReserveKey& reservekey);
 bool CheckProofOfWork(uint256 hash, unsigned int nBits);
 int GetTotalBlocksEstimate();
+int GetNumBlocksOfPeers();
 bool IsInitialBlockDownload();
 std::string GetWarnings(std::string strFor);
 
@@ -399,6 +400,9 @@ public:
     std::vector<CTxOut> vout;
     unsigned int nLockTime;
 
+    // Denial-of-service detection:
+    mutable int nDoS;
+    bool DoS(int nDoSIn, bool fIn) const { nDoS += nDoSIn; return fIn; }
 
     CTransaction()
     {
@@ -420,6 +424,7 @@ public:
         vin.clear();
         vout.clear();
         nLockTime = 0;
+        nDoS = 0;  // Denial-of-service prevention
     }
 
     bool IsNull() const
@@ -786,6 +791,9 @@ public:
     // memory only
     mutable std::vector<uint256> vMerkleTree;
 
+    // Denial-of-service detection:
+    mutable int nDoS;
+    bool DoS(int nDoSIn, bool fIn) const { nDoS += nDoSIn; return fIn; }
 
     CBlock()
     {
@@ -819,6 +827,7 @@ public:
         nNonce = 0;
         vtx.clear();
         vMerkleTree.clear();
+        nDoS = 0;
     }
 
     bool IsNull() const
index 24cc127..cae82f8 100644 (file)
@@ -49,7 +49,7 @@ HEADERS = \
     net.h \
     noui.h \
     protocol.h \
-    rpc.h \
+    bitcoinrpc.h \
     script.h \
     serialize.h \
     strlcpy.h \
@@ -76,7 +76,7 @@ OBJS= \
     obj/main.o \
     obj/net.o \
     obj/protocol.o \
-    obj/rpc.o \
+    obj/bitcoinrpc.o \
     obj/script.o \
     obj/util.o \
     obj/wallet.o \
index 1ca1a7b..5aa5eba 100644 (file)
@@ -46,7 +46,7 @@ HEADERS = \
     net.h \
     noui.h \
     protocol.h \
-    rpc.h \
+    bitcoinrpc.h \
     script.h \
     serialize.h \
     strlcpy.h \
@@ -74,7 +74,7 @@ OBJS= \
     obj/main.o \
     obj/net.o \
     obj/protocol.o \
-    obj/rpc.o \
+    obj/bitcoinrpc.o \
     obj/script.o \
     obj/util.o \
     obj/wallet.o \
index 97264c7..9dce3f3 100644 (file)
@@ -46,7 +46,7 @@ HEADERS = \
     net.h \
     noui.h \
     protocol.h \
-    rpc.h \
+    bitcoinrpc.h \
     script.h \
     serialize.h \
     strlcpy.h \
@@ -65,7 +65,7 @@ OBJS= \
     obj/main.o \
     obj/net.o \
     obj/protocol.o \
-    obj/rpc.o \
+    obj/bitcoinrpc.o \
     obj/script.o \
     obj/util.o \
     obj/wallet.o \
index 43c3ea7..b893853 100644 (file)
@@ -80,7 +80,7 @@ HEADERS = \
     net.h \
     noui.h \
     protocol.h \
-    rpc.h \
+    bitcoinrpc.h \
     script.h \
     serialize.h \
     strlcpy.h \
@@ -99,7 +99,7 @@ OBJS= \
     obj/main.o \
     obj/net.o \
     obj/protocol.o \
-    obj/rpc.o \
+    obj/bitcoinrpc.o \
     obj/script.o \
     obj/util.o \
     obj/wallet.o \
index a5437bc..5d28379 100644 (file)
@@ -59,7 +59,7 @@ HEADERS = \
     net.h \
     noui.h \
     protocol.h \
-    rpc.h \
+    bitcoinrpc.h \
     script.h \
     serialize.h \
     strlcpy.h \
index 509d890..1792bf7 100644 (file)
@@ -726,6 +726,52 @@ void CNode::Cleanup()
 }
 
 
+std::map<unsigned int, int64> CNode::setBanned;
+CCriticalSection CNode::cs_setBanned;
+
+void CNode::ClearBanned()
+{
+    setBanned.clear();
+}
+
+bool CNode::IsBanned(unsigned int ip)
+{
+    bool fResult = false;
+    CRITICAL_BLOCK(cs_setBanned)
+    {
+        std::map<unsigned int, int64>::iterator i = setBanned.find(ip);
+        if (i != setBanned.end())
+        {
+            int64 t = (*i).second;
+            if (GetTime() < t)
+                fResult = true;
+        }
+    }
+    return fResult;
+}
+
+bool CNode::Misbehaving(int howmuch)
+{
+    if (addr.IsLocal())
+    {
+        printf("Warning: local node %s misbehaving\n", addr.ToString().c_str());
+        return false;
+    }
+
+    nMisbehavior += howmuch;
+    if (nMisbehavior >= GetArg("-banscore", 100))
+    {
+        int64 banTime = GetTime()+GetArg("-bantime", 60*60*24);  // Default 24-hour ban
+        CRITICAL_BLOCK(cs_setBanned)
+            if (setBanned[addr.ip] < banTime)
+                setBanned[addr.ip] = banTime;
+        CloseSocketDisconnect();
+        printf("Disconnected %s for misbehavior (score=%d)\n", addr.ToString().c_str(), nMisbehavior);
+        return true;
+    }
+    return false;
+}
+
 
 
 
@@ -896,6 +942,11 @@ void ThreadSocketHandler2(void* parg)
             {
                 closesocket(hSocket);
             }
+            else if (CNode::IsBanned(addr.ip))
+            {
+                printf("connetion from %s dropped (banned)\n", addr.ToString().c_str());
+                closesocket(hSocket);
+            }
             else
             {
                 printf("accepted connection %s\n", addr.ToString().c_str());
@@ -1454,7 +1505,8 @@ bool OpenNetworkConnection(const CAddress& addrConnect)
     //
     if (fShutdown)
         return false;
-    if (addrConnect.ip == addrLocalHost.ip || !addrConnect.IsIPv4() || FindNode(addrConnect.ip))
+    if (addrConnect.ip == addrLocalHost.ip || !addrConnect.IsIPv4() ||
+        FindNode(addrConnect.ip) || CNode::IsBanned(addrConnect.ip))
         return false;
 
     vnThreadsRunning[1]--;
@@ -1713,7 +1765,7 @@ void StartNode(void* parg)
         printf("Error: CreateThread(ThreadIRCSeed) failed\n");
 
     // Send and receive from sockets, accept connections
-    CreateThread(ThreadSocketHandler, NULL, true);
+    CreateThread(ThreadSocketHandler, NULL);
 
     // Initiate outbound connections
     if (!CreateThread(ThreadOpenConnections, NULL))
index efac1f4..5b3568f 100644 (file)
--- a/src/net.h
+++ b/src/net.h
@@ -124,6 +124,13 @@ public:
     bool fDisconnect;
 protected:
     int nRefCount;
+
+    // Denial-of-service detection/prevention
+    // Key is ip address, value is banned-until-time
+    static std::map<unsigned int, int64> setBanned;
+    static CCriticalSection cs_setBanned;
+    int nMisbehavior;
+
 public:
     int64 nReleaseTime;
     std::map<uint256, CRequestTracker> mapRequests;
@@ -148,7 +155,6 @@ public:
     // publish and subscription
     std::vector<char> vfSubscribe;
 
-
     CNode(SOCKET hSocketIn, CAddress addrIn, bool fInboundIn=false)
     {
         nServices = 0;
@@ -185,6 +191,7 @@ public:
         nStartingHeight = -1;
         fGetAddr = false;
         vfSubscribe.assign(256, false);
+        nMisbehavior = 0;
 
         // Be shy and don't send version until we hear
         if (!fInbound)
@@ -282,9 +289,10 @@ public:
         nHeaderStart = vSend.size();
         vSend << CMessageHeader(pszCommand, 0);
         nMessageStart = vSend.size();
-        if (fDebug)
+        if (fDebug) {
             printf("%s ", DateTimeStrFormat("%x %H:%M:%S", GetTime()).c_str());
-        printf("sending: %s ", pszCommand);
+            printf("sending: %s ", pszCommand);
+        }
     }
 
     void AbortMessage()
@@ -295,7 +303,9 @@ public:
         nHeaderStart = -1;
         nMessageStart = -1;
         cs_vSend.Leave();
-        printf("(aborted)\n");
+
+        if (fDebug)
+            printf("(aborted)\n");
     }
 
     void EndMessage()
@@ -324,8 +334,9 @@ public:
             memcpy((char*)&vSend[nHeaderStart] + offsetof(CMessageHeader, nChecksum), &nChecksum, sizeof(nChecksum));
         }
 
-        printf("(%d bytes) ", nSize);
-        printf("\n");
+        if (fDebug) {
+            printf("(%d bytes)\n", nSize);
+        }
 
         nHeaderStart = -1;
         nMessageStart = -1;
@@ -564,6 +575,25 @@ public:
     void CancelSubscribe(unsigned int nChannel);
     void CloseSocketDisconnect();
     void Cleanup();
+
+
+    // Denial-of-service detection/prevention
+    // The idea is to detect peers that are behaving
+    // badly and disconnect/ban them, but do it in a
+    // one-coding-mistake-won't-shatter-the-entire-network
+    // way.
+    // IMPORTANT:  There should be nothing I can give a
+    // node that it will forward on that will make that
+    // node's peers drop it. If there is, an attacker
+    // can isolate a node and/or try to split the network.
+    // Dropping a node for sending stuff that is invalid
+    // now but might be valid in a later version is also
+    // dangerous, because it can cause a network split
+    // between nodes running old code and nodes running
+    // new code.
+    static void ClearBanned(); // needed for unit testing
+    static bool IsBanned(unsigned int ip);
+    bool Misbehaving(int howmuch); // 1 == a little, 100 == a lot
 };
 
 
index cbe6fa4..754c222 100644 (file)
@@ -67,4 +67,8 @@ inline void MainFrameRepaint()
 {
 }
 
+inline void InitMessage(const std::string &message)
+{
+}
+
 #endif
diff --git a/src/qt/aboutdialog.cpp b/src/qt/aboutdialog.cpp
new file mode 100644 (file)
index 0000000..13d263b
--- /dev/null
@@ -0,0 +1,26 @@
+#include "aboutdialog.h"
+#include "ui_aboutdialog.h"
+#include "clientmodel.h"
+
+AboutDialog::AboutDialog(QWidget *parent) :
+    QDialog(parent),
+    ui(new Ui::AboutDialog)
+{
+    ui->setupUi(this);
+
+}
+
+void AboutDialog::setModel(ClientModel *model)
+{
+    ui->versionLabel->setText(model->formatFullVersion());
+}
+
+AboutDialog::~AboutDialog()
+{
+    delete ui;
+}
+
+void AboutDialog::on_buttonBox_accepted()
+{
+    close();
+}
diff --git a/src/qt/aboutdialog.h b/src/qt/aboutdialog.h
new file mode 100644 (file)
index 0000000..d2caa3e
--- /dev/null
@@ -0,0 +1,27 @@
+#ifndef ABOUTDIALOG_H
+#define ABOUTDIALOG_H
+
+#include <QDialog>
+
+namespace Ui {
+    class AboutDialog;
+}
+class ClientModel;
+
+class AboutDialog : public QDialog
+{
+    Q_OBJECT
+
+public:
+    explicit AboutDialog(QWidget *parent = 0);
+    ~AboutDialog();
+
+    void setModel(ClientModel *model);
+private:
+    Ui::AboutDialog *ui;
+
+private slots:
+    void on_buttonBox_accepted();
+};
+
+#endif // ABOUTDIALOG_H
diff --git a/src/qt/addressbookpage.cpp b/src/qt/addressbookpage.cpp
new file mode 100644 (file)
index 0000000..ee64cc2
--- /dev/null
@@ -0,0 +1,215 @@
+#include "addressbookpage.h"
+#include "ui_addressbookpage.h"
+
+#include "addresstablemodel.h"
+#include "editaddressdialog.h"
+#include "csvmodelwriter.h"
+
+#include <QSortFilterProxyModel>
+#include <QClipboard>
+#include <QFileDialog>
+#include <QMessageBox>
+
+AddressBookPage::AddressBookPage(Mode mode, Tabs tab, QWidget *parent) :
+    QDialog(parent),
+    ui(new Ui::AddressBookPage),
+    model(0),
+    mode(mode),
+    tab(tab)
+{
+    ui->setupUi(this);
+    switch(mode)
+    {
+    case ForSending:
+        connect(ui->tableView, SIGNAL(doubleClicked(QModelIndex)), this, SLOT(accept()));
+        ui->tableView->setEditTriggers(QAbstractItemView::NoEditTriggers);
+        ui->tableView->setFocus();
+        break;
+    case ForEditing:
+        ui->buttonBox->hide();
+        break;
+    }
+    switch(tab)
+    {
+    case SendingTab:
+        ui->labelExplanation->hide();
+        break;
+    case ReceivingTab:
+        break;
+    }
+    ui->tableView->setTabKeyNavigation(false);
+
+    connect(ui->buttonBox, SIGNAL(accepted()), this, SLOT(accept()));
+}
+
+AddressBookPage::~AddressBookPage()
+{
+    delete ui;
+}
+
+void AddressBookPage::setModel(AddressTableModel *model)
+{
+    this->model = model;
+    // Refresh list from core
+    model->updateList();
+
+    proxyModel = new QSortFilterProxyModel(this);
+    proxyModel->setSourceModel(model);
+    proxyModel->setDynamicSortFilter(true);
+    switch(tab)
+    {
+    case ReceivingTab:
+        // Receive filter
+        proxyModel->setFilterRole(AddressTableModel::TypeRole);
+        proxyModel->setFilterFixedString(AddressTableModel::Receive);
+        break;
+    case SendingTab:
+        // Send filter
+        proxyModel->setFilterRole(AddressTableModel::TypeRole);
+        proxyModel->setFilterFixedString(AddressTableModel::Send);
+        break;
+    }
+    ui->tableView->setModel(proxyModel);
+    ui->tableView->sortByColumn(0, Qt::AscendingOrder);
+
+    // Set column widths
+    ui->tableView->horizontalHeader()->resizeSection(
+            AddressTableModel::Address, 320);
+    ui->tableView->horizontalHeader()->setResizeMode(
+            AddressTableModel::Label, QHeaderView::Stretch);
+
+    connect(ui->tableView->selectionModel(), SIGNAL(selectionChanged(QItemSelection,QItemSelection)),
+            this, SLOT(selectionChanged()));
+
+    if(mode == ForSending)
+    {
+        // Auto-select first row when in sending mode
+        ui->tableView->selectRow(0);
+    }
+    selectionChanged();
+}
+
+QTableView *AddressBookPage::getCurrentTable()
+{
+    return ui->tableView;
+}
+
+void AddressBookPage::on_copyToClipboard_clicked()
+{
+    // Copy currently selected address to clipboard
+    //   (or nothing, if nothing selected)
+    QTableView *table = getCurrentTable();
+    QModelIndexList indexes = table->selectionModel()->selectedRows(AddressTableModel::Address);
+
+    foreach (QModelIndex index, indexes)
+    {
+        QVariant address = index.data();
+        QApplication::clipboard()->setText(address.toString());
+    }
+}
+
+void AddressBookPage::on_newAddressButton_clicked()
+{
+    EditAddressDialog dlg(
+            tab == SendingTab ?
+            EditAddressDialog::NewSendingAddress :
+            EditAddressDialog::NewReceivingAddress);
+    dlg.setModel(model);
+    if(dlg.exec())
+    {
+        // Select row for newly created address
+        QString address = dlg.getAddress();
+        QModelIndexList lst = proxyModel->match(proxyModel->index(0,
+                          AddressTableModel::Address, QModelIndex()),
+                          Qt::EditRole, address, 1, Qt::MatchExactly);
+        if(!lst.isEmpty())
+        {
+            ui->tableView->setFocus();
+            ui->tableView->selectRow(lst.at(0).row());
+        }
+    }
+}
+
+void AddressBookPage::on_deleteButton_clicked()
+{
+    QTableView *table = getCurrentTable();
+    QModelIndexList indexes = table->selectionModel()->selectedRows();
+    if(!indexes.isEmpty())
+    {
+        table->model()->removeRow(indexes.at(0).row());
+    }
+}
+
+void AddressBookPage::selectionChanged()
+{
+    // Set button states based on selected tab and selection
+    QTableView *table = getCurrentTable();
+
+    if(table->selectionModel()->hasSelection())
+    {
+        switch(tab)
+        {
+        case SendingTab:
+            ui->deleteButton->setEnabled(true);
+            break;
+        case ReceivingTab:
+            ui->deleteButton->setEnabled(false);
+            break;
+        }
+        ui->copyToClipboard->setEnabled(true);
+    }
+    else
+    {
+        ui->deleteButton->setEnabled(false);
+        ui->copyToClipboard->setEnabled(false);
+    }
+}
+
+void AddressBookPage::done(int retval)
+{
+    // When this is a tab/widget and not a model dialog, ignore "done"
+    if(mode == ForEditing)
+        return;
+
+    // Figure out which address was selected, and return it
+    QTableView *table = getCurrentTable();
+    QModelIndexList indexes = table->selectionModel()->selectedRows(AddressTableModel::Address);
+
+    foreach (QModelIndex index, indexes)
+    {
+        QVariant address = table->model()->data(index);
+        returnValue = address.toString();
+    }
+
+    if(returnValue.isEmpty())
+    {
+        retval = Rejected;
+    }
+
+    QDialog::done(retval);
+}
+
+void AddressBookPage::exportClicked()
+{
+    // CSV is currently the only supported format
+    QString filename = QFileDialog::getSaveFileName(
+            this,
+            tr("Export Address Book Data"),
+            QDir::currentPath(),
+            tr("Comma separated file (*.csv)"));
+
+    if (filename.isNull()) return;
+
+    CSVModelWriter writer(filename);
+
+    // name, column, role
+    writer.setModel(proxyModel);
+    writer.addColumn("Label", AddressTableModel::Label, Qt::EditRole);
+    writer.addColumn("Address", AddressTableModel::Address, Qt::EditRole);
+
+    if(!writer.write())
+    {
+        QMessageBox::critical(this, tr("Error exporting"), tr("Could not write to file %1.").arg(filename),
+                              QMessageBox::Abort, QMessageBox::Abort);
+    }
+}
diff --git a/src/qt/addressbookpage.h b/src/qt/addressbookpage.h
new file mode 100644 (file)
index 0000000..53c7728
--- /dev/null
@@ -0,0 +1,59 @@
+#ifndef ADDRESSBOOKPAGE_H
+#define ADDRESSBOOKPAGE_H
+
+#include <QDialog>
+
+namespace Ui {
+    class AddressBookPage;
+}
+class AddressTableModel;
+
+QT_BEGIN_NAMESPACE
+class QTableView;
+class QItemSelection;
+class QSortFilterProxyModel;
+QT_END_NAMESPACE
+
+class AddressBookPage : public QDialog
+{
+    Q_OBJECT
+
+public:
+    enum Tabs {
+        SendingTab = 0,
+        ReceivingTab = 1
+    };
+
+    enum Mode {
+        ForSending, // Pick address for sending
+        ForEditing  // Open address book for editing
+    };
+
+    explicit AddressBookPage(Mode mode, Tabs tab, QWidget *parent = 0);
+    ~AddressBookPage();
+
+    void setModel(AddressTableModel *model);
+    const QString &getReturnValue() const { return returnValue; }
+
+public slots:
+    void done(int retval);
+    void exportClicked();
+
+private:
+    Ui::AddressBookPage *ui;
+    AddressTableModel *model;
+    Mode mode;
+    Tabs tab;
+    QString returnValue;
+    QSortFilterProxyModel *proxyModel;
+
+    QTableView *getCurrentTable();
+
+private slots:
+    void on_deleteButton_clicked();
+    void on_newAddressButton_clicked();
+    void on_copyToClipboard_clicked();
+    void selectionChanged();
+};
+
+#endif // ADDRESSBOOKDIALOG_H
diff --git a/src/qt/addresstablemodel.cpp b/src/qt/addresstablemodel.cpp
new file mode 100644 (file)
index 0000000..8fd6d52
--- /dev/null
@@ -0,0 +1,347 @@
+#include "addresstablemodel.h"
+#include "guiutil.h"
+#include "walletmodel.h"
+
+#include "headers.h"
+
+#include <QFont>
+#include <QColor>
+
+const QString AddressTableModel::Send = "S";
+const QString AddressTableModel::Receive = "R";
+
+struct AddressTableEntry
+{
+    enum Type {
+        Sending,
+        Receiving
+    };
+
+    Type type;
+    QString label;
+    QString address;
+
+    AddressTableEntry() {}
+    AddressTableEntry(Type type, const QString &label, const QString &address):
+        type(type), label(label), address(address) {}
+};
+
+// Private implementation
+struct AddressTablePriv
+{
+    CWallet *wallet;
+    QList<AddressTableEntry> cachedAddressTable;
+
+    AddressTablePriv(CWallet *wallet):
+            wallet(wallet) {}
+
+    void refreshAddressTable()
+    {
+        cachedAddressTable.clear();
+
+        CRITICAL_BLOCK(wallet->cs_wallet)
+        {
+            BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress, std::string)& item, wallet->mapAddressBook)
+            {
+                const CBitcoinAddress& address = item.first;
+                const std::string& strName = item.second;
+                bool fMine = wallet->HaveKey(address);
+                cachedAddressTable.append(AddressTableEntry(fMine ? AddressTableEntry::Receiving : AddressTableEntry::Sending,
+                                  QString::fromStdString(strName),
+                                  QString::fromStdString(address.ToString())));
+            }
+        }
+    }
+
+    int size()
+    {
+        return cachedAddressTable.size();
+    }
+
+    AddressTableEntry *index(int idx)
+    {
+        if(idx >= 0 && idx < cachedAddressTable.size())
+        {
+            return &cachedAddressTable[idx];
+        }
+        else
+        {
+            return 0;
+        }
+    }
+};
+
+AddressTableModel::AddressTableModel(CWallet *wallet, WalletModel *parent) :
+    QAbstractTableModel(parent),walletModel(parent),wallet(wallet),priv(0)
+{
+    columns << tr("Label") << tr("Address");
+    priv = new AddressTablePriv(wallet);
+    priv->refreshAddressTable();
+}
+
+AddressTableModel::~AddressTableModel()
+{
+    delete priv;
+}
+
+int AddressTableModel::rowCount(const QModelIndex &parent) const
+{
+    Q_UNUSED(parent);
+    return priv->size();
+}
+
+int AddressTableModel::columnCount(const QModelIndex &parent) const
+{
+    Q_UNUSED(parent);
+    return columns.length();
+}
+
+QVariant AddressTableModel::data(const QModelIndex &index, int role) const
+{
+    if(!index.isValid())
+        return QVariant();
+
+    AddressTableEntry *rec = static_cast<AddressTableEntry*>(index.internalPointer());
+
+    if(role == Qt::DisplayRole || role == Qt::EditRole)
+    {
+        switch(index.column())
+        {
+        case Label:
+            if(rec->label.isEmpty() && role == Qt::DisplayRole)
+            {
+                return tr("(no label)");
+            }
+            else
+            {
+                return rec->label;
+            }
+        case Address:
+            return rec->address;
+        }
+    }
+    else if (role == Qt::FontRole)
+    {
+        QFont font;
+        if(index.column() == Address)
+        {
+            font = GUIUtil::bitcoinAddressFont();
+        }
+        return font;
+    }
+    else if (role == TypeRole)
+    {
+        switch(rec->type)
+        {
+        case AddressTableEntry::Sending:
+            return Send;
+        case AddressTableEntry::Receiving:
+            return Receive;
+        default: break;
+        }
+    }
+    return QVariant();
+}
+
+bool AddressTableModel::setData(const QModelIndex & index, const QVariant & value, int role)
+{
+    if(!index.isValid())
+        return false;
+    AddressTableEntry *rec = static_cast<AddressTableEntry*>(index.internalPointer());
+
+    editStatus = OK;
+
+    if(role == Qt::EditRole)
+    {
+        switch(index.column())
+        {
+        case Label:
+            wallet->SetAddressBookName(rec->address.toStdString(), value.toString().toStdString());
+            rec->label = value.toString();
+            break;
+        case Address:
+            // Refuse to set invalid address, set error status and return false
+            if(!walletModel->validateAddress(value.toString()))
+            {
+                editStatus = INVALID_ADDRESS;
+                return false;
+            }
+            // Double-check that we're not overwriting a receiving address
+            if(rec->type == AddressTableEntry::Sending)
+            {
+                CRITICAL_BLOCK(wallet->cs_wallet)
+                {
+                    // Remove old entry
+                    wallet->DelAddressBookName(rec->address.toStdString());
+                    // Add new entry with new address
+                    wallet->SetAddressBookName(value.toString().toStdString(), rec->label.toStdString());
+                }
+
+                rec->address = value.toString();
+            }
+            break;
+        }
+        emit dataChanged(index, index);
+
+        return true;
+    }
+    return false;
+}
+
+QVariant AddressTableModel::headerData(int section, Qt::Orientation orientation, int role) const
+{
+    if(orientation == Qt::Horizontal)
+    {
+        if(role == Qt::DisplayRole)
+        {
+            return columns[section];
+        }
+    }
+    return QVariant();
+}
+
+Qt::ItemFlags AddressTableModel::flags(const QModelIndex & index) const
+{
+    if(!index.isValid())
+        return 0;
+    AddressTableEntry *rec = static_cast<AddressTableEntry*>(index.internalPointer());
+
+    Qt::ItemFlags retval = Qt::ItemIsSelectable | Qt::ItemIsEnabled;
+    // Can edit address and label for sending addresses,
+    // and only label for receiving addresses.
+    if(rec->type == AddressTableEntry::Sending ||
+      (rec->type == AddressTableEntry::Receiving && index.column()==Label))
+    {
+        retval |= Qt::ItemIsEditable;
+    }
+    return retval;
+}
+
+QModelIndex AddressTableModel::index(int row, int column, const QModelIndex & parent) const
+{
+    Q_UNUSED(parent);
+    AddressTableEntry *data = priv->index(row);
+    if(data)
+    {
+        return createIndex(row, column, priv->index(row));
+    }
+    else
+    {
+        return QModelIndex();
+    }
+}
+
+void AddressTableModel::updateList()
+{
+    // Update address book model from Bitcoin core
+    beginResetModel();
+    priv->refreshAddressTable();
+    endResetModel();
+}
+
+QString AddressTableModel::addRow(const QString &type, const QString &label, const QString &address)
+{
+    std::string strLabel = label.toStdString();
+    std::string strAddress = address.toStdString();
+
+    editStatus = OK;
+
+    if(type == Send)
+    {
+        if(!walletModel->validateAddress(address))
+        {
+            editStatus = INVALID_ADDRESS;
+            return QString();
+        }
+        // Check for duplicate addresses
+        CRITICAL_BLOCK(wallet->cs_wallet)
+        {
+            if(wallet->mapAddressBook.count(strAddress))
+            {
+                editStatus = DUPLICATE_ADDRESS;
+                return QString();
+            }
+        }
+    }
+    else if(type == Receive)
+    {
+        // Generate a new address to associate with given label
+        WalletModel::UnlockContext ctx(walletModel->requestUnlock());
+        if(!ctx.isValid())
+        {
+            // Unlock wallet failed or was cancelled
+            editStatus = WALLET_UNLOCK_FAILURE;
+            return QString();
+        }
+        std::vector<unsigned char> newKey;
+        if(!wallet->GetKeyFromPool(newKey, true))
+        {
+            editStatus = KEY_GENERATION_FAILURE;
+            return QString();
+        }
+        strAddress = CBitcoinAddress(newKey).ToString();
+    }
+    else
+    {
+        return QString();
+    }
+    // Add entry and update list
+    CRITICAL_BLOCK(wallet->cs_wallet)
+        wallet->SetAddressBookName(strAddress, strLabel);
+    updateList();
+    return QString::fromStdString(strAddress);
+}
+
+bool AddressTableModel::removeRows(int row, int count, const QModelIndex & parent)
+{
+    Q_UNUSED(parent);
+    AddressTableEntry *rec = priv->index(row);
+    if(count != 1 || !rec || rec->type == AddressTableEntry::Receiving)
+    {
+        // Can only remove one row at a time, and cannot remove rows not in model.
+        // Also refuse to remove receiving addresses.
+        return false;
+    }
+    CRITICAL_BLOCK(wallet->cs_wallet)
+    {
+        wallet->DelAddressBookName(rec->address.toStdString());
+    }
+    updateList();
+    return true;
+}
+
+void AddressTableModel::update()
+{
+
+}
+
+/* Look up label for address in address book, if not found return empty string.
+ */
+QString AddressTableModel::labelForAddress(const QString &address) const
+{
+    CRITICAL_BLOCK(wallet->cs_wallet)
+    {
+        CBitcoinAddress address_parsed(address.toStdString());
+        std::map<CBitcoinAddress, std::string>::iterator mi = wallet->mapAddressBook.find(address_parsed);
+        if (mi != wallet->mapAddressBook.end())
+        {
+            return QString::fromStdString(mi->second);
+        }
+    }
+    return QString();
+}
+
+int AddressTableModel::lookupAddress(const QString &address) const
+{
+    QModelIndexList lst = match(index(0, Address, QModelIndex()),
+                                Qt::EditRole, address, 1, Qt::MatchExactly);
+    if(lst.isEmpty())
+    {
+        return -1;
+    }
+    else
+    {
+        return lst.at(0).row();
+    }
+}
+
diff --git a/src/qt/addresstablemodel.h b/src/qt/addresstablemodel.h
new file mode 100644 (file)
index 0000000..f4a8dad
--- /dev/null
@@ -0,0 +1,83 @@
+#ifndef ADDRESSTABLEMODEL_H
+#define ADDRESSTABLEMODEL_H
+
+#include <QAbstractTableModel>
+#include <QStringList>
+
+class AddressTablePriv;
+class CWallet;
+class WalletModel;
+
+class AddressTableModel : public QAbstractTableModel
+{
+    Q_OBJECT
+public:
+    explicit AddressTableModel(CWallet *wallet, WalletModel *parent = 0);
+    ~AddressTableModel();
+
+    enum ColumnIndex {
+        Label = 0,   /* User specified label */
+        Address = 1  /* Bitcoin address */
+    };
+
+    enum RoleIndex {
+        TypeRole = Qt::UserRole
+    };
+
+    // Return status of last edit/insert operation
+    enum EditStatus {
+        OK,
+        INVALID_ADDRESS,
+        DUPLICATE_ADDRESS,
+        WALLET_UNLOCK_FAILURE,
+        KEY_GENERATION_FAILURE
+    };
+
+    static const QString Send; /* Send addres */
+    static const QString Receive; /* Receive address */
+
+    /* Overridden methods from QAbstractTableModel */
+    int rowCount(const QModelIndex &parent) const;
+    int columnCount(const QModelIndex &parent) const;
+    QVariant data(const QModelIndex &index, int role) const;
+    bool setData(const QModelIndex & index, const QVariant & value, int role);
+    QVariant headerData(int section, Qt::Orientation orientation, int role) const;
+    QModelIndex index(int row, int column, const QModelIndex & parent) const;
+    bool removeRows(int row, int count, const QModelIndex & parent = QModelIndex());
+    Qt::ItemFlags flags(const QModelIndex & index) const;
+
+    /* Add an address to the model.
+       Returns the added address on success, and an empty string otherwise.
+     */
+    QString addRow(const QString &type, const QString &label, const QString &address);
+
+    /* Update address list from core. Invalidates any indices.
+     */
+    void updateList();
+
+    /* Look up label for address in address book, if not found return empty string.
+     */
+    QString labelForAddress(const QString &address) const;
+
+    /* Look up row index of an address in the model.
+       Return -1 if not found.
+     */
+    int lookupAddress(const QString &address) const;
+
+    EditStatus getEditStatus() const { return editStatus; }
+
+private:
+    WalletModel *walletModel;
+    CWallet *wallet;
+    AddressTablePriv *priv;
+    QStringList columns;
+    EditStatus editStatus;
+
+signals:
+    void defaultAddressChanged(const QString &address);
+
+public slots:
+    void update();
+};
+
+#endif // ADDRESSTABLEMODEL_H
diff --git a/src/qt/askpassphrasedialog.cpp b/src/qt/askpassphrasedialog.cpp
new file mode 100644 (file)
index 0000000..a297513
--- /dev/null
@@ -0,0 +1,186 @@
+#include "askpassphrasedialog.h"
+#include "ui_askpassphrasedialog.h"
+
+#include "guiconstants.h"
+#include "walletmodel.h"
+
+#include <QMessageBox>
+#include <QPushButton>
+
+AskPassphraseDialog::AskPassphraseDialog(Mode mode, QWidget *parent) :
+    QDialog(parent),
+    ui(new Ui::AskPassphraseDialog),
+    mode(mode),
+    model(0)
+{
+    ui->setupUi(this);
+    ui->passEdit1->setMaxLength(MAX_PASSPHRASE_SIZE);
+    ui->passEdit2->setMaxLength(MAX_PASSPHRASE_SIZE);
+    ui->passEdit3->setMaxLength(MAX_PASSPHRASE_SIZE);
+
+    switch(mode)
+    {
+        case Encrypt: // Ask passphrase x2
+            ui->passLabel1->hide();
+            ui->passEdit1->hide();
+            ui->warningLabel->setText(tr("Enter the new passphrase to the wallet.<br/>Please use a passphrase of <b>10 or more random characters</b>, or <b>eight or more words</b>."));
+            setWindowTitle(tr("Encrypt wallet"));
+            break;
+        case Unlock: // Ask passphrase
+            ui->warningLabel->setText(tr("This operation needs your wallet passphrase to unlock the wallet."));
+            ui->passLabel2->hide();
+            ui->passEdit2->hide();
+            ui->passLabel3->hide();
+            ui->passEdit3->hide();
+            setWindowTitle(tr("Unlock wallet"));
+            break;
+        case Decrypt:   // Ask passphrase
+            ui->warningLabel->setText(tr("This operation needs your wallet passphrase to decrypt the wallet."));
+            ui->passLabel2->hide();
+            ui->passEdit2->hide();
+            ui->passLabel3->hide();
+            ui->passEdit3->hide();
+            setWindowTitle(tr("Decrypt wallet"));
+            break;
+        case ChangePass: // Ask old passphrase + new passphrase x2
+            setWindowTitle(tr("Change passphrase"));
+            ui->warningLabel->setText(tr("Enter the old and new passphrase to the wallet."));
+            break;
+    }
+    resize(minimumSize()); // Get rid of extra space in dialog
+
+    textChanged();
+    connect(ui->passEdit1, SIGNAL(textChanged(QString)), this, SLOT(textChanged()));
+    connect(ui->passEdit2, SIGNAL(textChanged(QString)), this, SLOT(textChanged()));
+    connect(ui->passEdit3, SIGNAL(textChanged(QString)), this, SLOT(textChanged()));
+}
+
+AskPassphraseDialog::~AskPassphraseDialog()
+{
+    // Attempt to overwrite text so that they do not linger around in memory
+    ui->passEdit1->setText(QString(" ").repeated(ui->passEdit1->text().size()));
+    ui->passEdit2->setText(QString(" ").repeated(ui->passEdit2->text().size()));
+    ui->passEdit3->setText(QString(" ").repeated(ui->passEdit3->text().size()));
+    delete ui;
+}
+
+void AskPassphraseDialog::setModel(WalletModel *model)
+{
+    this->model = model;
+}
+
+void AskPassphraseDialog::accept()
+{
+    std::string oldpass, newpass1, newpass2;
+    // TODO: mlock memory / munlock on return so they will not be swapped out, really need "mlockedstring" wrapper class to do this safely
+    oldpass.reserve(MAX_PASSPHRASE_SIZE);
+    newpass1.reserve(MAX_PASSPHRASE_SIZE);
+    newpass2.reserve(MAX_PASSPHRASE_SIZE);
+    oldpass.assign(ui->passEdit1->text().toStdString());
+    newpass1.assign(ui->passEdit2->text().toStdString());
+    newpass2.assign(ui->passEdit3->text().toStdString());
+
+    switch(mode)
+    {
+    case Encrypt: {
+        if(newpass1.empty() || newpass2.empty())
+        {
+            // Cannot encrypt with empty passphrase
+            break;
+        }
+        QMessageBox::StandardButton retval = QMessageBox::question(this, tr("Confirm wallet encryption"),
+                 tr("WARNING: If you encrypt your wallet and lose your passphrase, you will <b>LOSE ALL OF YOUR BITCOINS</b>!\nAre you sure you wish to encrypt your wallet?"),
+                 QMessageBox::Yes|QMessageBox::Cancel,
+                 QMessageBox::Cancel);
+        if(retval == QMessageBox::Yes)
+        {
+            if(newpass1 == newpass2)
+            {
+                if(model->setWalletEncrypted(true, newpass1))
+                {
+                    QMessageBox::warning(this, tr("Wallet encrypted"),
+                                         tr("Remember that encrypting your wallet cannot fully protect your bitcoins from being stolen by malware infecting your computer."));
+                }
+                else
+                {
+                    QMessageBox::critical(this, tr("Wallet encryption failed"),
+                                         tr("Wallet encryption failed due to an internal error. Your wallet was not encrypted."));
+                }
+                QDialog::accept(); // Success
+            }
+            else
+            {
+                QMessageBox::critical(this, tr("Wallet encryption failed"),
+                                     tr("The supplied passphrases do not match."));
+            }
+        }
+        else
+        {
+            QDialog::reject(); // Cancelled
+        }
+        } break;
+    case Unlock:
+        if(!model->setWalletLocked(false, oldpass))
+        {
+            QMessageBox::critical(this, tr("Wallet unlock failed"),
+                                  tr("The passphrase entered for the wallet decryption was incorrect."));
+        }
+        else
+        {
+            QDialog::accept(); // Success
+        }
+        break;
+    case Decrypt:
+        if(!model->setWalletEncrypted(false, oldpass))
+        {
+            QMessageBox::critical(this, tr("Wallet decryption failed"),
+                                  tr("The passphrase entered for the wallet decryption was incorrect."));
+        }
+        else
+        {
+            QDialog::accept(); // Success
+        }
+        break;
+    case ChangePass:
+        if(newpass1 == newpass2)
+        {
+            if(model->changePassphrase(oldpass, newpass1))
+            {
+                QMessageBox::information(this, tr("Wallet encrypted"),
+                                     tr("Wallet passphrase was succesfully changed."));
+                QDialog::accept(); // Success
+            }
+            else
+            {
+                QMessageBox::critical(this, tr("Wallet encryption failed"),
+                                     tr("The passphrase entered for the wallet decryption was incorrect."));
+            }
+        }
+        else
+        {
+            QMessageBox::critical(this, tr("Wallet encryption failed"),
+                                 tr("The supplied passphrases do not match."));
+        }
+        break;
+    }
+}
+
+void AskPassphraseDialog::textChanged()
+{
+    // Validate input, set Ok button to enabled when accepable
+    bool acceptable = false;
+    switch(mode)
+    {
+    case Encrypt: // New passphrase x2
+        acceptable = !ui->passEdit2->text().isEmpty() && !ui->passEdit3->text().isEmpty();
+        break;
+    case Unlock: // Old passphrase x1
+    case Decrypt:
+        acceptable = !ui->passEdit1->text().isEmpty();
+        break;
+    case ChangePass: // Old passphrase x1, new passphrase x2
+        acceptable = !ui->passEdit1->text().isEmpty() && !ui->passEdit2->text().isEmpty() && !ui->passEdit3->text().isEmpty();
+        break;
+    }
+    ui->buttonBox->button(QDialogButtonBox::Ok)->setEnabled(acceptable);
+}
diff --git a/src/qt/askpassphrasedialog.h b/src/qt/askpassphrasedialog.h
new file mode 100644 (file)
index 0000000..761612c
--- /dev/null
@@ -0,0 +1,40 @@
+#ifndef ASKPASSPHRASEDIALOG_H
+#define ASKPASSPHRASEDIALOG_H
+
+#include <QDialog>
+
+namespace Ui {
+    class AskPassphraseDialog;
+}
+
+class WalletModel;
+
+class AskPassphraseDialog : public QDialog
+{
+    Q_OBJECT
+
+public:
+    enum Mode {
+        Encrypt,    // Ask passphrase x2
+        Unlock,     // Ask passphrase
+        ChangePass, // Ask old passphrase + new passphrase x2
+        Decrypt   // Ask passphrase
+    };
+
+    explicit AskPassphraseDialog(Mode mode, QWidget *parent = 0);
+    ~AskPassphraseDialog();
+
+    void accept();
+
+    void setModel(WalletModel *model);
+
+private:
+    Ui::AskPassphraseDialog *ui;
+    Mode mode;
+    WalletModel *model;
+
+private slots:
+    void textChanged();
+};
+
+#endif // ASKPASSPHRASEDIALOG_H
diff --git a/src/qt/bitcoin.cpp b/src/qt/bitcoin.cpp
new file mode 100644 (file)
index 0000000..daba512
--- /dev/null
@@ -0,0 +1,170 @@
+/*
+ * W.J. van der Laan 2011
+ */
+#include "bitcoingui.h"
+#include "clientmodel.h"
+#include "walletmodel.h"
+#include "optionsmodel.h"
+
+#include "headers.h"
+#include "init.h"
+
+#include <QApplication>
+#include <QMessageBox>
+#include <QThread>
+#include <QTextCodec>
+#include <QLocale>
+#include <QTranslator>
+#include <QSplashScreen>
+
+// Need a global reference for the notifications to find the GUI
+BitcoinGUI *guiref;
+QSplashScreen *splashref;
+
+int MyMessageBox(const std::string& message, const std::string& caption, int style, wxWindow* parent, int x, int y)
+{
+    // Message from main thread
+    if(guiref)
+    {
+        guiref->error(QString::fromStdString(caption),
+                      QString::fromStdString(message));
+    }
+    else
+    {
+        QMessageBox::critical(0, QString::fromStdString(caption),
+            QString::fromStdString(message),
+            QMessageBox::Ok, QMessageBox::Ok);
+    }
+    return 4;
+}
+
+int ThreadSafeMessageBox(const std::string& message, const std::string& caption, int style, wxWindow* parent, int x, int y)
+{
+    // Message from network thread
+    if(guiref)
+    {
+        QMetaObject::invokeMethod(guiref, "error", Qt::QueuedConnection,
+                                   Q_ARG(QString, QString::fromStdString(caption)),
+                                   Q_ARG(QString, QString::fromStdString(message)));
+    }
+    else
+    {
+        printf("%s: %s\n", caption.c_str(), message.c_str());
+        fprintf(stderr, "%s: %s\n", caption.c_str(), message.c_str());
+    }
+    return 4;
+}
+
+bool ThreadSafeAskFee(int64 nFeeRequired, const std::string& strCaption, wxWindow* parent)
+{
+    if(!guiref)
+        return false;
+    if(nFeeRequired < MIN_TX_FEE || nFeeRequired <= nTransactionFee || fDaemon)
+        return true;
+    bool payFee = false;
+
+    // Call slot on GUI thread.
+    // If called from another thread, use a blocking QueuedConnection.
+    Qt::ConnectionType connectionType = Qt::DirectConnection;
+    if(QThread::currentThread() != QCoreApplication::instance()->thread())
+    {
+        connectionType = Qt::BlockingQueuedConnection;
+    }
+
+    QMetaObject::invokeMethod(guiref, "askFee", connectionType,
+                               Q_ARG(qint64, nFeeRequired),
+                               Q_ARG(bool*, &payFee));
+
+    return payFee;
+}
+
+void CalledSetStatusBar(const std::string& strText, int nField)
+{
+    // Only used for built-in mining, which is disabled, simple ignore
+}
+
+void UIThreadCall(boost::function0<void> fn)
+{
+    // Only used for built-in mining, which is disabled, simple ignore
+}
+
+void MainFrameRepaint()
+{
+}
+
+void InitMessage(const std::string &message)
+{
+    if(splashref)
+    {
+        splashref->showMessage(QString::fromStdString(message), Qt::AlignBottom|Qt::AlignHCenter, QColor(255,255,200));
+        QApplication::instance()->processEvents();
+    }
+}
+
+/*
+   Translate string to current locale using Qt.
+ */
+std::string _(const char* psz)
+{
+    return QCoreApplication::translate("bitcoin-core", psz).toStdString();
+}
+
+int main(int argc, char *argv[])
+{
+    QTextCodec::setCodecForTr(QTextCodec::codecForName("UTF-8"));
+    QTextCodec::setCodecForCStrings(QTextCodec::codecForTr());
+
+    Q_INIT_RESOURCE(bitcoin);
+    QApplication app(argc, argv);
+
+    // Load language file for system locale
+    QString locale = QLocale::system().name();
+    QTranslator translator;
+    translator.load("bitcoin_"+locale);
+    app.installTranslator(&translator);
+
+    QSplashScreen splash(QPixmap(":/images/splash"), 0);
+    splash.show();
+    splash.setAutoFillBackground(true);
+    splashref = &splash;
+
+    app.processEvents();
+
+    app.setQuitOnLastWindowClosed(false);
+
+    try
+    {
+        if(AppInit2(argc, argv))
+        {
+            {
+                // Put this in a block, so that BitcoinGUI is cleaned up properly before
+                // calling Shutdown().
+                BitcoinGUI window;
+                splash.finish(&window);
+                OptionsModel optionsModel(pwalletMain);
+                ClientModel clientModel(&optionsModel);
+                WalletModel walletModel(pwalletMain, &optionsModel);
+
+                guiref = &window;
+                window.setClientModel(&clientModel);
+                window.setWalletModel(&walletModel);
+
+                window.show();
+
+                app.exec();
+
+                guiref = 0;
+            }
+            Shutdown(NULL);
+        }
+        else
+        {
+            return 1;
+        }
+    } catch (std::exception& e) {
+        PrintException(&e, "Runaway exception");
+    } catch (...) {
+        PrintException(NULL, "Runaway exception");
+    }
+    return 0;
+}
diff --git a/src/qt/bitcoin.qrc b/src/qt/bitcoin.qrc
new file mode 100644 (file)
index 0000000..be0e4dc
--- /dev/null
@@ -0,0 +1,48 @@
+<RCC>
+    <qresource prefix="/icons" lang="edit">
+        <file alias="bitcoin">res/icons/bitcoin.png</file>
+        <file alias="address-book">res/icons/address-book.png</file>
+        <file alias="quit">res/icons/quit.png</file>
+        <file alias="send">res/icons/send.png</file>
+        <file alias="toolbar">res/icons/toolbar.png</file>
+        <file alias="connect_0">res/icons/connect0_16.png</file>
+        <file alias="connect_1">res/icons/connect1_16.png</file>
+        <file alias="connect_2">res/icons/connect2_16.png</file>
+        <file alias="connect_3">res/icons/connect3_16.png</file>
+        <file alias="connect_4">res/icons/connect4_16.png</file>
+        <file alias="transaction_0">res/icons/transaction0.png</file>
+        <file alias="transaction_confirmed">res/icons/transaction2.png</file>
+        <file alias="transaction_1">res/icons/clock1.png</file>
+        <file alias="transaction_2">res/icons/clock2.png</file>
+        <file alias="transaction_3">res/icons/clock3.png</file>
+        <file alias="transaction_4">res/icons/clock4.png</file>
+        <file alias="transaction_5">res/icons/clock5.png</file>
+        <file alias="options">res/icons/configure.png</file>
+        <file alias="receiving_addresses">res/icons/receive.png</file>
+        <file alias="editpaste">res/icons/editpaste.png</file>
+        <file alias="editcopy">res/icons/editcopy.png</file>
+        <file alias="add">res/icons/add.png</file>
+        <file alias="bitcoin_testnet">res/icons/bitcoin_testnet.png</file>
+        <file alias="toolbar_testnet">res/icons/toolbar_testnet.png</file>
+        <file alias="edit">res/icons/edit.png</file>
+        <file alias="history">res/icons/history.png</file>
+        <file alias="overview">res/icons/overview.png</file>
+        <file alias="export">res/icons/export.png</file>
+        <file alias="synced">res/icons/synced.png</file>
+        <file alias="remove">res/icons/remove.png</file>
+        <file alias="tx_mined">res/icons/tx_mined.png</file>
+        <file alias="tx_input">res/icons/tx_input.png</file>
+        <file alias="tx_output">res/icons/tx_output.png</file>
+        <file alias="tx_inout">res/icons/tx_inout.png</file>
+        <file alias="lock_closed">res/icons/lock_closed.png</file>
+        <file alias="lock_open">res/icons/lock_open.png</file>
+        <file alias="key">res/icons/key.png</file>
+    </qresource>
+    <qresource prefix="/images">
+        <file alias="about">res/images/about.png</file>
+        <file alias="splash">res/images/splash2.jpg</file>
+    </qresource>
+    <qresource prefix="/movies">
+        <file alias="update_spinner">res/movies/update_spinner.mng</file>
+    </qresource>
+</RCC>
diff --git a/src/qt/bitcoinaddressvalidator.cpp b/src/qt/bitcoinaddressvalidator.cpp
new file mode 100644 (file)
index 0000000..3738778
--- /dev/null
@@ -0,0 +1,67 @@
+#include "bitcoinaddressvalidator.h"
+
+/* Base58 characters are:
+     "123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"
+
+  This is:
+  - All numbers except for '0'
+  - All uppercase letters except for 'I' and 'O'
+  - All lowercase letters except for 'l'
+
+  User friendly Base58 input can map
+  - 'l' and 'I' to '1'
+  - '0' and 'O' to 'o'
+*/
+
+BitcoinAddressValidator::BitcoinAddressValidator(QObject *parent) :
+    QValidator(parent)
+{
+}
+
+QValidator::State BitcoinAddressValidator::validate(QString &input, int &pos) const
+{
+    // Correction
+    for(int idx=0; idx<input.size(); ++idx)
+    {
+        switch(input.at(idx).unicode())
+        {
+        case 'l':
+        case 'I':
+            input[idx] = QChar('1');
+            break;
+        case '0':
+        case 'O':
+            input[idx] = QChar('o');
+            break;
+        default:
+            break;
+        }
+    }
+
+    // Validation
+    QValidator::State state = QValidator::Acceptable;
+    for(int idx=0; idx<input.size(); ++idx)
+    {
+        int ch = input.at(idx).unicode();
+
+        if(((ch >= '0' && ch<='9') ||
+           (ch >= 'a' && ch<='z') ||
+           (ch >= 'A' && ch<='Z')) &&
+           ch != 'l' && ch != 'I' && ch != '0' && ch != 'O')
+        {
+            // Alphanumeric and not a 'forbidden' character
+        }
+        else
+        {
+            state = QValidator::Invalid;
+        }
+    }
+
+    // Empty address is "intermediate" input
+    if(input.isEmpty())
+    {
+        state = QValidator::Intermediate;
+    }
+
+    return state;
+}
diff --git a/src/qt/bitcoinaddressvalidator.h b/src/qt/bitcoinaddressvalidator.h
new file mode 100644 (file)
index 0000000..73f6ea1
--- /dev/null
@@ -0,0 +1,24 @@
+#ifndef BITCOINADDRESSVALIDATOR_H
+#define BITCOINADDRESSVALIDATOR_H
+
+#include <QRegExpValidator>
+
+/* Base48 entry widget validator.
+   Corrects near-miss characters and refuses characters that are no part of base48.
+ */
+class BitcoinAddressValidator : public QValidator
+{
+    Q_OBJECT
+public:
+    explicit BitcoinAddressValidator(QObject *parent = 0);
+
+    State validate(QString &input, int &pos) const;
+
+    static const int MaxAddressLength = 34;
+signals:
+
+public slots:
+
+};
+
+#endif // BITCOINADDRESSVALIDATOR_H
diff --git a/src/qt/bitcoinamountfield.cpp b/src/qt/bitcoinamountfield.cpp
new file mode 100644 (file)
index 0000000..f1edc62
--- /dev/null
@@ -0,0 +1,178 @@
+#include "bitcoinamountfield.h"
+#include "qvalidatedlineedit.h"
+#include "qvaluecombobox.h"
+#include "bitcoinunits.h"
+
+#include <QLabel>
+#include <QLineEdit>
+#include <QRegExpValidator>
+#include <QHBoxLayout>
+#include <QKeyEvent>
+#include <QComboBox>
+
+BitcoinAmountField::BitcoinAmountField(QWidget *parent):
+        QWidget(parent), amount(0), decimals(0), currentUnit(-1)
+{
+    amount = new QValidatedLineEdit(this);
+    amount->setValidator(new QRegExpValidator(QRegExp("[0-9]*"), this));
+    amount->setAlignment(Qt::AlignRight|Qt::AlignVCenter);
+    amount->installEventFilter(this);
+    amount->setMaximumWidth(75);
+    decimals = new QValidatedLineEdit(this);
+    decimals->setValidator(new QRegExpValidator(QRegExp("[0-9]+"), this));
+    decimals->setAlignment(Qt::AlignLeft|Qt::AlignVCenter);
+    decimals->setMaximumWidth(75);
+
+    QHBoxLayout *layout = new QHBoxLayout(this);
+    layout->setSpacing(0);
+    layout->addWidget(amount);
+    layout->addWidget(new QLabel(QString("<b>.</b>")));
+    layout->addWidget(decimals);
+    unit = new QValueComboBox(this);
+    unit->setModel(new BitcoinUnits(this));
+    layout->addWidget(unit);
+    layout->addStretch(1);
+    layout->setContentsMargins(0,0,0,0);
+
+    setLayout(layout);
+
+    setFocusPolicy(Qt::TabFocus);
+    setFocusProxy(amount);
+
+    // If one if the widgets changes, the combined content changes as well
+    connect(amount, SIGNAL(textChanged(QString)), this, SIGNAL(textChanged()));
+    connect(decimals, SIGNAL(textChanged(QString)), this, SIGNAL(textChanged()));
+    connect(unit, SIGNAL(currentIndexChanged(int)), this, SLOT(unitChanged(int)));
+
+    // Set default based on configuration
+    unitChanged(unit->currentIndex());
+}
+
+void BitcoinAmountField::setText(const QString &text)
+{
+    const QStringList parts = text.split(QString("."));
+    if(parts.size() == 2)
+    {
+        amount->setText(parts[0]);
+        decimals->setText(parts[1]);
+    }
+    else
+    {
+        amount->setText(QString());
+        decimals->setText(QString());
+    }
+}
+
+void BitcoinAmountField::clear()
+{
+    amount->clear();
+    decimals->clear();
+    unit->setCurrentIndex(0);
+}
+
+bool BitcoinAmountField::validate()
+{
+    bool valid = true;
+    if(decimals->text().isEmpty())
+    {
+        decimals->setValid(false);
+        valid = false;
+    }
+    if(!BitcoinUnits::parse(currentUnit, text(), 0))
+    {
+        setValid(false);
+        valid = false;
+    }
+
+    return valid;
+}
+
+void BitcoinAmountField::setValid(bool valid)
+{
+    amount->setValid(valid);
+    decimals->setValid(valid);
+}
+
+QString BitcoinAmountField::text() const
+{
+    if(decimals->text().isEmpty() && amount->text().isEmpty())
+    {
+        return QString();
+    }
+    return amount->text() + QString(".") + decimals->text();
+}
+
+// Intercept '.' and ',' keys, if pressed focus a specified widget
+bool BitcoinAmountField::eventFilter(QObject *object, QEvent *event)
+{
+    Q_UNUSED(object);
+    if(event->type() == QEvent::KeyPress)
+    {
+        QKeyEvent *keyEvent = static_cast<QKeyEvent *>(event);
+        if(keyEvent->key() == Qt::Key_Period || keyEvent->key() == Qt::Key_Comma)
+        {
+            decimals->setFocus();
+            decimals->selectAll();
+        }
+    }
+    return false;
+}
+
+QWidget *BitcoinAmountField::setupTabChain(QWidget *prev)
+{
+    QWidget::setTabOrder(prev, amount);
+    QWidget::setTabOrder(amount, decimals);
+    return decimals;
+}
+
+qint64 BitcoinAmountField::value(bool *valid_out) const
+{
+    qint64 val_out = 0;
+    bool valid = BitcoinUnits::parse(currentUnit, text(), &val_out);
+    if(valid_out)
+    {
+        *valid_out = valid;
+    }
+    return val_out;
+}
+
+void BitcoinAmountField::setValue(qint64 value)
+{
+    setText(BitcoinUnits::format(currentUnit, value));
+}
+
+void BitcoinAmountField::unitChanged(int idx)
+{
+    // Use description tooltip for current unit for the combobox
+    unit->setToolTip(unit->itemData(idx, Qt::ToolTipRole).toString());
+
+    // Determine new unit ID
+    int newUnit = unit->itemData(idx, BitcoinUnits::UnitRole).toInt();
+
+    // Parse current value and convert to new unit
+    bool valid = false;
+    qint64 currentValue = value(&valid);
+
+    currentUnit = newUnit;
+
+    // Set max length after retrieving the value, to prevent truncation
+    amount->setMaxLength(BitcoinUnits::amountDigits(currentUnit));
+    decimals->setMaxLength(BitcoinUnits::decimals(currentUnit));
+
+    if(valid)
+    {
+        // If value was valid, re-place it in the widget with the new unit
+        setValue(currentValue);
+    }
+    else
+    {
+        // If current value is invalid, just clear field
+        setText("");
+    }
+    setValid(true);
+}
+
+void BitcoinAmountField::setDisplayUnit(int newUnit)
+{
+    unit->setValue(newUnit);
+}
diff --git a/src/qt/bitcoinamountfield.h b/src/qt/bitcoinamountfield.h
new file mode 100644 (file)
index 0000000..cc92159
--- /dev/null
@@ -0,0 +1,59 @@
+#ifndef BITCOINFIELD_H
+#define BITCOINFIELD_H
+
+#include <QWidget>
+
+QT_BEGIN_NAMESPACE
+class QValidatedLineEdit;
+class QValueComboBox;
+QT_END_NAMESPACE
+
+// Coin amount entry widget with separate parts for whole
+// coins and decimals.
+class BitcoinAmountField: public QWidget
+{
+    Q_OBJECT
+    Q_PROPERTY(qint64 value READ value WRITE setValue NOTIFY textChanged USER true);
+public:
+    explicit BitcoinAmountField(QWidget *parent = 0);
+
+    qint64 value(bool *valid=0) const;
+    void setValue(qint64 value);
+
+    // Mark current valid as invalid in UI
+    void setValid(bool valid);
+    bool validate();
+
+    // Change current unit
+    void setDisplayUnit(int unit);
+
+    // Make field empty and ready for new input
+    void clear();
+
+    // Qt messes up the tab chain by default in some cases (issue http://bugreports.qt.nokia.com/browse/QTBUG-10907)
+    // Hence we have to set it up manually
+    QWidget *setupTabChain(QWidget *prev);
+
+signals:
+    void textChanged();
+
+protected:
+    // Intercept '.' and ',' keys, if pressed focus a specified widget
+    bool eventFilter(QObject *object, QEvent *event);
+
+private:
+    QValidatedLineEdit *amount;
+    QValidatedLineEdit *decimals;
+    QValueComboBox *unit;
+    int currentUnit;
+
+    void setText(const QString &text);
+    QString text() const;
+
+private slots:
+    void unitChanged(int idx);
+
+};
+
+
+#endif // BITCOINFIELD_H
diff --git a/src/qt/bitcoingui.cpp b/src/qt/bitcoingui.cpp
new file mode 100644 (file)
index 0000000..3e6b547
--- /dev/null
@@ -0,0 +1,613 @@
+/*
+ * Qt4 bitcoin GUI.
+ *
+ * W.J. van der Laan 2011
+ */
+#include "bitcoingui.h"
+#include "transactiontablemodel.h"
+#include "addressbookpage.h"
+#include "sendcoinsdialog.h"
+#include "optionsdialog.h"
+#include "aboutdialog.h"
+#include "clientmodel.h"
+#include "walletmodel.h"
+#include "editaddressdialog.h"
+#include "optionsmodel.h"
+#include "transactiondescdialog.h"
+#include "addresstablemodel.h"
+#include "transactionview.h"
+#include "overviewpage.h"
+#include "bitcoinunits.h"
+#include "guiconstants.h"
+#include "askpassphrasedialog.h"
+#include "notificator.h"
+
+#include <QApplication>
+#include <QMainWindow>
+#include <QMenuBar>
+#include <QMenu>
+#include <QIcon>
+#include <QTabWidget>
+#include <QVBoxLayout>
+#include <QToolBar>
+#include <QStatusBar>
+#include <QLabel>
+#include <QLineEdit>
+#include <QPushButton>
+#include <QLocale>
+#include <QMessageBox>
+#include <QProgressBar>
+#include <QStackedWidget>
+#include <QDateTime>
+#include <QMovie>
+
+#include <QDragEnterEvent>
+#include <QUrl>
+
+#include <iostream>
+
+BitcoinGUI::BitcoinGUI(QWidget *parent):
+    QMainWindow(parent),
+    clientModel(0),
+    walletModel(0),
+    encryptWalletAction(0),
+    changePassphraseAction(0),
+    trayIcon(0),
+    notificator(0)
+{
+    resize(850, 550);
+    setWindowTitle(tr("Bitcoin Wallet"));
+    setWindowIcon(QIcon(":icons/bitcoin"));
+    // Accept D&D of URIs
+    setAcceptDrops(true);
+
+    createActions();
+
+    // Menus
+    QMenu *file = menuBar()->addMenu(tr("&File"));
+    file->addAction(sendCoinsAction);
+    file->addAction(receiveCoinsAction);
+    file->addSeparator();
+    file->addAction(quitAction);
+    
+    QMenu *settings = menuBar()->addMenu(tr("&Settings"));
+    settings->addAction(encryptWalletAction);
+    settings->addAction(changePassphraseAction);
+    settings->addSeparator();
+    settings->addAction(optionsAction);
+
+    QMenu *help = menuBar()->addMenu(tr("&Help"));
+    help->addAction(aboutAction);
+    
+    // Toolbars
+    QToolBar *toolbar = addToolBar(tr("Tabs toolbar"));
+    toolbar->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
+    toolbar->addAction(overviewAction);
+    toolbar->addAction(sendCoinsAction);
+    toolbar->addAction(receiveCoinsAction);
+    toolbar->addAction(historyAction);
+    toolbar->addAction(addressBookAction);
+
+    QToolBar *toolbar2 = addToolBar(tr("Actions toolbar"));
+    toolbar2->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
+    toolbar2->addAction(exportAction);
+
+    // Create tabs
+    overviewPage = new OverviewPage();
+
+    transactionsPage = new QWidget(this);
+    QVBoxLayout *vbox = new QVBoxLayout();
+    transactionView = new TransactionView(this);
+    vbox->addWidget(transactionView);
+    transactionsPage->setLayout(vbox);
+
+    addressBookPage = new AddressBookPage(AddressBookPage::ForEditing, AddressBookPage::SendingTab);
+
+    receiveCoinsPage = new AddressBookPage(AddressBookPage::ForEditing, AddressBookPage::ReceivingTab);
+
+    sendCoinsPage = new SendCoinsDialog(this);
+
+    centralWidget = new QStackedWidget(this);
+    centralWidget->addWidget(overviewPage);
+    centralWidget->addWidget(transactionsPage);
+    centralWidget->addWidget(addressBookPage);
+    centralWidget->addWidget(receiveCoinsPage);
+    centralWidget->addWidget(sendCoinsPage);
+    setCentralWidget(centralWidget);
+
+    // Create status bar
+    statusBar();
+
+    // Status bar notification icons
+    QFrame *frameBlocks = new QFrame();
+    //frameBlocks->setFrameStyle(QFrame::Panel | QFrame::Sunken);
+    frameBlocks->setContentsMargins(0,0,0,0);
+    frameBlocks->setMinimumWidth(56);
+    frameBlocks->setMaximumWidth(56);
+    QHBoxLayout *frameBlocksLayout = new QHBoxLayout(frameBlocks);
+    frameBlocksLayout->setContentsMargins(3,0,3,0);
+    frameBlocksLayout->setSpacing(3);
+    labelEncryptionIcon = new QLabel();
+    labelConnectionsIcon = new QLabel();
+    labelBlocksIcon = new QLabel();
+    frameBlocksLayout->addStretch();
+    frameBlocksLayout->addWidget(labelEncryptionIcon);
+    frameBlocksLayout->addStretch();
+    frameBlocksLayout->addWidget(labelConnectionsIcon);
+    frameBlocksLayout->addStretch();
+    frameBlocksLayout->addWidget(labelBlocksIcon);
+    frameBlocksLayout->addStretch();
+
+    // Progress bar for blocks download
+    progressBarLabel = new QLabel(tr("Synchronizing with network..."));
+    progressBarLabel->setVisible(false);
+    progressBar = new QProgressBar();
+    progressBar->setToolTip(tr("Block chain synchronization in progress"));
+    progressBar->setVisible(false);
+
+    statusBar()->addWidget(progressBarLabel);
+    statusBar()->addWidget(progressBar);
+    statusBar()->addPermanentWidget(frameBlocks);
+
+    createTrayIcon();
+
+    syncIconMovie = new QMovie(":/movies/update_spinner", "mng", this);
+
+    // Clicking on a transaction on the overview page simply sends you to transaction history page
+    connect(overviewPage, SIGNAL(transactionClicked(QModelIndex)), this, SLOT(gotoHistoryPage()));
+
+    // Doubleclicking on a transaction on the transaction history page shows details
+    connect(transactionView, SIGNAL(doubleClicked(QModelIndex)), transactionView, SLOT(showDetails()));
+
+    gotoOverviewPage();
+}
+
+void BitcoinGUI::createActions()
+{
+    QActionGroup *tabGroup = new QActionGroup(this);
+
+    overviewAction = new QAction(QIcon(":/icons/overview"), tr("&Overview"), this);
+    overviewAction->setToolTip(tr("Show general overview of wallet"));
+    overviewAction->setCheckable(true);
+    tabGroup->addAction(overviewAction);
+
+    historyAction = new QAction(QIcon(":/icons/history"), tr("&Transactions"), this);
+    historyAction->setToolTip(tr("Browse transaction history"));
+    historyAction->setCheckable(true);
+    tabGroup->addAction(historyAction);
+
+    addressBookAction = new QAction(QIcon(":/icons/address-book"), tr("&Address Book"), this);
+    addressBookAction->setToolTip(tr("Edit the list of stored addresses and labels"));
+    addressBookAction->setCheckable(true);
+    tabGroup->addAction(addressBookAction);
+
+    receiveCoinsAction = new QAction(QIcon(":/icons/receiving_addresses"), tr("&Receive coins"), this);
+    receiveCoinsAction->setToolTip(tr("Show the list of addresses for receiving payments"));
+    receiveCoinsAction->setCheckable(true);
+    tabGroup->addAction(receiveCoinsAction);
+
+    sendCoinsAction = new QAction(QIcon(":/icons/send"), tr("&Send coins"), this);
+    sendCoinsAction->setToolTip(tr("Send coins to a bitcoin address"));
+    sendCoinsAction->setCheckable(true);
+    tabGroup->addAction(sendCoinsAction);
+
+    connect(overviewAction, SIGNAL(triggered()), this, SLOT(gotoOverviewPage()));
+    connect(historyAction, SIGNAL(triggered()), this, SLOT(gotoHistoryPage()));
+    connect(addressBookAction, SIGNAL(triggered()), this, SLOT(gotoAddressBookPage()));
+    connect(receiveCoinsAction, SIGNAL(triggered()), this, SLOT(gotoReceiveCoinsPage()));
+    connect(sendCoinsAction, SIGNAL(triggered()), this, SLOT(gotoSendCoinsPage()));
+
+    quitAction = new QAction(QIcon(":/icons/quit"), tr("&Exit"), this);
+    quitAction->setToolTip(tr("Quit application"));
+    aboutAction = new QAction(QIcon(":/icons/bitcoin"), tr("&About"), this);
+    aboutAction->setToolTip(tr("Show information about Bitcoin"));
+    optionsAction = new QAction(QIcon(":/icons/options"), tr("&Options..."), this);
+    optionsAction->setToolTip(tr("Modify configuration options for bitcoin"));
+    openBitcoinAction = new QAction(QIcon(":/icons/bitcoin"), tr("Open &Bitcoin"), this);
+    openBitcoinAction->setToolTip(tr("Show the Bitcoin window"));
+    exportAction = new QAction(QIcon(":/icons/export"), tr("&Export..."), this);
+    exportAction->setToolTip(tr("Export the current view to a file"));
+    encryptWalletAction = new QAction(QIcon(":/icons/lock_closed"), tr("&Encrypt Wallet"), this);
+    encryptWalletAction->setToolTip(tr("Encrypt or decrypt wallet"));
+    encryptWalletAction->setCheckable(true);
+    changePassphraseAction = new QAction(QIcon(":/icons/key"), tr("&Change Passphrase"), this);
+    changePassphraseAction->setToolTip(tr("Change the passphrase used for wallet encryption"));
+
+    connect(quitAction, SIGNAL(triggered()), qApp, SLOT(quit()));
+    connect(optionsAction, SIGNAL(triggered()), this, SLOT(optionsClicked()));
+    connect(aboutAction, SIGNAL(triggered()), this, SLOT(aboutClicked()));
+    connect(openBitcoinAction, SIGNAL(triggered()), this, SLOT(showNormal()));
+    connect(encryptWalletAction, SIGNAL(triggered(bool)), this, SLOT(encryptWallet(bool)));
+    connect(changePassphraseAction, SIGNAL(triggered()), this, SLOT(changePassphrase()));
+}
+
+void BitcoinGUI::setClientModel(ClientModel *clientModel)
+{
+    this->clientModel = clientModel;
+
+    if(clientModel->isTestNet())
+    {
+        QString title_testnet = windowTitle() + QString(" ") + tr("[testnet]");
+        setWindowTitle(title_testnet);
+        setWindowIcon(QIcon(":icons/bitcoin_testnet"));
+        if(trayIcon)
+        {
+            trayIcon->setToolTip(title_testnet);
+            trayIcon->setIcon(QIcon(":/icons/toolbar_testnet"));
+        }
+    }
+
+    // Keep up to date with client
+    setNumConnections(clientModel->getNumConnections());
+    connect(clientModel, SIGNAL(numConnectionsChanged(int)), this, SLOT(setNumConnections(int)));
+
+    setNumBlocks(clientModel->getNumBlocks());
+    connect(clientModel, SIGNAL(numBlocksChanged(int)), this, SLOT(setNumBlocks(int)));
+
+    // Report errors from network/worker thread
+    connect(clientModel, SIGNAL(error(QString,QString)), this, SLOT(error(QString,QString)));
+}
+
+void BitcoinGUI::setWalletModel(WalletModel *walletModel)
+{
+    this->walletModel = walletModel;
+
+    // Report errors from wallet thread
+    connect(walletModel, SIGNAL(error(QString,QString)), this, SLOT(error(QString,QString)));
+
+    // Put transaction list in tabs
+    transactionView->setModel(walletModel);
+
+    overviewPage->setModel(walletModel);
+    addressBookPage->setModel(walletModel->getAddressTableModel());
+    receiveCoinsPage->setModel(walletModel->getAddressTableModel());
+    sendCoinsPage->setModel(walletModel);
+
+    setEncryptionStatus(walletModel->getEncryptionStatus());
+    connect(walletModel, SIGNAL(encryptionStatusChanged(int)), this, SLOT(setEncryptionStatus(int)));
+
+    // Balloon popup for new transaction
+    connect(walletModel->getTransactionTableModel(), SIGNAL(rowsInserted(QModelIndex,int,int)),
+            this, SLOT(incomingTransaction(QModelIndex,int,int)));
+
+    // Ask for passphrase if needed
+    connect(walletModel, SIGNAL(requireUnlock()), this, SLOT(unlockWallet()));
+}
+
+void BitcoinGUI::createTrayIcon()
+{
+    QMenu *trayIconMenu = new QMenu(this);
+    trayIconMenu->addAction(openBitcoinAction);
+    trayIconMenu->addAction(optionsAction);
+    trayIconMenu->addSeparator();
+    trayIconMenu->addAction(quitAction);
+
+    trayIcon = new QSystemTrayIcon(this);
+    trayIcon->setContextMenu(trayIconMenu);
+    trayIcon->setToolTip("Bitcoin client");
+    trayIcon->setIcon(QIcon(":/icons/toolbar"));
+    connect(trayIcon, SIGNAL(activated(QSystemTrayIcon::ActivationReason)),
+            this, SLOT(trayIconActivated(QSystemTrayIcon::ActivationReason)));
+    trayIcon->show();
+
+    notificator = new Notificator(tr("bitcoin-qt"), trayIcon);
+}
+
+void BitcoinGUI::trayIconActivated(QSystemTrayIcon::ActivationReason reason)
+{
+    if(reason == QSystemTrayIcon::Trigger)
+    {
+        // Click on system tray icon triggers "open bitcoin"
+        openBitcoinAction->trigger();
+    }
+
+}
+
+void BitcoinGUI::optionsClicked()
+{
+    OptionsDialog dlg;
+    dlg.setModel(clientModel->getOptionsModel());
+    dlg.exec();
+}
+
+void BitcoinGUI::aboutClicked()
+{
+    AboutDialog dlg;
+    dlg.setModel(clientModel);
+    dlg.exec();
+}
+
+void BitcoinGUI::setNumConnections(int count)
+{
+    QString icon;
+    switch(count)
+    {
+    case 0: icon = ":/icons/connect_0"; break;
+    case 1: case 2: case 3: icon = ":/icons/connect_1"; break;
+    case 4: case 5: case 6: icon = ":/icons/connect_2"; break;
+    case 7: case 8: case 9: icon = ":/icons/connect_3"; break;
+    default: icon = ":/icons/connect_4"; break;
+    }
+    labelConnectionsIcon->setPixmap(QIcon(icon).pixmap(STATUSBAR_ICONSIZE,STATUSBAR_ICONSIZE));
+    labelConnectionsIcon->setToolTip(tr("%n active connection(s) to Bitcoin network", "", count));
+}
+
+void BitcoinGUI::setNumBlocks(int count)
+{
+    int initTotal = clientModel->getNumBlocksAtStartup();
+    int total = clientModel->getNumBlocksOfPeers();
+    QString tooltip;
+
+    if(count < total)
+    {
+        progressBarLabel->setVisible(true);
+        progressBar->setVisible(true);
+        progressBar->setMaximum(total - initTotal);
+        progressBar->setValue(count - initTotal);
+        tooltip = tr("Downloaded %1 of %2 blocks of transaction history.").arg(count).arg(total);
+    }
+    else
+    {
+        progressBarLabel->setVisible(false);
+        progressBar->setVisible(false);
+        tooltip = tr("Downloaded %1 blocks of transaction history.").arg(count);
+    }
+
+    QDateTime now = QDateTime::currentDateTime();
+    QDateTime lastBlockDate = clientModel->getLastBlockDate();
+    int secs = lastBlockDate.secsTo(now);
+    QString text;
+
+    // Represent time from last generated block in human readable text
+    if(secs < 60)
+    {
+        text = tr("%n second(s) ago","",secs);
+    }
+    else if(secs < 60*60)
+    {
+        text = tr("%n minute(s) ago","",secs/60);
+    }
+    else if(secs < 24*60*60)
+    {
+        text = tr("%n hour(s) ago","",secs/(60*60));
+    }
+    else
+    {
+        text = tr("%n day(s) ago","",secs/(60*60*24));
+    }
+
+    // Set icon state: spinning if catching up, tick otherwise
+    if(secs < 30*60)
+    {
+        tooltip = tr("Up to date") + QString("\n") + tooltip;
+        labelBlocksIcon->setPixmap(QIcon(":/icons/synced").pixmap(STATUSBAR_ICONSIZE,STATUSBAR_ICONSIZE));
+    }
+    else
+    {
+        tooltip = tr("Catching up...") + QString("\n") + tooltip;
+        labelBlocksIcon->setMovie(syncIconMovie);
+        syncIconMovie->start();
+    }
+
+    tooltip += QString("\n");
+    tooltip += tr("Last received block was generated %1.").arg(text);
+
+    labelBlocksIcon->setToolTip(tooltip);
+    progressBarLabel->setToolTip(tooltip);
+    progressBar->setToolTip(tooltip);
+}
+
+void BitcoinGUI::error(const QString &title, const QString &message)
+{
+    // Report errors from network/worker thread
+    notificator->notify(Notificator::Critical, title, message);
+}
+
+void BitcoinGUI::changeEvent(QEvent *e)
+{
+    if (e->type() == QEvent::WindowStateChange)
+    {
+        if(clientModel->getOptionsModel()->getMinimizeToTray())
+        {
+            if (isMinimized())
+            {
+                hide();
+                e->ignore();
+            }
+            else
+            {
+                show();
+                e->accept();
+            }
+        }
+    }
+    QMainWindow::changeEvent(e);
+}
+
+void BitcoinGUI::closeEvent(QCloseEvent *event)
+{
+    if(!clientModel->getOptionsModel()->getMinimizeToTray() &&
+       !clientModel->getOptionsModel()->getMinimizeOnClose())
+    {
+        qApp->quit();
+    }
+    QMainWindow::closeEvent(event);
+}
+
+void BitcoinGUI::askFee(qint64 nFeeRequired, bool *payFee)
+{
+    QString strMessage =
+        tr("This transaction is over the size limit.  You can still send it for a fee of %1, "
+          "which goes to the nodes that process your transaction and helps to support the network.  "
+          "Do you want to pay the fee?").arg(
+                BitcoinUnits::formatWithUnit(BitcoinUnits::BTC, nFeeRequired));
+    QMessageBox::StandardButton retval = QMessageBox::question(
+          this, tr("Sending..."), strMessage,
+          QMessageBox::Yes|QMessageBox::Cancel, QMessageBox::Yes);
+    *payFee = (retval == QMessageBox::Yes);
+}
+
+void BitcoinGUI::incomingTransaction(const QModelIndex & parent, int start, int end)
+{
+    TransactionTableModel *ttm = walletModel->getTransactionTableModel();
+    qint64 amount = ttm->index(start, TransactionTableModel::Amount, parent)
+                    .data(Qt::EditRole).toULongLong();
+    if(!clientModel->inInitialBlockDownload())
+    {
+        // On new transaction, make an info balloon
+        // Unless the initial block download is in progress, to prevent balloon-spam
+        QString date = ttm->index(start, TransactionTableModel::Date, parent)
+                        .data().toString();
+        QString type = ttm->index(start, TransactionTableModel::Type, parent)
+                        .data().toString();
+        QString address = ttm->index(start, TransactionTableModel::ToAddress, parent)
+                        .data().toString();
+        QIcon icon = qvariant_cast<QIcon>(ttm->index(start,
+                            TransactionTableModel::ToAddress, parent)
+                        .data(Qt::DecorationRole));
+
+        notificator->notify(Notificator::Information,
+                            (amount)<0 ? tr("Sent transaction") :
+                                         tr("Incoming transaction"),
+                              tr("Date: %1\n"
+                                 "Amount: %2\n"
+                                 "Type: %3\n"
+                                 "Address: %4\n")
+                              .arg(date)
+                              .arg(BitcoinUnits::formatWithUnit(walletModel->getOptionsModel()->getDisplayUnit(), amount, true))
+                              .arg(type)
+                              .arg(address), icon);
+    }
+}
+
+void BitcoinGUI::gotoOverviewPage()
+{
+    overviewAction->setChecked(true);
+    centralWidget->setCurrentWidget(overviewPage);
+
+    exportAction->setEnabled(false);
+    disconnect(exportAction, SIGNAL(triggered()), 0, 0);
+}
+
+void BitcoinGUI::gotoHistoryPage()
+{
+    historyAction->setChecked(true);
+    centralWidget->setCurrentWidget(transactionsPage);
+
+    exportAction->setEnabled(true);
+    disconnect(exportAction, SIGNAL(triggered()), 0, 0);
+    connect(exportAction, SIGNAL(triggered()), transactionView, SLOT(exportClicked()));
+}
+
+void BitcoinGUI::gotoAddressBookPage()
+{
+    addressBookAction->setChecked(true);
+    centralWidget->setCurrentWidget(addressBookPage);
+
+    exportAction->setEnabled(true);
+    disconnect(exportAction, SIGNAL(triggered()), 0, 0);
+    connect(exportAction, SIGNAL(triggered()), addressBookPage, SLOT(exportClicked()));
+}
+
+void BitcoinGUI::gotoReceiveCoinsPage()
+{
+    receiveCoinsAction->setChecked(true);
+    centralWidget->setCurrentWidget(receiveCoinsPage);
+
+    exportAction->setEnabled(true);
+    disconnect(exportAction, SIGNAL(triggered()), 0, 0);
+    connect(exportAction, SIGNAL(triggered()), receiveCoinsPage, SLOT(exportClicked()));
+}
+
+void BitcoinGUI::gotoSendCoinsPage()
+{
+    sendCoinsAction->setChecked(true);
+    if(centralWidget->currentWidget() != sendCoinsPage)
+    {
+        // Clear the current contents if we arrived from another tab
+        sendCoinsPage->clear();
+    }
+    centralWidget->setCurrentWidget(sendCoinsPage);
+
+    exportAction->setEnabled(false);
+    disconnect(exportAction, SIGNAL(triggered()), 0, 0);
+}
+
+void BitcoinGUI::dragEnterEvent(QDragEnterEvent *event)
+{
+    // Accept only URLs
+    if(event->mimeData()->hasUrls())
+        event->acceptProposedAction();
+}
+
+void BitcoinGUI::dropEvent(QDropEvent *event)
+{
+    if(event->mimeData()->hasUrls())
+    {
+        gotoSendCoinsPage();
+        QList<QUrl> urls = event->mimeData()->urls();
+        foreach(const QUrl &url, urls)
+        {
+            sendCoinsPage->handleURL(&url);
+        }
+    }
+
+    event->acceptProposedAction();
+}
+
+void BitcoinGUI::setEncryptionStatus(int status)
+{
+    switch(status)
+    {
+    case WalletModel::Unencrypted:
+        labelEncryptionIcon->hide();
+        encryptWalletAction->setChecked(false);
+        changePassphraseAction->setEnabled(false);
+        encryptWalletAction->setEnabled(true);
+        break;
+    case WalletModel::Unlocked:
+        labelEncryptionIcon->show();
+        labelEncryptionIcon->setPixmap(QIcon(":/icons/lock_open").pixmap(STATUSBAR_ICONSIZE,STATUSBAR_ICONSIZE));
+        labelEncryptionIcon->setToolTip(tr("Wallet is <b>encrypted</b> and currently <b>unlocked</b>"));
+        encryptWalletAction->setChecked(true);
+        changePassphraseAction->setEnabled(true);
+        encryptWalletAction->setEnabled(false); // TODO: decrypt currently not supported
+        break;
+    case WalletModel::Locked:
+        labelEncryptionIcon->show();
+        labelEncryptionIcon->setPixmap(QIcon(":/icons/lock_closed").pixmap(STATUSBAR_ICONSIZE,STATUSBAR_ICONSIZE));
+        labelEncryptionIcon->setToolTip(tr("Wallet is <b>encrypted</b> and currently <b>locked</b>"));
+        encryptWalletAction->setChecked(true);
+        changePassphraseAction->setEnabled(true);
+        encryptWalletAction->setEnabled(false); // TODO: decrypt currently not supported
+        break;
+    }
+}
+
+void BitcoinGUI::encryptWallet(bool status)
+{
+    AskPassphraseDialog dlg(status ? AskPassphraseDialog::Encrypt:
+                                     AskPassphraseDialog::Decrypt, this);
+    dlg.setModel(walletModel);
+    dlg.exec();
+
+    setEncryptionStatus(walletModel->getEncryptionStatus());
+}
+
+void BitcoinGUI::changePassphrase()
+{
+    AskPassphraseDialog dlg(AskPassphraseDialog::ChangePass, this);
+    dlg.setModel(walletModel);
+    dlg.exec();
+}
+
+void BitcoinGUI::unlockWallet()
+{
+    // Unlock wallet when requested by wallet model
+    if(walletModel->getEncryptionStatus() == WalletModel::Locked)
+    {
+        AskPassphraseDialog dlg(AskPassphraseDialog::Unlock, this);
+        dlg.setModel(walletModel);
+        dlg.exec();
+    }
+}
diff --git a/src/qt/bitcoingui.h b/src/qt/bitcoingui.h
new file mode 100644 (file)
index 0000000..5966135
--- /dev/null
@@ -0,0 +1,120 @@
+#ifndef BITCOINGUI_H
+#define BITCOINGUI_H
+
+#include <QMainWindow>
+#include <QSystemTrayIcon>
+
+class TransactionTableModel;
+class ClientModel;
+class WalletModel;
+class TransactionView;
+class OverviewPage;
+class AddressBookPage;
+class SendCoinsDialog;
+class Notificator;
+
+QT_BEGIN_NAMESPACE
+class QLabel;
+class QLineEdit;
+class QTableView;
+class QAbstractItemModel;
+class QModelIndex;
+class QProgressBar;
+class QStackedWidget;
+class QUrl;
+QT_END_NAMESPACE
+
+class BitcoinGUI : public QMainWindow
+{
+    Q_OBJECT
+public:
+    explicit BitcoinGUI(QWidget *parent = 0);
+    void setClientModel(ClientModel *clientModel);
+    void setWalletModel(WalletModel *walletModel);
+    
+    /* Transaction table tab indices */
+    enum {
+        AllTransactions = 0,
+        SentReceived = 1,
+        Sent = 2,
+        Received = 3
+    } TabIndex;
+
+protected:
+    void changeEvent(QEvent *e);
+    void closeEvent(QCloseEvent *event);
+    void dragEnterEvent(QDragEnterEvent *event);
+    void dropEvent(QDropEvent *event);
+
+private:
+    ClientModel *clientModel;
+    WalletModel *walletModel;
+
+    QStackedWidget *centralWidget;
+
+    OverviewPage *overviewPage;
+    QWidget *transactionsPage;
+    AddressBookPage *addressBookPage;
+    AddressBookPage *receiveCoinsPage;
+    SendCoinsDialog *sendCoinsPage;
+
+    QLabel *labelEncryptionIcon;
+    QLabel *labelConnectionsIcon;
+    QLabel *labelBlocksIcon;
+    QLabel *progressBarLabel;
+    QProgressBar *progressBar;
+
+    QAction *overviewAction;
+    QAction *historyAction;
+    QAction *quitAction;
+    QAction *sendCoinsAction;
+    QAction *addressBookAction;
+    QAction *aboutAction;
+    QAction *receiveCoinsAction;
+    QAction *optionsAction;
+    QAction *openBitcoinAction;
+    QAction *exportAction;
+    QAction *encryptWalletAction;
+    QAction *changePassphraseAction;
+
+    QSystemTrayIcon *trayIcon;
+    Notificator *notificator;
+    TransactionView *transactionView;
+
+    QMovie *syncIconMovie;
+
+    void createActions();
+    QWidget *createTabs();
+    void createTrayIcon();
+
+public slots:
+    void setNumConnections(int count);
+    void setNumBlocks(int count);
+    void setEncryptionStatus(int status);
+
+    void error(const QString &title, const QString &message);
+    /* It is currently not possible to pass a return value to another thread through
+       BlockingQueuedConnection, so use an indirected pointer.
+       http://bugreports.qt.nokia.com/browse/QTBUG-10440
+    */
+    void askFee(qint64 nFeeRequired, bool *payFee);
+
+private slots:
+    // UI pages
+    void gotoOverviewPage();
+    void gotoHistoryPage();
+    void gotoAddressBookPage();
+    void gotoReceiveCoinsPage();
+    void gotoSendCoinsPage();
+
+    // Misc actions
+    void optionsClicked();
+    void aboutClicked();
+    void trayIconActivated(QSystemTrayIcon::ActivationReason reason);
+    void incomingTransaction(const QModelIndex & parent, int start, int end);
+    void encryptWallet(bool status);
+    void changePassphrase();
+    void unlockWallet();
+};
+
+#endif
diff --git a/src/qt/bitcoinstrings.cpp b/src/qt/bitcoinstrings.cpp
new file mode 100644 (file)
index 0000000..45aadd4
--- /dev/null
@@ -0,0 +1,217 @@
+#include <QtGlobal>
+// Automatically generated by extract_strings.py
+static const char *bitcoin_strings[] = {QT_TRANSLATE_NOOP("bitcoin-core", "Bitcoin version"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Usage:"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Send command to -server or bitcoind\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "List commands\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Get help for a command\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Options:\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Specify configuration file (default: bitcoin.conf)\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Specify pid file (default: bitcoind.pid)\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Generate coins\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Don't generate coins\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Start minimized\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Specify data directory\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Specify connection timeout (in milliseconds)\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Connect through socks4 proxy\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Allow DNS lookups for addnode and connect\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Add a node to connect to\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Connect only to the specified node\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Don't accept connections from outside\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Don't attempt to use UPnP to map the listening port\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Attempt to use UPnP to map the listening port\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Fee per KB to add to transactions you send\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Accept command line and JSON-RPC commands\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Run in the background as a daemon and accept commands\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Use the test network\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Username for JSON-RPC connections\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Password for JSON-RPC connections\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Listen for JSON-RPC connections on <port> (default: 8332)\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Allow JSON-RPC connections from specified IP address\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Send commands to node running on <ip> (default: 127.0.0.1)\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Set key pool size to <n> (default: 100)\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Rescan the block chain for missing wallet transactions\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"\n"
+"SSL options: (see the Bitcoin Wiki for SSL setup instructions)\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Use OpenSSL (https) for JSON-RPC connections\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Server certificate file (default: server.cert)\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Server private key (default: server.pem)\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:"
+"@STRENGTH)\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "This help message\n"),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"Cannot obtain a lock on data directory %s.  Bitcoin is probably already "
+"running."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Loading addresses..."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Error loading addr.dat      \n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Loading block index..."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Error loading blkindex.dat      \n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Loading wallet..."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Error loading wallet.dat: Wallet corrupted      \n"),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"Error loading wallet.dat: Wallet requires newer version of Bitcoin      \n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Error loading wallet.dat      \n"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Rescanning..."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Done loading"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Invalid -proxy address"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Invalid amount for -paytxfee=<amount>"),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"Warning: -paytxfee is set very high.  This is the transaction fee you will "
+"pay if you send a transaction."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Error: CreateThread(StartNode) failed"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Warning: Disk space is low  "),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"Unable to bind to port %d on this computer.  Bitcoin is probably already "
+"running."),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"This transaction is over the size limit.  You can still send it for a fee of "
+"%s, which goes to the nodes that process your transaction and helps to "
+"support the network.  Do you want to pay the fee?"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Enter the current passphrase to the wallet."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Passphrase"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Please supply the current wallet decryption passphrase."),
+QT_TRANSLATE_NOOP("bitcoin-core", "The passphrase entered for the wallet decryption was incorrect."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Status"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Date"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Description"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Debit"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Credit"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Open for %d blocks"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Open until %s"),
+QT_TRANSLATE_NOOP("bitcoin-core", "%d/offline?"),
+QT_TRANSLATE_NOOP("bitcoin-core", "%d/unconfirmed"),
+QT_TRANSLATE_NOOP("bitcoin-core", "%d confirmations"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Generated"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Generated (%s matures in %d more blocks)"),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"Generated - Warning: This block was not received by any other nodes and will "
+"probably not be accepted!"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Generated (not accepted)"),
+QT_TRANSLATE_NOOP("bitcoin-core", "From: "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Received with: "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Payment to yourself"),
+QT_TRANSLATE_NOOP("bitcoin-core", "To: "),
+QT_TRANSLATE_NOOP("bitcoin-core", "    Generating"),
+QT_TRANSLATE_NOOP("bitcoin-core", "(not connected)"),
+QT_TRANSLATE_NOOP("bitcoin-core", "     %d connections     %d blocks     %d transactions"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Wallet already encrypted."),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"Enter the new passphrase to the wallet.\n"
+"Please use a passphrase of 10 or more random characters, or eight or more "
+"words."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Error: The supplied passphrase was too short."),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"WARNING: If you encrypt your wallet and lose your passphrase, you will LOSE "
+"ALL OF YOUR BITCOINS!\n"
+"Are you sure you wish to encrypt your wallet?"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Please re-enter your new wallet passphrase."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Error: the supplied passphrases didn't match."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Wallet encryption failed."),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"Wallet Encrypted.\n"
+"Remember that encrypting your wallet cannot fully protect your bitcoins from "
+"being stolen by malware infecting your computer."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Wallet is unencrypted, please encrypt it first."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Enter the new passphrase for the wallet."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Re-enter the new passphrase for the wallet."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Wallet Passphrase Changed."),
+QT_TRANSLATE_NOOP("bitcoin-core", "New Receiving Address"),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"You should use a new address for each payment you receive.\n"
+"\n"
+"Label"),
+QT_TRANSLATE_NOOP("bitcoin-core", "<b>Status:</b> "),
+QT_TRANSLATE_NOOP("bitcoin-core", ", has not been successfully broadcast yet"),
+QT_TRANSLATE_NOOP("bitcoin-core", ", broadcast through %d node"),
+QT_TRANSLATE_NOOP("bitcoin-core", ", broadcast through %d nodes"),
+QT_TRANSLATE_NOOP("bitcoin-core", "<b>Date:</b> "),
+QT_TRANSLATE_NOOP("bitcoin-core", "<b>Source:</b> Generated<br>"),
+QT_TRANSLATE_NOOP("bitcoin-core", "<b>From:</b> "),
+QT_TRANSLATE_NOOP("bitcoin-core", "unknown"),
+QT_TRANSLATE_NOOP("bitcoin-core", "<b>To:</b> "),
+QT_TRANSLATE_NOOP("bitcoin-core", " (yours, label: "),
+QT_TRANSLATE_NOOP("bitcoin-core", " (yours)"),
+QT_TRANSLATE_NOOP("bitcoin-core", "<b>Credit:</b> "),
+QT_TRANSLATE_NOOP("bitcoin-core", "(%s matures in %d more blocks)"),
+QT_TRANSLATE_NOOP("bitcoin-core", "(not accepted)"),
+QT_TRANSLATE_NOOP("bitcoin-core", "<b>Debit:</b> "),
+QT_TRANSLATE_NOOP("bitcoin-core", "<b>Transaction fee:</b> "),
+QT_TRANSLATE_NOOP("bitcoin-core", "<b>Net amount:</b> "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Message:"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Comment:"),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"Generated coins must wait 120 blocks before they can be spent.  When you "
+"generated this block, it was broadcast to the network to be added to the "
+"block chain.  If it fails to get into the chain, it will change to \"not "
+"accepted\" and not be spendable.  This may occasionally happen if another "
+"node generates a block within a few seconds of yours."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Cannot write autostart/bitcoin.desktop file"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Main"),
+QT_TRANSLATE_NOOP("bitcoin-core", "&Start Bitcoin on window system startup"),
+QT_TRANSLATE_NOOP("bitcoin-core", "&Minimize on close"),
+QT_TRANSLATE_NOOP("bitcoin-core", "version %s"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Error in amount  "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Send Coins"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Amount exceeds your balance  "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Total exceeds your balance when the "),
+QT_TRANSLATE_NOOP("bitcoin-core", " transaction fee is included  "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Payment sent  "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Sending..."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Invalid address  "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Sending %s to %s"),
+QT_TRANSLATE_NOOP("bitcoin-core", "CANCELLED"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Cancelled"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Transfer cancelled  "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Error: "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Insufficient funds"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Connecting..."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Unable to connect"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Requesting public key..."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Received public key..."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Recipient is not accepting transactions sent by IP address"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Transfer was not accepted"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Invalid response received"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Creating transaction..."),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"This transaction requires a transaction fee of at least %s because of its "
+"amount, complexity, or use of recently received funds"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Transaction creation failed"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Transaction aborted"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Lost connection, transaction cancelled"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Sending payment..."),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"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."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Waiting for confirmation..."),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"The payment was sent, but the recipient was unable to verify it.\n"
+"The transaction is recorded and will credit to the recipient,\n"
+"but the comment information will be blank."),
+QT_TRANSLATE_NOOP("bitcoin-core", "Payment was sent, but an invalid response was received"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Payment completed"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Name"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Address"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Label"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Bitcoin Address"),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"This is one of your own addresses for receiving payments and cannot be "
+"entered in the address book.  "),
+QT_TRANSLATE_NOOP("bitcoin-core", "Edit Address"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Edit Address Label"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Add Address"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Bitcoin"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Bitcoin - Generating"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Bitcoin - (not connected)"),
+QT_TRANSLATE_NOOP("bitcoin-core", "&Open Bitcoin"),
+QT_TRANSLATE_NOOP("bitcoin-core", "&Send Bitcoins"),
+QT_TRANSLATE_NOOP("bitcoin-core", "O&ptions..."),
+QT_TRANSLATE_NOOP("bitcoin-core", "E&xit"),
+QT_TRANSLATE_NOOP("bitcoin-core", "Program has crashed and will terminate.  "),
+QT_TRANSLATE_NOOP("bitcoin-core", ""
+"Warning: Please check that your computer's date and time are correct.  If "
+"your clock is wrong Bitcoin will not work properly."),
+QT_TRANSLATE_NOOP("bitcoin-core", "beta"),
+};
\ No newline at end of file
diff --git a/src/qt/bitcoinunits.cpp b/src/qt/bitcoinunits.cpp
new file mode 100644 (file)
index 0000000..9a9a489
--- /dev/null
@@ -0,0 +1,181 @@
+#include "bitcoinunits.h"
+
+#include <QStringList>
+
+BitcoinUnits::BitcoinUnits(QObject *parent):
+        QAbstractListModel(parent),
+        unitlist(availableUnits())
+{
+}
+
+QList<BitcoinUnits::Unit> BitcoinUnits::availableUnits()
+{
+    QList<BitcoinUnits::Unit> unitlist;
+    unitlist.append(BTC);
+    unitlist.append(mBTC);
+    unitlist.append(uBTC);
+    return unitlist;
+}
+
+bool BitcoinUnits::valid(int unit)
+{
+    switch(unit)
+    {
+    case BTC:
+    case mBTC:
+    case uBTC:
+        return true;
+    default:
+        return false;
+    }
+}
+
+QString BitcoinUnits::name(int unit)
+{
+    switch(unit)
+    {
+    case BTC: return QString("BTC");
+    case mBTC: return QString("mBTC");
+    case uBTC: return QString::fromUtf8("μBTC");
+    default: return QString("???");
+    }
+}
+
+QString BitcoinUnits::description(int unit)
+{
+    switch(unit)
+    {
+    case BTC: return QString("Bitcoins");
+    case mBTC: return QString("Milli-Bitcoins (1 / 1,000)");
+    case uBTC: return QString("Micro-Bitcoins (1 / 1,000,000)");
+    default: return QString("???");
+    }
+}
+
+qint64 BitcoinUnits::factor(int unit)
+{
+    switch(unit)
+    {
+    case BTC:  return 100000000;
+    case mBTC: return 100000;
+    case uBTC: return 100;
+    default:   return 100000000;
+    }
+}
+
+int BitcoinUnits::amountDigits(int unit)
+{
+    switch(unit)
+    {
+    case BTC: return 8; // 21,000,000 (# digits, without commas)
+    case mBTC: return 11; // 21,000,000,000
+    case uBTC: return 14; // 21,000,000,000,000
+    default: return 0;
+    }
+}
+
+int BitcoinUnits::decimals(int unit)
+{
+    switch(unit)
+    {
+    case BTC: return 8;
+    case mBTC: return 5;
+    case uBTC: return 2;
+    default: return 0;
+    }
+}
+
+QString BitcoinUnits::format(int unit, qint64 n, bool fPlus)
+{
+    // Note: not using straight sprintf here because we do NOT want
+    // localized number formatting.
+    if(!valid(unit))
+        return QString(); // Refuse to format invalid unit
+    qint64 coin = factor(unit);
+    int num_decimals = decimals(unit);
+    qint64 n_abs = (n > 0 ? n : -n);
+    qint64 quotient = n_abs / coin;
+    qint64 remainder = n_abs % coin;
+    QString quotient_str = QString::number(quotient);
+    QString remainder_str = QString::number(remainder).rightJustified(num_decimals, '0');
+
+    // Right-trim excess 0's after the decimal point
+    int nTrim = 0;
+    for (int i = remainder_str.size()-1; i>=2 && (remainder_str.at(i) == '0'); --i)
+        ++nTrim;
+    remainder_str.chop(nTrim);
+
+    if (n < 0)
+        quotient_str.insert(0, '-');
+    else if (fPlus && n > 0)
+        quotient_str.insert(0, '+');
+    return quotient_str + QString(".") + remainder_str;
+}
+
+QString BitcoinUnits::formatWithUnit(int unit, qint64 amount, bool plussign)
+{
+    return format(unit, amount, plussign) + QString(" ") + name(unit);
+}
+
+bool BitcoinUnits::parse(int unit, const QString &value, qint64 *val_out)
+{
+    if(!valid(unit) || value.isEmpty())
+        return false; // Refuse to parse invalid unit or empty string
+    int num_decimals = decimals(unit);
+    QStringList parts = value.split(".");
+
+    if(parts.size() > 2)
+    {
+        return false; // More than one dot
+    }
+    QString whole = parts[0];
+    QString decimals;
+
+    if(parts.size() > 1)
+    {
+        decimals = parts[1];
+    }
+    if(decimals.size() > num_decimals)
+    {
+        return false; // Exceeds max precision
+    }
+    bool ok = false;
+    QString str = whole + decimals.leftJustified(num_decimals, '0');
+
+    if(str.size() > 18)
+    {
+        return false; // Longer numbers will exceed 63 bits
+    }
+    qint64 retvalue = str.toLongLong(&ok);
+    if(val_out)
+    {
+        *val_out = retvalue;
+    }
+    return ok;
+}
+
+int BitcoinUnits::rowCount(const QModelIndex &parent) const
+{
+    Q_UNUSED(parent);
+    return unitlist.size();
+}
+
+QVariant BitcoinUnits::data(const QModelIndex &index, int role) const
+{
+    int row = index.row();
+    if(row >= 0 && row < unitlist.size())
+    {
+        Unit unit = unitlist.at(row);
+        switch(role)
+        {
+        case Qt::EditRole:
+        case Qt::DisplayRole:
+            return QVariant(name(unit));
+        case Qt::ToolTipRole:
+            return QVariant(description(unit));
+        case UnitRole:
+            return QVariant(static_cast<int>(unit));
+        }
+    }
+    return QVariant();
+}
diff --git a/src/qt/bitcoinunits.h b/src/qt/bitcoinunits.h
new file mode 100644 (file)
index 0000000..a7bebbc
--- /dev/null
@@ -0,0 +1,57 @@
+#ifndef BITCOINUNITS_H
+#define BITCOINUNITS_H
+
+#include <QString>
+#include <QAbstractListModel>
+
+// Bitcoin unit definitions, encapsulates parsing and formatting
+// and serves as list model for dropdown selection boxes.
+class BitcoinUnits: public QAbstractListModel
+{
+public:
+    explicit BitcoinUnits(QObject *parent);
+
+    enum Unit
+    {
+        // Source: https://en.bitcoin.it/wiki/Units
+        // Please add only sensible ones
+        BTC,
+        mBTC,
+        uBTC
+    };
+
+    /// Static API
+    // Get list of units, for dropdown box
+    static QList<Unit> availableUnits();
+    // Is unit ID valid?
+    static bool valid(int unit);
+    // Short name
+    static QString name(int unit);
+    // Longer description
+    static QString description(int unit);
+    // Number of satoshis / unit
+    static qint64 factor(int unit);
+    // Number of amount digits (to represent max number of coins)
+    static int amountDigits(int unit);
+    // Number of decimals left
+    static int decimals(int unit);
+    // Format as string
+    static QString format(int unit, qint64 amount, bool plussign=false);
+    // Format as string (with unit)
+    static QString formatWithUnit(int unit, qint64 amount, bool plussign=false);
+    // Parse string to coin amount
+    static bool parse(int unit, const QString &value, qint64 *val_out);
+
+    /// AbstractListModel implementation
+    enum {
+        // Unit identifier
+        UnitRole = Qt::UserRole
+    } RoleIndex;
+    int rowCount(const QModelIndex &parent) const;
+    QVariant data(const QModelIndex &index, int role) const;
+private:
+    QList<BitcoinUnits::Unit> unitlist;
+};
+typedef BitcoinUnits::Unit BitcoinUnit;
+
+#endif // BITCOINUNITS_H
diff --git a/src/qt/clientmodel.cpp b/src/qt/clientmodel.cpp
new file mode 100644 (file)
index 0000000..2ed3ce5
--- /dev/null
@@ -0,0 +1,83 @@
+#include "clientmodel.h"
+#include "guiconstants.h"
+#include "optionsmodel.h"
+#include "addresstablemodel.h"
+#include "transactiontablemodel.h"
+
+#include "headers.h"
+
+#include <QTimer>
+#include <QDateTime>
+
+ClientModel::ClientModel(OptionsModel *optionsModel, QObject *parent) :
+    QObject(parent), optionsModel(optionsModel),
+    cachedNumConnections(0), cachedNumBlocks(0)
+{
+    // Until signal notifications is built into the bitcoin core,
+    //  simply update everything after polling using a timer.
+    QTimer *timer = new QTimer(this);
+    connect(timer, SIGNAL(timeout()), this, SLOT(update()));
+    timer->start(MODEL_UPDATE_DELAY);
+
+    numBlocksAtStartup = -1;
+}
+
+int ClientModel::getNumConnections() const
+{
+    return vNodes.size();
+}
+
+int ClientModel::getNumBlocks() const
+{
+    return nBestHeight;
+}
+
+int ClientModel::getNumBlocksAtStartup()
+{
+    if (numBlocksAtStartup == -1) numBlocksAtStartup = getNumBlocks();
+    return numBlocksAtStartup;
+}
+
+QDateTime ClientModel::getLastBlockDate() const
+{
+    return QDateTime::fromTime_t(pindexBest->GetBlockTime());
+}
+
+void ClientModel::update()
+{
+    int newNumConnections = getNumConnections();
+    int newNumBlocks = getNumBlocks();
+
+    if(cachedNumConnections != newNumConnections)
+        emit numConnectionsChanged(newNumConnections);
+    if(cachedNumBlocks != newNumBlocks)
+        emit numBlocksChanged(newNumBlocks);
+
+    cachedNumConnections = newNumConnections;
+    cachedNumBlocks = newNumBlocks;
+}
+
+bool ClientModel::isTestNet() const
+{
+    return fTestNet;
+}
+
+bool ClientModel::inInitialBlockDownload() const
+{
+    return IsInitialBlockDownload();
+}
+
+int ClientModel::getNumBlocksOfPeers() const
+{
+    return GetNumBlocksOfPeers();
+}
+
+OptionsModel *ClientModel::getOptionsModel()
+{
+    return optionsModel;
+}
+
+QString ClientModel::formatFullVersion() const
+{
+    return QString::fromStdString(FormatFullVersion());
+}
diff --git a/src/qt/clientmodel.h b/src/qt/clientmodel.h
new file mode 100644 (file)
index 0000000..c68fb0f
--- /dev/null
@@ -0,0 +1,60 @@
+#ifndef CLIENTMODEL_H
+#define CLIENTMODEL_H
+
+#include <QObject>
+
+class OptionsModel;
+class AddressTableModel;
+class TransactionTableModel;
+class CWallet;
+
+QT_BEGIN_NAMESPACE
+class QDateTime;
+QT_END_NAMESPACE
+
+// Model for Bitcoin network client
+class ClientModel : public QObject
+{
+    Q_OBJECT
+public:
+    explicit ClientModel(OptionsModel *optionsModel, QObject *parent = 0);
+
+    OptionsModel *getOptionsModel();
+
+    int getNumConnections() const;
+    int getNumBlocks() const;
+    int getNumBlocksAtStartup();
+
+    QDateTime getLastBlockDate() const;
+
+    // Return true if client connected to testnet
+    bool isTestNet() const;
+    // Return true if core is doing initial block download
+    bool inInitialBlockDownload() const;
+    // Return conservative estimate of total number of blocks, or 0 if unknown
+    int getNumBlocksOfPeers() const;
+
+    QString formatFullVersion() const;
+
+private:
+    OptionsModel *optionsModel;
+
+    int cachedNumConnections;
+    int cachedNumBlocks;
+
+    int numBlocksAtStartup;
+
+signals:
+    void numConnectionsChanged(int count);
+    void numBlocksChanged(int count);
+
+    // Asynchronous error notification
+    void error(const QString &title, const QString &message);
+
+public slots:
+
+private slots:
+    void update();
+};
+
+#endif // CLIENTMODEL_H
diff --git a/src/qt/csvmodelwriter.cpp b/src/qt/csvmodelwriter.cpp
new file mode 100644 (file)
index 0000000..62c0b94
--- /dev/null
@@ -0,0 +1,83 @@
+#include "csvmodelwriter.h"
+
+#include <QAbstractItemModel>
+#include <QFile>
+#include <QTextStream>
+
+CSVModelWriter::CSVModelWriter(const QString &filename, QObject *parent) :
+    QObject(parent),
+    filename(filename)
+{
+}
+
+void CSVModelWriter::setModel(const QAbstractItemModel *model)
+{
+    this->model = model;
+}
+
+void CSVModelWriter::addColumn(const QString &title, int column, int role)
+{
+    Column col;
+    col.title = title;
+    col.column = column;
+    col.role = role;
+
+    columns.append(col);
+}
+
+static void writeValue(QTextStream &f, const QString &value)
+{
+    // TODO: quoting if " or \n in string
+    f << "\"" << value << "\"";
+}
+
+static void writeSep(QTextStream &f)
+{
+    f << ",";
+}
+
+static void writeNewline(QTextStream &f)
+{
+    f << "\n";
+}
+
+bool CSVModelWriter::write()
+{
+    QFile file(filename);
+    if(!file.open(QIODevice::WriteOnly | QIODevice::Text))
+        return false;
+    QTextStream out(&file);
+
+    int numRows = model->rowCount();
+
+    // Header row
+    for(int i=0; i<columns.size(); ++i)
+    {
+        if(i!=0)
+        {
+            writeSep(out);
+        }
+        writeValue(out, columns[i].title);
+    }
+    writeNewline(out);
+
+    // Data rows
+    for(int j=0; j<numRows; ++j)
+    {
+        for(int i=0; i<columns.size(); ++i)
+        {
+            if(i!=0)
+            {
+                writeSep(out);
+            }
+            QVariant data = model->index(j, columns[i].column).data(columns[i].role);
+            writeValue(out, data.toString());
+        }
+        writeNewline(out);
+    }
+
+    file.close();
+
+    return file.error() == QFile::NoError;
+}
+
diff --git a/src/qt/csvmodelwriter.h b/src/qt/csvmodelwriter.h
new file mode 100644 (file)
index 0000000..7367f3a
--- /dev/null
@@ -0,0 +1,43 @@
+#ifndef CSVMODELWRITER_H
+#define CSVMODELWRITER_H
+
+#include <QObject>
+#include <QList>
+
+QT_BEGIN_NAMESPACE
+class QAbstractItemModel;
+QT_END_NAMESPACE
+
+// Export TableModel to CSV file
+class CSVModelWriter : public QObject
+{
+    Q_OBJECT
+public:
+    explicit CSVModelWriter(const QString &filename, QObject *parent = 0);
+
+    void setModel(const QAbstractItemModel *model);
+    void addColumn(const QString &title, int column, int role=Qt::EditRole);
+
+    // Perform write operation
+    // Returns true on success, false otherwise
+    bool write();
+
+private:
+    QString filename;
+    const QAbstractItemModel *model;
+
+    struct Column
+    {
+        QString title;
+        int column;
+        int role;
+    };
+    QList<Column> columns;
+
+signals:
+
+public slots:
+
+};
+
+#endif // CSVMODELWRITER_H
diff --git a/src/qt/editaddressdialog.cpp b/src/qt/editaddressdialog.cpp
new file mode 100644 (file)
index 0000000..b8e6fe4
--- /dev/null
@@ -0,0 +1,115 @@
+#include "editaddressdialog.h"
+#include "ui_editaddressdialog.h"
+#include "addresstablemodel.h"
+#include "guiutil.h"
+
+#include <QDataWidgetMapper>
+#include <QMessageBox>
+
+EditAddressDialog::EditAddressDialog(Mode mode, QWidget *parent) :
+    QDialog(parent),
+    ui(new Ui::EditAddressDialog), mapper(0), mode(mode), model(0)
+{
+    ui->setupUi(this);
+
+    GUIUtil::setupAddressWidget(ui->addressEdit, this);
+
+    switch(mode)
+    {
+    case NewReceivingAddress:
+        setWindowTitle(tr("New receiving address"));
+        ui->addressEdit->setEnabled(false);
+        break;
+    case NewSendingAddress:
+        setWindowTitle(tr("New sending address"));
+        break;
+    case EditReceivingAddress:
+        setWindowTitle(tr("Edit receiving address"));
+        ui->addressEdit->setDisabled(true);
+        break;
+    case EditSendingAddress:
+        setWindowTitle(tr("Edit sending address"));
+        break;
+    }
+
+    mapper = new QDataWidgetMapper(this);
+    mapper->setSubmitPolicy(QDataWidgetMapper::ManualSubmit);
+}
+
+EditAddressDialog::~EditAddressDialog()
+{
+    delete ui;
+}
+
+void EditAddressDialog::setModel(AddressTableModel *model)
+{
+    this->model = model;
+    mapper->setModel(model);
+    mapper->addMapping(ui->labelEdit, AddressTableModel::Label);
+    mapper->addMapping(ui->addressEdit, AddressTableModel::Address);
+}
+
+void EditAddressDialog::loadRow(int row)
+{
+    mapper->setCurrentIndex(row);
+}
+
+bool EditAddressDialog::saveCurrentRow()
+{
+    switch(mode)
+    {
+    case NewReceivingAddress:
+    case NewSendingAddress:
+        address = model->addRow(
+                mode == NewSendingAddress ? AddressTableModel::Send : AddressTableModel::Receive,
+                ui->labelEdit->text(),
+                ui->addressEdit->text());
+        break;
+    case EditReceivingAddress:
+    case EditSendingAddress:
+        if(mapper->submit())
+        {
+            address = ui->addressEdit->text();
+        }
+        break;
+    }
+    return !address.isEmpty();
+}
+
+void EditAddressDialog::accept()
+{
+    if(!saveCurrentRow())
+    {
+        switch(model->getEditStatus())
+        {
+        case AddressTableModel::DUPLICATE_ADDRESS:
+            QMessageBox::warning(this, windowTitle(),
+                tr("The entered address \"%1\" is already in the address book.").arg(ui->addressEdit->text()),
+                QMessageBox::Ok, QMessageBox::Ok);
+            break;
+        case AddressTableModel::INVALID_ADDRESS:
+            QMessageBox::warning(this, windowTitle(),
+                tr("The entered address \"%1\" is not a valid bitcoin address.").arg(ui->addressEdit->text()),
+                QMessageBox::Ok, QMessageBox::Ok);
+            return;
+        case AddressTableModel::WALLET_UNLOCK_FAILURE:
+            QMessageBox::critical(this, windowTitle(),
+                tr("Could not unlock wallet."),
+                QMessageBox::Ok, QMessageBox::Ok);
+            return;
+        case AddressTableModel::KEY_GENERATION_FAILURE:
+            QMessageBox::critical(this, windowTitle(),
+                tr("New key generation failed."),
+                QMessageBox::Ok, QMessageBox::Ok);
+            return;
+        }
+
+        return;
+    }
+    QDialog::accept();
+}
+
+QString EditAddressDialog::getAddress() const
+{
+    return address;
+}
diff --git a/src/qt/editaddressdialog.h b/src/qt/editaddressdialog.h
new file mode 100644 (file)
index 0000000..81086a4
--- /dev/null
@@ -0,0 +1,47 @@
+#ifndef EDITADDRESSDIALOG_H
+#define EDITADDRESSDIALOG_H
+
+#include <QDialog>
+
+QT_BEGIN_NAMESPACE
+class QDataWidgetMapper;
+QT_END_NAMESPACE
+
+namespace Ui {
+    class EditAddressDialog;
+}
+class AddressTableModel;
+
+class EditAddressDialog : public QDialog
+{
+    Q_OBJECT
+
+public:
+    enum Mode {
+        NewReceivingAddress,
+        NewSendingAddress,
+        EditReceivingAddress,
+        EditSendingAddress
+    };
+
+    explicit EditAddressDialog(Mode mode, QWidget *parent = 0);
+    ~EditAddressDialog();    
+
+    void setModel(AddressTableModel *model);
+    void loadRow(int row);
+
+    void accept();
+
+    QString getAddress() const;
+private:
+    bool saveCurrentRow();
+
+    Ui::EditAddressDialog *ui;
+    QDataWidgetMapper *mapper;
+    Mode mode;
+    AddressTableModel *model;
+
+    QString address;
+};
+
+#endif // EDITADDRESSDIALOG_H
diff --git a/src/qt/forms/aboutdialog.ui b/src/qt/forms/aboutdialog.ui
new file mode 100644 (file)
index 0000000..cf79973
--- /dev/null
@@ -0,0 +1,162 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>AboutDialog</class>
+ <widget class="QDialog" name="AboutDialog">
+  <property name="geometry">
+   <rect>
+    <x>0</x>
+    <y>0</y>
+    <width>593</width>
+    <height>319</height>
+   </rect>
+  </property>
+  <property name="windowTitle">
+   <string>About Bitcoin</string>
+  </property>
+  <layout class="QHBoxLayout" name="horizontalLayout_2">
+   <item>
+    <widget class="QLabel" name="label_4">
+     <property name="sizePolicy">
+      <sizepolicy hsizetype="Preferred" vsizetype="Ignored">
+       <horstretch>0</horstretch>
+       <verstretch>0</verstretch>
+      </sizepolicy>
+     </property>
+     <property name="text">
+      <string/>
+     </property>
+     <property name="pixmap">
+      <pixmap resource="../bitcoin.qrc">:/images/about</pixmap>
+     </property>
+    </widget>
+   </item>
+   <item>
+    <layout class="QVBoxLayout" name="verticalLayout_2">
+     <item>
+      <spacer name="verticalSpacer_2">
+       <property name="orientation">
+        <enum>Qt::Vertical</enum>
+       </property>
+       <property name="sizeHint" stdset="0">
+        <size>
+         <width>20</width>
+         <height>40</height>
+        </size>
+       </property>
+      </spacer>
+     </item>
+     <item>
+      <layout class="QHBoxLayout" name="horizontalLayout">
+       <item>
+        <widget class="QLabel" name="label">
+         <property name="text">
+          <string>&lt;b&gt;Bitcoin&lt;/b&gt; version</string>
+         </property>
+        </widget>
+       </item>
+       <item>
+        <widget class="QLabel" name="versionLabel">
+         <property name="text">
+          <string notr="true">0.3.666-beta</string>
+         </property>
+         <property name="textFormat">
+          <enum>Qt::RichText</enum>
+         </property>
+        </widget>
+       </item>
+       <item>
+        <spacer name="horizontalSpacer">
+         <property name="orientation">
+          <enum>Qt::Horizontal</enum>
+         </property>
+         <property name="sizeHint" stdset="0">
+          <size>
+           <width>40</width>
+           <height>20</height>
+          </size>
+         </property>
+        </spacer>
+       </item>
+      </layout>
+     </item>
+     <item>
+      <widget class="QLabel" name="label_2">
+       <property name="text">
+        <string>Copyright © 2009-2011 Bitcoin Developers
+
+This is experimental software.
+
+Distributed under the MIT/X11 software license, see the accompanying file license.txt or http://www.opensource.org/licenses/mit-license.php.
+
+This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit (http://www.openssl.org/) and cryptographic software written by Eric Young (eay@cryptsoft.com) and UPnP software written by Thomas Bernard.</string>
+       </property>
+       <property name="wordWrap">
+        <bool>true</bool>
+       </property>
+      </widget>
+     </item>
+     <item>
+      <spacer name="verticalSpacer">
+       <property name="orientation">
+        <enum>Qt::Vertical</enum>
+       </property>
+       <property name="sizeHint" stdset="0">
+        <size>
+         <width>20</width>
+         <height>40</height>
+        </size>
+       </property>
+      </spacer>
+     </item>
+     <item>
+      <widget class="QDialogButtonBox" name="buttonBox">
+       <property name="orientation">
+        <enum>Qt::Horizontal</enum>
+       </property>
+       <property name="standardButtons">
+        <set>QDialogButtonBox::Ok</set>
+       </property>
+      </widget>
+     </item>
+    </layout>
+   </item>
+  </layout>
+ </widget>
+ <resources>
+  <include location="../bitcoin.qrc"/>
+ </resources>
+ <connections>
+  <connection>
+   <sender>buttonBox</sender>
+   <signal>accepted()</signal>
+   <receiver>AboutDialog</receiver>
+   <slot>accept()</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>360</x>
+     <y>308</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>157</x>
+     <y>274</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>buttonBox</sender>
+   <signal>rejected()</signal>
+   <receiver>AboutDialog</receiver>
+   <slot>reject()</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>428</x>
+     <y>308</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>286</x>
+     <y>274</y>
+    </hint>
+   </hints>
+  </connection>
+ </connections>
+</ui>
diff --git a/src/qt/forms/addressbookpage.ui b/src/qt/forms/addressbookpage.ui
new file mode 100644 (file)
index 0000000..fb098c8
--- /dev/null
@@ -0,0 +1,130 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>AddressBookPage</class>
+ <widget class="QWidget" name="AddressBookPage">
+  <property name="geometry">
+   <rect>
+    <x>0</x>
+    <y>0</y>
+    <width>627</width>
+    <height>347</height>
+   </rect>
+  </property>
+  <property name="windowTitle">
+   <string>Address Book</string>
+  </property>
+  <layout class="QVBoxLayout" name="verticalLayout">
+   <item>
+    <widget class="QLabel" name="labelExplanation">
+     <property name="text">
+      <string>These are your Bitcoin addresses for receiving payments.  You may want to give a different one to each sender so you can keep track of who is paying you.</string>
+     </property>
+     <property name="textFormat">
+      <enum>Qt::AutoText</enum>
+     </property>
+     <property name="wordWrap">
+      <bool>true</bool>
+     </property>
+    </widget>
+   </item>
+   <item>
+    <widget class="QTableView" name="tableView">
+     <property name="toolTip">
+      <string>Double-click to edit address or label</string>
+     </property>
+     <property name="alternatingRowColors">
+      <bool>true</bool>
+     </property>
+     <property name="selectionMode">
+      <enum>QAbstractItemView::SingleSelection</enum>
+     </property>
+     <property name="selectionBehavior">
+      <enum>QAbstractItemView::SelectRows</enum>
+     </property>
+     <property name="sortingEnabled">
+      <bool>true</bool>
+     </property>
+     <attribute name="verticalHeaderVisible">
+      <bool>false</bool>
+     </attribute>
+    </widget>
+   </item>
+   <item>
+    <layout class="QHBoxLayout" name="horizontalLayout">
+     <item>
+      <widget class="QPushButton" name="newAddressButton">
+       <property name="toolTip">
+        <string>Create a new address</string>
+       </property>
+       <property name="text">
+        <string>&amp;New Address...</string>
+       </property>
+       <property name="icon">
+        <iconset resource="../bitcoin.qrc">
+         <normaloff>:/icons/add</normaloff>:/icons/add</iconset>
+       </property>
+      </widget>
+     </item>
+     <item>
+      <widget class="QPushButton" name="copyToClipboard">
+       <property name="toolTip">
+        <string>Copy the currently selected address to the system clipboard</string>
+       </property>
+       <property name="text">
+        <string>&amp;Copy to Clipboard</string>
+       </property>
+       <property name="icon">
+        <iconset resource="../bitcoin.qrc">
+         <normaloff>:/icons/editcopy</normaloff>:/icons/editcopy</iconset>
+       </property>
+      </widget>
+     </item>
+     <item>
+      <widget class="QPushButton" name="deleteButton">
+       <property name="toolTip">
+        <string>Delete the currently selected address from the list. Only sending addresses can be deleted.</string>
+       </property>
+       <property name="text">
+        <string>&amp;Delete</string>
+       </property>
+       <property name="icon">
+        <iconset resource="../bitcoin.qrc">
+         <normaloff>:/icons/remove</normaloff>:/icons/remove</iconset>
+       </property>
+      </widget>
+     </item>
+     <item>
+      <spacer name="horizontalSpacer">
+       <property name="orientation">
+        <enum>Qt::Horizontal</enum>
+       </property>
+       <property name="sizeHint" stdset="0">
+        <size>
+         <width>40</width>
+         <height>20</height>
+        </size>
+       </property>
+      </spacer>
+     </item>
+     <item>
+      <widget class="QDialogButtonBox" name="buttonBox">
+       <property name="sizePolicy">
+        <sizepolicy hsizetype="Maximum" vsizetype="Fixed">
+         <horstretch>0</horstretch>
+         <verstretch>0</verstretch>
+        </sizepolicy>
+       </property>
+       <property name="standardButtons">
+        <set>QDialogButtonBox::Ok</set>
+       </property>
+      </widget>
+     </item>
+    </layout>
+   </item>
+  </layout>
+ </widget>
+ <resources>
+  <include location="../bitcoin.qrc"/>
+ </resources>
+ <connections/>
+</ui>
diff --git a/src/qt/forms/askpassphrasedialog.ui b/src/qt/forms/askpassphrasedialog.ui
new file mode 100644 (file)
index 0000000..70d9180
--- /dev/null
@@ -0,0 +1,148 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>AskPassphraseDialog</class>
+ <widget class="QDialog" name="AskPassphraseDialog">
+  <property name="geometry">
+   <rect>
+    <x>0</x>
+    <y>0</y>
+    <width>589</width>
+    <height>228</height>
+   </rect>
+  </property>
+  <property name="sizePolicy">
+   <sizepolicy hsizetype="Preferred" vsizetype="Minimum">
+    <horstretch>0</horstretch>
+    <verstretch>0</verstretch>
+   </sizepolicy>
+  </property>
+  <property name="minimumSize">
+   <size>
+    <width>550</width>
+    <height>0</height>
+   </size>
+  </property>
+  <property name="windowTitle">
+   <string>Dialog</string>
+  </property>
+  <layout class="QVBoxLayout" name="verticalLayout">
+   <item>
+    <widget class="QLabel" name="warningLabel">
+     <property name="text">
+      <string>TextLabel</string>
+     </property>
+     <property name="textFormat">
+      <enum>Qt::RichText</enum>
+     </property>
+    </widget>
+   </item>
+   <item>
+    <layout class="QFormLayout" name="formLayout">
+     <property name="fieldGrowthPolicy">
+      <enum>QFormLayout::AllNonFixedFieldsGrow</enum>
+     </property>
+     <item row="1" column="0">
+      <widget class="QLabel" name="passLabel1">
+       <property name="text">
+        <string>Enter passphrase</string>
+       </property>
+      </widget>
+     </item>
+     <item row="1" column="1">
+      <widget class="QLineEdit" name="passEdit1">
+       <property name="echoMode">
+        <enum>QLineEdit::Password</enum>
+       </property>
+      </widget>
+     </item>
+     <item row="2" column="0">
+      <widget class="QLabel" name="passLabel2">
+       <property name="text">
+        <string>New passphrase</string>
+       </property>
+      </widget>
+     </item>
+     <item row="2" column="1">
+      <widget class="QLineEdit" name="passEdit2">
+       <property name="echoMode">
+        <enum>QLineEdit::Password</enum>
+       </property>
+      </widget>
+     </item>
+     <item row="3" column="0">
+      <widget class="QLabel" name="passLabel3">
+       <property name="text">
+        <string>Repeat new passphrase</string>
+       </property>
+      </widget>
+     </item>
+     <item row="3" column="1">
+      <widget class="QLineEdit" name="passEdit3">
+       <property name="echoMode">
+        <enum>QLineEdit::Password</enum>
+       </property>
+      </widget>
+     </item>
+    </layout>
+   </item>
+   <item>
+    <spacer name="verticalSpacer">
+     <property name="orientation">
+      <enum>Qt::Vertical</enum>
+     </property>
+     <property name="sizeHint" stdset="0">
+      <size>
+       <width>20</width>
+       <height>40</height>
+      </size>
+     </property>
+    </spacer>
+   </item>
+   <item>
+    <widget class="QDialogButtonBox" name="buttonBox">
+     <property name="orientation">
+      <enum>Qt::Horizontal</enum>
+     </property>
+     <property name="standardButtons">
+      <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
+     </property>
+    </widget>
+   </item>
+  </layout>
+ </widget>
+ <resources/>
+ <connections>
+  <connection>
+   <sender>buttonBox</sender>
+   <signal>accepted()</signal>
+   <receiver>AskPassphraseDialog</receiver>
+   <slot>accept()</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>248</x>
+     <y>254</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>157</x>
+     <y>274</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>buttonBox</sender>
+   <signal>rejected()</signal>
+   <receiver>AskPassphraseDialog</receiver>
+   <slot>reject()</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>316</x>
+     <y>260</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>286</x>
+     <y>274</y>
+    </hint>
+   </hints>
+  </connection>
+ </connections>
+</ui>
diff --git a/src/qt/forms/editaddressdialog.ui b/src/qt/forms/editaddressdialog.ui
new file mode 100644 (file)
index 0000000..b4a4c1b
--- /dev/null
@@ -0,0 +1,105 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>EditAddressDialog</class>
+ <widget class="QDialog" name="EditAddressDialog">
+  <property name="geometry">
+   <rect>
+    <x>0</x>
+    <y>0</y>
+    <width>457</width>
+    <height>126</height>
+   </rect>
+  </property>
+  <property name="windowTitle">
+   <string>Edit Address</string>
+  </property>
+  <layout class="QVBoxLayout" name="verticalLayout">
+   <item>
+    <layout class="QFormLayout" name="formLayout">
+     <property name="fieldGrowthPolicy">
+      <enum>QFormLayout::AllNonFixedFieldsGrow</enum>
+     </property>
+     <item row="0" column="0">
+      <widget class="QLabel" name="label">
+       <property name="text">
+        <string>&amp;Label</string>
+       </property>
+       <property name="buddy">
+        <cstring>labelEdit</cstring>
+       </property>
+      </widget>
+     </item>
+     <item row="0" column="1">
+      <widget class="QLineEdit" name="labelEdit">
+       <property name="toolTip">
+        <string>The label associated with this address book entry</string>
+       </property>
+      </widget>
+     </item>
+     <item row="1" column="0">
+      <widget class="QLabel" name="label_2">
+       <property name="text">
+        <string>&amp;Address</string>
+       </property>
+       <property name="buddy">
+        <cstring>addressEdit</cstring>
+       </property>
+      </widget>
+     </item>
+     <item row="1" column="1">
+      <widget class="QLineEdit" name="addressEdit">
+       <property name="toolTip">
+        <string>The address associated with this address book entry. This can only be modified for sending addresses.</string>
+       </property>
+      </widget>
+     </item>
+    </layout>
+   </item>
+   <item>
+    <widget class="QDialogButtonBox" name="buttonBox">
+     <property name="orientation">
+      <enum>Qt::Horizontal</enum>
+     </property>
+     <property name="standardButtons">
+      <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
+     </property>
+    </widget>
+   </item>
+  </layout>
+ </widget>
+ <resources/>
+ <connections>
+  <connection>
+   <sender>buttonBox</sender>
+   <signal>accepted()</signal>
+   <receiver>EditAddressDialog</receiver>
+   <slot>accept()</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>248</x>
+     <y>254</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>157</x>
+     <y>274</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>buttonBox</sender>
+   <signal>rejected()</signal>
+   <receiver>EditAddressDialog</receiver>
+   <slot>reject()</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>316</x>
+     <y>260</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>286</x>
+     <y>274</y>
+    </hint>
+   </hints>
+  </connection>
+ </connections>
+</ui>
diff --git a/src/qt/forms/overviewpage.ui b/src/qt/forms/overviewpage.ui
new file mode 100644 (file)
index 0000000..cc67fae
--- /dev/null
@@ -0,0 +1,161 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>OverviewPage</class>
+ <widget class="QWidget" name="OverviewPage">
+  <property name="geometry">
+   <rect>
+    <x>0</x>
+    <y>0</y>
+    <width>552</width>
+    <height>342</height>
+   </rect>
+  </property>
+  <property name="windowTitle">
+   <string>Form</string>
+  </property>
+  <layout class="QHBoxLayout" name="horizontalLayout" stretch="1,1">
+   <item>
+    <layout class="QVBoxLayout" name="verticalLayout_2">
+     <item>
+      <widget class="QFrame" name="frame">
+       <property name="frameShape">
+        <enum>QFrame::StyledPanel</enum>
+       </property>
+       <property name="frameShadow">
+        <enum>QFrame::Raised</enum>
+       </property>
+       <layout class="QFormLayout" name="formLayout_2">
+        <property name="fieldGrowthPolicy">
+         <enum>QFormLayout::AllNonFixedFieldsGrow</enum>
+        </property>
+        <property name="horizontalSpacing">
+         <number>12</number>
+        </property>
+        <property name="verticalSpacing">
+         <number>12</number>
+        </property>
+        <item row="2" column="0">
+         <widget class="QLabel" name="label">
+          <property name="text">
+           <string>Balance:</string>
+          </property>
+         </widget>
+        </item>
+        <item row="2" column="1">
+         <widget class="QLabel" name="labelBalance">
+          <property name="text">
+           <string>123.456 BTC</string>
+          </property>
+         </widget>
+        </item>
+        <item row="4" column="0">
+         <widget class="QLabel" name="label_2">
+          <property name="text">
+           <string>Number of transactions:</string>
+          </property>
+         </widget>
+        </item>
+        <item row="4" column="1">
+         <widget class="QLabel" name="labelNumTransactions">
+          <property name="text">
+           <string>0</string>
+          </property>
+         </widget>
+        </item>
+        <item row="3" column="0">
+         <widget class="QLabel" name="label_3">
+          <property name="text">
+           <string>Unconfirmed:</string>
+          </property>
+         </widget>
+        </item>
+        <item row="3" column="1">
+         <widget class="QLabel" name="labelUnconfirmed">
+          <property name="text">
+           <string>0 BTC</string>
+          </property>
+         </widget>
+        </item>
+        <item row="1" column="0">
+         <widget class="QLabel" name="label_5">
+          <property name="text">
+           <string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
+&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
+p, li { white-space: pre-wrap; }
+&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Ubuntu'; font-size:11pt; font-weight:400; font-style:normal;&quot;&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-weight:600;&quot;&gt;Wallet&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
+          </property>
+         </widget>
+        </item>
+       </layout>
+      </widget>
+     </item>
+     <item>
+      <spacer name="verticalSpacer">
+       <property name="orientation">
+        <enum>Qt::Vertical</enum>
+       </property>
+       <property name="sizeHint" stdset="0">
+        <size>
+         <width>20</width>
+         <height>40</height>
+        </size>
+       </property>
+      </spacer>
+     </item>
+    </layout>
+   </item>
+   <item>
+    <layout class="QVBoxLayout" name="verticalLayout_3">
+     <item>
+      <widget class="QFrame" name="frame_2">
+       <property name="frameShape">
+        <enum>QFrame::StyledPanel</enum>
+       </property>
+       <property name="frameShadow">
+        <enum>QFrame::Raised</enum>
+       </property>
+       <layout class="QVBoxLayout" name="verticalLayout">
+        <item>
+         <widget class="QLabel" name="label_4">
+          <property name="text">
+           <string>&lt;b&gt;Recent transactions&lt;/b&gt;</string>
+          </property>
+         </widget>
+        </item>
+        <item>
+         <widget class="QListView" name="listTransactions">
+          <property name="frameShape">
+           <enum>QFrame::NoFrame</enum>
+          </property>
+          <property name="verticalScrollBarPolicy">
+           <enum>Qt::ScrollBarAlwaysOff</enum>
+          </property>
+          <property name="horizontalScrollBarPolicy">
+           <enum>Qt::ScrollBarAlwaysOff</enum>
+          </property>
+         </widget>
+        </item>
+       </layout>
+      </widget>
+     </item>
+     <item>
+      <spacer name="verticalSpacer_2">
+       <property name="orientation">
+        <enum>Qt::Vertical</enum>
+       </property>
+       <property name="sizeHint" stdset="0">
+        <size>
+         <width>20</width>
+         <height>40</height>
+        </size>
+       </property>
+      </spacer>
+     </item>
+    </layout>
+   </item>
+  </layout>
+ </widget>
+ <resources/>
+ <connections/>
+</ui>
diff --git a/src/qt/forms/sendcoinsdialog.ui b/src/qt/forms/sendcoinsdialog.ui
new file mode 100644 (file)
index 0000000..5b30d99
--- /dev/null
@@ -0,0 +1,122 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>SendCoinsDialog</class>
+ <widget class="QDialog" name="SendCoinsDialog">
+  <property name="geometry">
+   <rect>
+    <x>0</x>
+    <y>0</y>
+    <width>686</width>
+    <height>217</height>
+   </rect>
+  </property>
+  <property name="windowTitle">
+   <string>Send Coins</string>
+  </property>
+  <layout class="QVBoxLayout" name="verticalLayout">
+   <item>
+    <widget class="QScrollArea" name="scrollArea">
+     <property name="widgetResizable">
+      <bool>true</bool>
+     </property>
+     <widget class="QWidget" name="scrollAreaWidgetContents">
+      <property name="geometry">
+       <rect>
+        <x>0</x>
+        <y>0</y>
+        <width>666</width>
+        <height>162</height>
+       </rect>
+      </property>
+      <layout class="QVBoxLayout" name="verticalLayout_2">
+       <property name="margin">
+        <number>0</number>
+       </property>
+       <item>
+        <layout class="QVBoxLayout" name="entries">
+         <property name="spacing">
+          <number>6</number>
+         </property>
+        </layout>
+       </item>
+       <item>
+        <spacer name="verticalSpacer">
+         <property name="orientation">
+          <enum>Qt::Vertical</enum>
+         </property>
+         <property name="sizeHint" stdset="0">
+          <size>
+           <width>20</width>
+           <height>40</height>
+          </size>
+         </property>
+        </spacer>
+       </item>
+      </layout>
+     </widget>
+    </widget>
+   </item>
+   <item>
+    <layout class="QHBoxLayout" name="horizontalLayout">
+     <property name="spacing">
+      <number>12</number>
+     </property>
+     <item>
+      <widget class="QPushButton" name="addButton">
+       <property name="toolTip">
+        <string>Send to multiple recipients at once</string>
+       </property>
+       <property name="text">
+        <string>&amp;Add recipient...</string>
+       </property>
+       <property name="icon">
+        <iconset resource="../bitcoin.qrc">
+         <normaloff>:/icons/add</normaloff>:/icons/add</iconset>
+       </property>
+      </widget>
+     </item>
+     <item>
+      <spacer name="horizontalSpacer">
+       <property name="orientation">
+        <enum>Qt::Horizontal</enum>
+       </property>
+       <property name="sizeHint" stdset="0">
+        <size>
+         <width>40</width>
+         <height>20</height>
+        </size>
+       </property>
+      </spacer>
+     </item>
+     <item>
+      <widget class="QPushButton" name="sendButton">
+       <property name="minimumSize">
+        <size>
+         <width>150</width>
+         <height>0</height>
+        </size>
+       </property>
+       <property name="toolTip">
+        <string>Confirm the send action</string>
+       </property>
+       <property name="text">
+        <string>&amp;Send</string>
+       </property>
+       <property name="icon">
+        <iconset resource="../bitcoin.qrc">
+         <normaloff>:/icons/send</normaloff>:/icons/send</iconset>
+       </property>
+       <property name="default">
+        <bool>true</bool>
+       </property>
+      </widget>
+     </item>
+    </layout>
+   </item>
+  </layout>
+ </widget>
+ <resources>
+  <include location="../bitcoin.qrc"/>
+ </resources>
+ <connections/>
+</ui>
diff --git a/src/qt/forms/sendcoinsentry.ui b/src/qt/forms/sendcoinsentry.ui
new file mode 100644 (file)
index 0000000..13593c2
--- /dev/null
@@ -0,0 +1,178 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>SendCoinsEntry</class>
+ <widget class="QFrame" name="SendCoinsEntry">
+  <property name="geometry">
+   <rect>
+    <x>0</x>
+    <y>0</y>
+    <width>729</width>
+    <height>136</height>
+   </rect>
+  </property>
+  <property name="windowTitle">
+   <string>Form</string>
+  </property>
+  <property name="frameShape">
+   <enum>QFrame::StyledPanel</enum>
+  </property>
+  <property name="frameShadow">
+   <enum>QFrame::Sunken</enum>
+  </property>
+  <layout class="QGridLayout" name="gridLayout">
+   <property name="spacing">
+    <number>12</number>
+   </property>
+   <item row="5" column="0">
+    <widget class="QLabel" name="label">
+     <property name="text">
+      <string>A&amp;mount:</string>
+     </property>
+     <property name="alignment">
+      <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+     </property>
+     <property name="buddy">
+      <cstring>payAmount</cstring>
+     </property>
+    </widget>
+   </item>
+   <item row="3" column="0">
+    <widget class="QLabel" name="label_2">
+     <property name="text">
+      <string>Pay &amp;To:</string>
+     </property>
+     <property name="alignment">
+      <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+     </property>
+     <property name="buddy">
+      <cstring>payTo</cstring>
+     </property>
+    </widget>
+   </item>
+   <item row="5" column="1">
+    <widget class="BitcoinAmountField" name="payAmount"/>
+   </item>
+   <item row="4" column="1">
+    <layout class="QHBoxLayout" name="horizontalLayout_2">
+     <property name="spacing">
+      <number>0</number>
+     </property>
+     <item>
+      <widget class="QValidatedLineEdit" name="addAsLabel">
+       <property name="enabled">
+        <bool>true</bool>
+       </property>
+       <property name="toolTip">
+        <string>Enter a label for this address to add it to your address book</string>
+       </property>
+      </widget>
+     </item>
+    </layout>
+   </item>
+   <item row="4" column="0">
+    <widget class="QLabel" name="label_4">
+     <property name="text">
+      <string>&amp;Label:</string>
+     </property>
+     <property name="alignment">
+      <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
+     </property>
+     <property name="buddy">
+      <cstring>addAsLabel</cstring>
+     </property>
+    </widget>
+   </item>
+   <item row="3" column="1">
+    <layout class="QHBoxLayout" name="horizontalLayout_3">
+     <property name="spacing">
+      <number>0</number>
+     </property>
+     <item>
+      <widget class="QValidatedLineEdit" name="payTo">
+       <property name="toolTip">
+        <string>The address to send the payment to  (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</string>
+       </property>
+       <property name="maxLength">
+        <number>34</number>
+       </property>
+      </widget>
+     </item>
+     <item>
+      <widget class="QPushButton" name="addressBookButton">
+       <property name="toolTip">
+        <string>Choose adress from address book</string>
+       </property>
+       <property name="text">
+        <string/>
+       </property>
+       <property name="icon">
+        <iconset resource="../bitcoin.qrc">
+         <normaloff>:/icons/address-book</normaloff>:/icons/address-book</iconset>
+       </property>
+       <property name="shortcut">
+        <string>Alt+A</string>
+       </property>
+       <property name="autoDefault">
+        <bool>false</bool>
+       </property>
+       <property name="flat">
+        <bool>false</bool>
+       </property>
+      </widget>
+     </item>
+     <item>
+      <widget class="QPushButton" name="pasteButton">
+       <property name="toolTip">
+        <string>Paste address from clipboard</string>
+       </property>
+       <property name="text">
+        <string/>
+       </property>
+       <property name="icon">
+        <iconset resource="../bitcoin.qrc">
+         <normaloff>:/icons/editpaste</normaloff>:/icons/editpaste</iconset>
+       </property>
+       <property name="shortcut">
+        <string>Alt+P</string>
+       </property>
+       <property name="autoDefault">
+        <bool>false</bool>
+       </property>
+      </widget>
+     </item>
+     <item>
+      <widget class="QPushButton" name="deleteButton">
+       <property name="toolTip">
+        <string>Remove this recipient</string>
+       </property>
+       <property name="text">
+        <string/>
+       </property>
+       <property name="icon">
+        <iconset resource="../bitcoin.qrc">
+         <normaloff>:/icons/remove</normaloff>:/icons/remove</iconset>
+       </property>
+      </widget>
+     </item>
+    </layout>
+   </item>
+  </layout>
+ </widget>
+ <customwidgets>
+  <customwidget>
+   <class>BitcoinAmountField</class>
+   <extends>QLineEdit</extends>
+   <header>bitcoinamountfield.h</header>
+   <container>1</container>
+  </customwidget>
+  <customwidget>
+   <class>QValidatedLineEdit</class>
+   <extends>QLineEdit</extends>
+   <header>qvalidatedlineedit.h</header>
+  </customwidget>
+ </customwidgets>
+ <resources>
+  <include location="../bitcoin.qrc"/>
+ </resources>
+ <connections/>
+</ui>
diff --git a/src/qt/forms/transactiondescdialog.ui b/src/qt/forms/transactiondescdialog.ui
new file mode 100644 (file)
index 0000000..2f70a38
--- /dev/null
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
+ <class>TransactionDescDialog</class>
+ <widget class="QDialog" name="TransactionDescDialog">
+  <property name="geometry">
+   <rect>
+    <x>0</x>
+    <y>0</y>
+    <width>400</width>
+    <height>300</height>
+   </rect>
+  </property>
+  <property name="windowTitle">
+   <string>Transaction details</string>
+  </property>
+  <layout class="QVBoxLayout" name="verticalLayout">
+   <item>
+    <widget class="QTextEdit" name="detailText">
+     <property name="toolTip">
+      <string>This pane shows a detailed description of the transaction</string>
+     </property>
+    </widget>
+   </item>
+   <item>
+    <widget class="QDialogButtonBox" name="buttonBox">
+     <property name="orientation">
+      <enum>Qt::Horizontal</enum>
+     </property>
+     <property name="standardButtons">
+      <set>QDialogButtonBox::Close</set>
+     </property>
+    </widget>
+   </item>
+  </layout>
+ </widget>
+ <resources/>
+ <connections>
+  <connection>
+   <sender>buttonBox</sender>
+   <signal>accepted()</signal>
+   <receiver>TransactionDescDialog</receiver>
+   <slot>accept()</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>248</x>
+     <y>254</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>157</x>
+     <y>274</y>
+    </hint>
+   </hints>
+  </connection>
+  <connection>
+   <sender>buttonBox</sender>
+   <signal>rejected()</signal>
+   <receiver>TransactionDescDialog</receiver>
+   <slot>reject()</slot>
+   <hints>
+    <hint type="sourcelabel">
+     <x>316</x>
+     <y>260</y>
+    </hint>
+    <hint type="destinationlabel">
+     <x>286</x>
+     <y>274</y>
+    </hint>
+   </hints>
+  </connection>
+ </connections>
+</ui>
diff --git a/src/qt/guiconstants.h b/src/qt/guiconstants.h
new file mode 100644 (file)
index 0000000..0cb5075
--- /dev/null
@@ -0,0 +1,23 @@
+#ifndef GUICONSTANTS_H
+#define GUICONSTANTS_H
+
+/* Milliseconds between model updates */
+static const int MODEL_UPDATE_DELAY = 500;
+
+/* Maximum  passphrase length */
+static const int MAX_PASSPHRASE_SIZE = 1024;
+
+/* Size of icons in status bar */
+static const int STATUSBAR_ICONSIZE = 16;
+
+/* Invalid field background style */
+#define STYLE_INVALID "background:#FF8080"
+
+/* Transaction list -- unconfirmed transaction */
+#define COLOR_UNCONFIRMED QColor(128, 128, 128)
+/* Transaction list -- negative amount */
+#define COLOR_NEGATIVE QColor(255, 0, 0)
+/* Transaction list -- bare address (without label) */
+#define COLOR_BAREADDRESS QColor(140, 140, 140)
+
+#endif // GUICONSTANTS_H
diff --git a/src/qt/guiutil.cpp b/src/qt/guiutil.cpp
new file mode 100644 (file)
index 0000000..158b84a
--- /dev/null
@@ -0,0 +1,74 @@
+#include "guiutil.h"
+#include "bitcoinaddressvalidator.h"
+#include "walletmodel.h"
+#include "bitcoinunits.h"
+
+#include "headers.h"
+
+#include <QString>
+#include <QDateTime>
+#include <QDoubleValidator>
+#include <QFont>
+#include <QLineEdit>
+#include <QUrl>
+
+QString GUIUtil::dateTimeStr(qint64 nTime)
+{
+    return dateTimeStr(QDateTime::fromTime_t((qint32)nTime));
+}
+
+QString GUIUtil::dateTimeStr(const QDateTime &date)
+{
+    return date.date().toString(Qt::SystemLocaleShortDate) + QString(" ") + date.toString("hh:mm");
+}
+
+QFont GUIUtil::bitcoinAddressFont()
+{
+    QFont font("Monospace");
+    font.setStyleHint(QFont::TypeWriter);
+    return font;
+}
+
+void GUIUtil::setupAddressWidget(QLineEdit *widget, QWidget *parent)
+{
+    widget->setMaxLength(BitcoinAddressValidator::MaxAddressLength);
+    widget->setValidator(new BitcoinAddressValidator(parent));
+    widget->setFont(bitcoinAddressFont());
+}
+
+void GUIUtil::setupAmountWidget(QLineEdit *widget, QWidget *parent)
+{
+    QDoubleValidator *amountValidator = new QDoubleValidator(parent);
+    amountValidator->setDecimals(8);
+    amountValidator->setBottom(0.0);
+    widget->setValidator(amountValidator);
+    widget->setAlignment(Qt::AlignRight|Qt::AlignVCenter);
+}
+
+bool GUIUtil::parseBitcoinURL(const QUrl *url, SendCoinsRecipient *out)
+{
+    if(url->scheme() != QString("bitcoin"))
+        return false;
+
+    SendCoinsRecipient rv;
+    rv.address = url->path();
+    rv.label = url->queryItemValue("label");
+
+    QString amount = url->queryItemValue("amount");
+    if(amount.isEmpty())
+    {
+        rv.amount = 0;
+    }
+    else // Amount is non-empty
+    {
+        if(!BitcoinUnits::parse(BitcoinUnits::BTC, amount, &rv.amount))
+        {
+            return false;
+        }
+    }
+    if(out)
+    {
+        *out = rv;
+    }
+    return true;
+}
diff --git a/src/qt/guiutil.h b/src/qt/guiutil.h
new file mode 100644 (file)
index 0000000..bc4ddb8
--- /dev/null
@@ -0,0 +1,34 @@
+#ifndef GUIUTIL_H
+#define GUIUTIL_H
+
+#include <QString>
+
+QT_BEGIN_NAMESPACE
+class QFont;
+class QLineEdit;
+class QWidget;
+class QDateTime;
+class QUrl;
+QT_END_NAMESPACE
+class SendCoinsRecipient;
+
+class GUIUtil
+{
+public:
+    // Create human-readable string from date
+    static QString dateTimeStr(qint64 nTime);
+    static QString dateTimeStr(const QDateTime &datetime);
+
+    // Render bitcoin addresses in monospace font
+    static QFont bitcoinAddressFont();
+
+    // Set up widgets for address and amounts
+    static void setupAddressWidget(QLineEdit *widget, QWidget *parent);
+    static void setupAmountWidget(QLineEdit *widget, QWidget *parent);
+
+    // Parse "bitcoin:" URL into recipient object, return true on succesful parsing
+    // See Bitcoin URL definition discussion here: https://bitcointalk.org/index.php?topic=33490.0
+    static bool parseBitcoinURL(const QUrl *url, SendCoinsRecipient *out);
+};
+
+#endif // GUIUTIL_H
diff --git a/src/qt/locale/bitcoin_de.ts b/src/qt/locale/bitcoin_de.ts
new file mode 100644 (file)
index 0000000..1978f06
--- /dev/null
@@ -0,0 +1,1155 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.0" language="de_DE">
+<defaultcodec>UTF-8</defaultcodec>
+<context>
+    <name>AboutDialog</name>
+    <message>
+        <location filename="../forms/aboutdialog.ui" line="14"/>
+        <source>About Bitcoin</source>
+        <translation>Über Bitcoin</translation>
+    </message>
+    <message>
+        <location filename="../forms/aboutdialog.ui" line="53"/>
+        <source>&lt;b&gt;Bitcoin&lt;/b&gt; version</source>
+        <translation>&lt;b&gt;Bitcoin&lt;/b&gt; Version</translation>
+    </message>
+    <message>
+        <location filename="../forms/aboutdialog.ui" line="85"/>
+        <source>Copyright © 2009-2011 Bitcoin Developers
+
+This is experimental software.
+
+Distributed under the MIT/X11 software license, see the accompanying file license.txt or http://www.opensource.org/licenses/mit-license.php.
+
+This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit (http://www.openssl.org/) and cryptographic software written by Eric Young (eay@cryptsoft.com) and UPnP software written by Thomas Bernard.</source>
+        <translation>Copyright © 2009-2011 Bitcoin Developers
+
+Dies ist experimentelle Software.
+
+Veröffentlicht unter der MIT/X11 Software-Lizenz. Sie können diese in der beiligenden Datei license.txt oder unter http://www.opensource.org/licenses/mit-license.php nachlesen.
+
+Dieses Produkt enthält Software, welche vom OpenSSL Projekt zur Verwendung im OpenSSL Toolkit (http://www.openssl.org/) entwickelt wurde, kryptographische Software von Eric Young (eay@cryptsoft.com) und UPnP Software von Thomas-Bernard.</translation>
+    </message>
+</context>
+<context>
+    <name>AddressBookPage</name>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="14"/>
+        <source>Address Book</source>
+        <translation>Adressbuch</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="20"/>
+        <source>These are your Bitcoin addresses for receiving payments.  You may want to give a different one to each sender so you can keep track of who is paying you.</source>
+        <translation>Dies sind ihre Bitcoin-Adressen zum empfangen von Zahlungen. Um Ihre Zahlungen zurückverfolgen zu können ist es möglich jedem Sender eine andere Empfangsaddresse mitzuteilen.</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="33"/>
+        <source>Double-click to edit address or label</source>
+        <translation>Doppelklick zum Ändern der Adresse oder Beschreibung</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="57"/>
+        <source>Create a new address</source>
+        <translation>Neue Adresse erstellen</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="60"/>
+        <source>&amp;New Address...</source>
+        <translation>&amp;Neue Adresse...</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="71"/>
+        <source>Copy the currently selected address to the system clipboard</source>
+        <translation>Ausgewählte Adresse in die Zwischenablage kopieren</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="74"/>
+        <source>&amp;Copy to Clipboard</source>
+        <translation>&amp;In die Zwischenablage kopieren</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="85"/>
+        <source>Delete the currently selected address from the list. Only sending addresses can be deleted.</source>
+        <translation>Die ausgewählte Adresse aus der Liste entfernen. Sie können nur ausgehende Adressen entfernen.</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="88"/>
+        <source>&amp;Delete</source>
+        <translation>&amp;Löschen</translation>
+    </message>
+</context>
+<context>
+    <name>AddressTableModel</name>
+    <message>
+        <location filename="../addresstablemodel.cpp" line="78"/>
+        <source>Label</source>
+        <translation>Bezeichnung</translation>
+    </message>
+    <message>
+        <location filename="../addresstablemodel.cpp" line="78"/>
+        <source>Address</source>
+        <translation>Adresse</translation>
+    </message>
+    <message>
+        <location filename="../addresstablemodel.cpp" line="114"/>
+        <source>(no label)</source>
+        <translation>(keine Bezeichnung)</translation>
+    </message>
+</context>
+<context>
+    <name>BitcoinGUI</name>
+    <message>
+        <location filename="../bitcoingui.cpp" line="50"/>
+        <source>Bitcoin Wallet</source>
+        <translation>Bitcoin Wallet</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="112"/>
+        <source>Number of connections to other clients</source>
+        <translation>Anzahl der Verbindungen zu anderen Clients</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="117"/>
+        <source>Number of blocks in the block chain</source>
+        <translation>Anzahl der Blöcke in der Block-Chain</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="120"/>
+        <source>Synchronizing with network...</source>
+        <translation>Mit Netzwerk synchronisieren...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="123"/>
+        <source>Block chain synchronization in progress</source>
+        <translation>Synchronisierung der Block-Chain...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="140"/>
+        <source>&amp;Overview</source>
+        <translation>Übersicht</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="144"/>
+        <source>&amp;Transactions</source>
+        <translation>Transaktionen</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="148"/>
+        <source>&amp;Address Book</source>
+        <translation>Adressbuch</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="149"/>
+        <source>Edit the list of stored addresses and labels</source>
+        <translation>Adressen bearbeiten</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="153"/>
+        <source>&amp;Receive coins</source>
+        <translation>Bitcoins empfangen</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="154"/>
+        <source>Show the list of addresses for receiving payments</source>
+        <translation>Empfangsadressen anzeigen</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="158"/>
+        <source>&amp;Send coins</source>
+        <translation>Bitcoins senden</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="159"/>
+        <source>Send coins to a bitcoin address</source>
+        <translation>Bitcoins an eine Bitcoin-Adresse senden</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="169"/>
+        <source>&amp;Exit</source>
+        <translation>Beenden</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="170"/>
+        <source>Quit application</source>
+        <translation>Anwendung beenden</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="171"/>
+        <source>&amp;About</source>
+        <translation>Über</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="172"/>
+        <source>Show information about Bitcoin</source>
+        <translation>Informationen über Bitcoin</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="173"/>
+        <source>&amp;Options...</source>
+        <translation>Einstellungen</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="174"/>
+        <source>Modify configuration options for bitcoin</source>
+        <translation>Einstellungen ändern</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="175"/>
+        <source>Open &amp;Bitcoin</source>
+        <translation>Bitcoin öffnen</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="176"/>
+        <source>Show the Bitcoin window</source>
+        <translation>Bitcoin-Fenster anzeigen</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="177"/>
+        <source>&amp;Export...</source>
+        <translation>Exportieren...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="178"/>
+        <source>Export data in current view to a file</source>
+        <translation>Angezeigte Daten als Datei exportieren</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="193"/>
+        <source>Bitcoin Wallet [testnet]</source>
+        <translation>Bitcoin Wallet [testnet]</translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../bitcoingui.cpp" line="298"/>
+        <source>%n connection(s)</source>
+        <translation>
+            <numerusform>%n Verbindung(en)</numerusform>
+            <numerusform></numerusform>
+        </translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../bitcoingui.cpp" line="317"/>
+        <source>%n block(s)</source>
+        <translation>
+            <numerusform>%n Blöcke</numerusform>
+            <numerusform></numerusform>
+        </translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="375"/>
+        <source>This transaction is over the size limit.  You can still send it for a fee of %1, which goes to the nodes that process your transaction and helps to support the network.  Do you want to pay the fee?</source>
+        <translation>Die Größe dieser Transaktion übersteigt das Limit.
+ Sie können die Coins jedoch senden, wenn sie einen zusätzlichen Betrag von 1% zahlen, 
+welcher an die Teilnehmer des Bitcoin-Netzwerkes ausgeschüttet wird und dieses unterstützt.
+Möchten Sie die zusätzliche Gebühr zahlen?</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="379"/>
+        <source>Sending...</source>
+        <translation>Senden...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="407"/>
+        <source>Incoming transaction</source>
+        <translation>Eingehende Transaktion</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="408"/>
+        <source>Date: </source>
+        <translation>Datum:</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="409"/>
+        <source>Amount: </source>
+        <translation>Betrag:</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="410"/>
+        <source>Type: </source>
+        <translation>Beschreibung:</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="411"/>
+        <source>Address: </source>
+        <translation>Adresse:</translation>
+    </message>
+</context>
+<context>
+    <name>EditAddressDialog</name>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="14"/>
+        <source>Edit Address</source>
+        <translation>Adresse bearbeiten</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="25"/>
+        <source>&amp;Label</source>
+        <translation>Beschreibung</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="35"/>
+        <source>The label associated with this address book entry</source>
+        <translation>Name/Beschreibung des Adressbucheintrags</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="42"/>
+        <source>&amp;Address</source>
+        <translation>Adresse</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="52"/>
+        <source>The address associated with this address book entry. This can only be modified for sending addresses.</source>
+        <translation>Die Adresse des Adressbucheintrag. Diese kann nur für Zahlungsadressen bearbeitet werden.</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="20"/>
+        <source>New receiving address</source>
+        <translation>Neue Empfangsadresse</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="24"/>
+        <source>New sending address</source>
+        <translation>Neue Zahlungsadresse</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="27"/>
+        <source>Edit receiving address</source>
+        <translation>Empfangsadresse bearbeiten</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="31"/>
+        <source>Edit sending address</source>
+        <translation>Zahlungsadresse bearbeiten</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="89"/>
+        <source>The entered address &quot;%1&quot; is not a valid bitcoin address.</source>
+        <translation>Die eingegebene Adresse (&quot;%1&quot;) ist keine gültige Bitcoin-Adresse.</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="97"/>
+        <source>The entered address &quot;%1&quot; is already in the address book.</source>
+        <translation>Die eingegebene Adresse (&quot;%1&quot;) befindet sich bereits in Ihrem Adressbuch.</translation>
+    </message>
+</context>
+<context>
+    <name>MainOptionsPage</name>
+    <message>
+        <location filename="../optionsdialog.cpp" line="142"/>
+        <source>&amp;Start Bitcoin on window system startup</source>
+        <translation>Bitcoin beim Start des Systems ausführen</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="143"/>
+        <source>Automatically start Bitcoin after the computer is turned on</source>
+        <translation>Bitcoin automatisch beim Systemstart ausführen</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="146"/>
+        <source>&amp;Minimize to the tray instead of the taskbar</source>
+        <translation>In den Infobereich statt der Taskleiste minimieren</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="147"/>
+        <source>Show only a tray icon after minimizing the window</source>
+        <translation>Minimiert nur im Infobereich anzeigen.</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="150"/>
+        <source>Map port using &amp;UPnP</source>
+        <translation>Portweiterleitung via UPnP</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="151"/>
+        <source>Automatically open the Bitcoin client port on the router. This only works when your router supports UPnP and it is enabled.</source>
+        <translation>Öffnet den Bitcoin Client-Port automatisch auf dem Router. Dies funktioniert nur, wenn Ihr Router UPnP unterstützt und dies aktiviert ist.</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="154"/>
+        <source>M&amp;inimize on close</source>
+        <translation>Beim Schließen minimieren</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="155"/>
+        <source>Minimize instead of exit the application when the window is closed. When this option is enabled, the application will be closed only after selecting Quit in the menu.</source>
+        <translation>Minimiert die Anwendung, wenn das Fenster geschlossen wird. Wenn dies aktiviert ist, müssen Sie das Programm über &quot;Beenden&quot; im Menü schließen.</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="158"/>
+        <source>&amp;Connect through SOCKS4 proxy:</source>
+        <translation>Über SOCKS4-Proxy verbinden:</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="159"/>
+        <source>Connect to the Bitcon network through a SOCKS4 proxy (e.g. when connecting through Tor)</source>
+        <translation>Über SOCKS4-Proxy zum Bitcoin-Netzwerk verbinden (bspw. für eine Verbindung über Tor)</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="164"/>
+        <source>Proxy &amp;IP: </source>
+        <translation>Proxy-IP:</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="170"/>
+        <source>IP address of the proxy (e.g. 127.0.0.1)</source>
+        <translation>IP-Adresse des Proxys (z.B. 127.0.0.1)</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="173"/>
+        <source>&amp;Port: </source>
+        <translation>Port:</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="179"/>
+        <source>Port of the proxy (e.g. 1234)</source>
+        <translation>Port des Proxy-Servers (z.B. 1234)</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="185"/>
+        <source>Optional transaction fee per KB that helps make sure your transactions are processed quickly.  Most transactions are 1KB.  Fee 0.01 recommended.</source>
+        <translation>Zusätzliche Transaktionsgebühr per KB, welche sicherstellt dass Ihre Transaktionen schnell bearbeitet werden. Die meisten Transaktionen sind 1KB groß. Eine Gebühr von 0.01 wird empfohlen.</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="191"/>
+        <source>Pay transaction &amp;fee</source>
+        <translation>Transaktionsgebühr bezahlen</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="194"/>
+        <source>Optional transaction fee per KB that helps make sure your transactions are processed quickly. Most transactions are 1KB. Fee 0.01 recommended.</source>
+        <translation>Zusätzliche Transaktionsgebühr per KB, welche sicherstellt dass Ihre Transaktionen schnell bearbeitet werden. Die meisten Transaktionen sind 1KB groß. Eine Gebühr von 0.01 wird empfohlen.</translation>
+    </message>
+</context>
+<context>
+    <name>OptionsDialog</name>
+    <message>
+        <location filename="../optionsdialog.cpp" line="54"/>
+        <source>Main</source>
+        <translation>Haupt</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="74"/>
+        <source>Options</source>
+        <translation>Einstellungen</translation>
+    </message>
+</context>
+<context>
+    <name>OverviewPage</name>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="14"/>
+        <source>Form</source>
+        <translation></translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="38"/>
+        <source>Balance:</source>
+        <translation>Kontostand:</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="45"/>
+        <source>123.456 BTC</source>
+        <translation></translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="52"/>
+        <source>Number of transactions:</source>
+        <translation>Anzahl der Transaktionen:</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="59"/>
+        <source>0</source>
+        <translation></translation>
+    </message>
+    <message>
+        <location filename="../overviewpage.cpp" line="14"/>
+        <source>Your current balance</source>
+        <translation>Kontostand</translation>
+    </message>
+</context>
+<context>
+    <name>SendCoinsDialog</name>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="14"/>
+        <location filename="../sendcoinsdialog.cpp" line="56"/>
+        <location filename="../sendcoinsdialog.cpp" line="78"/>
+        <location filename="../sendcoinsdialog.cpp" line="84"/>
+        <location filename="../sendcoinsdialog.cpp" line="90"/>
+        <location filename="../sendcoinsdialog.cpp" line="96"/>
+        <source>Send Coins</source>
+        <translation>Bitcoins überweisen</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="27"/>
+        <source>The address to send the payment to  (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source>
+        <translation>Empfangsadresse für die Überweisung (z.B. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="37"/>
+        <source>Look up adress in address book</source>
+        <translation>Adressbuch</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="47"/>
+        <source>Alt+A</source>
+        <translation>Alt+A</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="60"/>
+        <source>Paste address from system clipboard</source>
+        <translation>Adresse aus der Zwischenanlage einfügen</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="70"/>
+        <source>Alt+P</source>
+        <translation>Alt+P</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="82"/>
+        <source>A&amp;mount:</source>
+        <translation>Betrag:</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="95"/>
+        <source>Pay &amp;To:</source>
+        <translation>Empfänger:</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="113"/>
+        <source>Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source>
+        <translation>Bitcoin-Adresse eingeben (z.B. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="131"/>
+        <location filename="../sendcoinsdialog.cpp" line="23"/>
+        <source>Enter a label for this address to add it to your address book</source>
+        <translation>Beschreibung der Adresse im Adressbuch</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="140"/>
+        <source>&amp;Label:</source>
+        <translation>Beschreibung:</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="183"/>
+        <source>Confirm the send action</source>
+        <translation>Überweisung bestätigen</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="186"/>
+        <source>&amp;Send</source>
+        <translation>Überweisen</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="206"/>
+        <source>Abort the send action</source>
+        <translation>Überweisung abbrechen</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="57"/>
+        <source>Must fill in an amount to pay.</source>
+        <translation>Bitte geben Sie einen Betrag ein.</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="65"/>
+        <source>Confirm send coins</source>
+        <translation>Überweisung bestätigen</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="66"/>
+        <source>Are you sure you want to send %1 BTC to %2 (%3)?</source>
+        <translation>Möchten Sie %1 BTC an %2 (%3) überweisen?</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="79"/>
+        <source>The recepient address is not valid, please recheck.</source>
+        <translation>Die Empfangsadresse ist ungültig.</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="85"/>
+        <source>The amount to pay must be larger than 0.</source>
+        <translation>Der Betrag muss mehr als 0 betragen.</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="91"/>
+        <source>Amount exceeds your balance</source>
+        <translation>Der Betrag übersteigt ihren Kontostand</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="97"/>
+        <source>Total exceeds your balance when the %1 transaction fee is included</source>
+        <translation>Betrag übersteigt ihren Kontostand aufgrund der Transaktionsgebühren in Höhe von %1</translation>
+    </message>
+</context>
+<context>
+    <name>TransactionDescDialog</name>
+    <message>
+        <location filename="../forms/transactiondescdialog.ui" line="14"/>
+        <source>Transaction details</source>
+        <translation>Transaktionsübersicht</translation>
+    </message>
+    <message>
+        <location filename="../forms/transactiondescdialog.ui" line="20"/>
+        <source>This pane shows a detailed description of the transaction</source>
+        <translation>Dieses Fenster zeigt ihnen eine detaillierte Übersicht der Transaktion an</translation>
+    </message>
+</context>
+<context>
+    <name>TransactionTableModel</name>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="211"/>
+        <source>Status</source>
+        <translation>Status</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="211"/>
+        <source>Date</source>
+        <translation>Datum</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="211"/>
+        <source>Type</source>
+        <translation>Beschreibung</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="211"/>
+        <source>Address</source>
+        <translation>Adresse</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="211"/>
+        <source>Amount</source>
+        <translation>Betrag</translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../transactiontablemodel.cpp" line="272"/>
+        <source>Open for %n block(s)</source>
+        <translation>
+            <numerusform>Offen für %n Blöcke</numerusform>
+            <numerusform></numerusform>
+        </translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="275"/>
+        <source>Open until %1</source>
+        <translation>Offen bis %1</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="278"/>
+        <source>Offline (%1 confirmations)</source>
+        <translation>Nicht verbunden (%1 Bestätigungen)</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="281"/>
+        <source>Unconfirmed (%1/%2 confirmations)</source>
+        <translation>Unbestätigt (%1/%2 Bestätigungen)</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="284"/>
+        <source>Confirmed (%1 confirmations)</source>
+        <translation>Bestätigt (%1 Bestätigungen)</translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../transactiontablemodel.cpp" line="293"/>
+        <source>Mined balance will be available in %n more blocks</source>
+        <translation>
+            <numerusform>Der Betrag wird in %n Blöcken verfügbar sein</numerusform>
+            <numerusform></numerusform>
+        </translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="299"/>
+        <source>This block was not received by any other nodes and will probably not be accepted!</source>
+        <translation>Dieser Block wurde vom Netzwerk nicht angenommen und wird wahrscheinlich nicht bestätigt werden!</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="302"/>
+        <source>Generated but not accepted</source>
+        <translation>Generiert, jedoch nicht angenommen</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="348"/>
+        <source>Received with</source>
+        <translation>Empfangen durch</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="351"/>
+        <source>Received from IP</source>
+        <translation>Empfangen durch IP</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="354"/>
+        <source>Sent to</source>
+        <translation>An</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="357"/>
+        <source>Sent to IP</source>
+        <translation>An IP</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="360"/>
+        <source>Payment to yourself</source>
+        <translation>Überweisung an Sie selbst</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="363"/>
+        <source>Mined</source>
+        <translation>Erarbeitet</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="578"/>
+        <source>Transaction status. Hover over this field to show number of confirmations.</source>
+        <translation>Transaktionsstatus. Fahren Sie mit der Maus über dieses Feld um die Anzahl der Bestätigungen zu sehen.</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="580"/>
+        <source>Date and time that the transaction was received.</source>
+        <translation>Datum und Uhrzeit als die Transaktion empfangen wurde.</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="582"/>
+        <source>Type of transaction.</source>
+        <translation>Art der Transaktion.</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="584"/>
+        <source>Destination address of transaction.</source>
+        <translation>Empfangsadresse der Transaktion</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="586"/>
+        <source>Amount removed from or added to balance.</source>
+        <translation>Betrag vom Kontostand entfernt oder hinzugefügt.</translation>
+    </message>
+</context>
+<context>
+    <name>TransactionView</name>
+    <message>
+        <location filename="../transactionview.cpp" line="39"/>
+        <location filename="../transactionview.cpp" line="52"/>
+        <source>All</source>
+        <translation>Alle</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="40"/>
+        <source>Today</source>
+        <translation>Heute</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="41"/>
+        <source>This week</source>
+        <translation>Diese Woche</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="42"/>
+        <source>This month</source>
+        <translation>Diesen Monat</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="43"/>
+        <source>Last month</source>
+        <translation>Letzten Monat</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="44"/>
+        <source>This year</source>
+        <translation>Dieses Jahr</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="45"/>
+        <source>Range...</source>
+        <translation>Bereich...</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="53"/>
+        <source>Received with</source>
+        <translation>Empfangen durch</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="55"/>
+        <source>Sent to</source>
+        <translation>An</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="57"/>
+        <source>To yourself</source>
+        <translation>Zu Ihnen selbst</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="58"/>
+        <source>Mined</source>
+        <translation>Erarbeitet</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="59"/>
+        <source>Other</source>
+        <translation>Andere</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="208"/>
+        <source>Export Transaction Data</source>
+        <translation>Transaktionen exportieren</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="210"/>
+        <source>Comma separated file (*.csv)</source>
+        <translation></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="230"/>
+        <source>Error exporting</source>
+        <translation>Fehler beim exportieren</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="230"/>
+        <source>Could not write to file %1.</source>
+        <translation>Konnte Datei %1 nicht zum beschreiben öffnen</translation>
+    </message>
+</context>
+<context>
+    <name>WalletModel</name>
+    <message>
+        <location filename="../walletmodel.cpp" line="95"/>
+        <source>Sending...</source>
+        <translation>Senden...</translation>
+    </message>
+</context>
+<context>
+    <name>bitcoin-core</name>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="3"/>
+        <source>Bitcoin version</source>
+        <translation>Bitcoin Version</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="4"/>
+        <source>Usage:</source>
+        <translation>Verwendung:</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="5"/>
+        <source>Send command to -server or bitcoind
+</source>
+        <translation>RPC-Befehl an bitcoind schicken</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="6"/>
+        <source>List commands
+</source>
+        <translation>RPC-Befehle auflisten</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="7"/>
+        <source>Get help for a command
+</source>
+        <translation>Hilfe</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="8"/>
+        <source>Options:
+</source>
+        <translation>Einstellungen</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="9"/>
+        <source>Specify configuration file (default: bitcoin.conf)
+</source>
+        <translation>Bitte wählen Sie eine Konfigurationsdatei (Standard: bitcoin.conf)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="10"/>
+        <source>Specify pid file (default: bitcoind.pid)
+</source>
+        <translation>Bitte wählen Sie den Namen der PID Datei (Standard bitcoind.pid)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="11"/>
+        <source>Generate coins
+</source>
+        <translation>Erarbeite Bitcoins</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="12"/>
+        <source>Don&apos;t generate coins
+</source>
+        <translation>Keine BitCoins erstellen</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="13"/>
+        <source>Start minimized
+</source>
+        <translation>minimiert starten</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="14"/>
+        <source>Specify data directory
+</source>
+        <translation>Bitte wählen Sie das Datenverzeichnis</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="15"/>
+        <source>Specify connection timeout (in milliseconds)
+</source>
+        <translation>Netzwerkverbindungsabbruch nach (in Millisekunden)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="16"/>
+        <source>Connect through socks4 proxy
+</source>
+        <translation>Durch SOCKS4-Proxy verbinden</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="17"/>
+        <source>Allow DNS lookups for addnode and connect
+</source>
+        <translation>Erlaube DNS Namensauflösung für addnode und connect</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="18"/>
+        <source>Add a node to connect to
+</source>
+        <translation>Bitcoin Server registrieren</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="19"/>
+        <source>Connect only to the specified node
+</source>
+        <translation>Nur zu den angegebenen Servern verbinden</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="20"/>
+        <source>Don&apos;t accept connections from outside
+</source>
+        <translation>Keine externen Transatkionen akzeptieren</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="21"/>
+        <source>Don&apos;t attempt to use UPnP to map the listening port
+</source>
+        <translation>UPnP nicht verwenden</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="22"/>
+        <source>Attempt to use UPnP to map the listening port
+</source>
+        <translation>Versuche eine Verbindung mittels UPnP herzustellen</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="23"/>
+        <source>Fee per KB to add to transactions you send
+</source>
+        <translation>Gebühr pro KB (je von Ihnen verschickte Transatkion)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="24"/>
+        <source>Accept command line and JSON-RPC commands
+</source>
+        <translation>Erlaube Kommandozeilen und RPC Befehle</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="25"/>
+        <source>Run in the background as a daemon and accept commands
+</source>
+        <translation>Als Hintergrunddienst starten</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="26"/>
+        <source>Use the test network
+</source>
+        <translation>Im Testnetz starten</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="27"/>
+        <source>Username for JSON-RPC connections
+</source>
+        <translation>Benutzername für RPC Befehle</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="28"/>
+        <source>Password for JSON-RPC connections
+</source>
+        <translation>Passwort für RPC Befehle</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="29"/>
+        <source>Listen for JSON-RPC connections on &lt;port&gt; (default: 8332)
+</source>
+        <translation>Port für RPC Befehle</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="30"/>
+        <source>Allow JSON-RPC connections from specified IP address
+</source>
+        <translation>RPC Befehle nur von dieser IP-Adresse erlauben</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="31"/>
+        <source>Send commands to node running on &lt;ip&gt; (default: 127.0.0.1)
+</source>
+        <translation>Befehl an einen anderen BitCoin Server senden</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="32"/>
+        <source>Set key pool size to &lt;n&gt; (default: 100)
+</source>
+        <translation>Menge der vorgenerierten Adressen</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="33"/>
+        <source>Rescan the block chain for missing wallet transactions
+</source>
+        <translation>Block-Chain nach verlorenen Transaktionen durchsuchen (rescan)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="34"/>
+        <source>
+SSL options: (see the Bitcoin Wiki for SSL setup instructions)
+</source>
+        <translation>SSL Einstellungen (Bitte sehen Sie für eine detallierte Beschreibung im BitCoin-Wiki nach</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="37"/>
+        <source>Use OpenSSL (https) for JSON-RPC connections
+</source>
+        <translation>RPC Befehle über HTTPS</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="38"/>
+        <source>Server certificate file (default: server.cert)
+</source>
+        <translation>SSL Server Zertifikat</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="39"/>
+        <source>Server private key (default: server.pem)
+</source>
+        <translation>Privater SSL Schlüssel (Standard: server.pem)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="40"/>
+        <source>Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)
+</source>
+        <translation>Erlaubte Kryptographiealgorithmen (Standard: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="43"/>
+        <source>This help message
+</source>
+        <translation>Dieser Hilfetext</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="44"/>
+        <source>Cannot obtain a lock on data directory %s.  Bitcoin is probably already running.</source>
+        <translation>Konnte das Datenverzeichnis %s nicht sperren. Evtl. wurde das Programm mehrfach gestartet.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="47"/>
+        <source>Error loading addr.dat      
+</source>
+        <translation>Fehler beim laden der addr.dat</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="48"/>
+        <source>Error loading blkindex.dat      
+</source>
+        <translation>Fehler beim laden der blkindex.dat</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="49"/>
+        <source>Error loading wallet.dat      
+</source>
+        <translation>Fehler beim laden von wallet.dat</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="50"/>
+        <source>Invalid -proxy address</source>
+        <translation>Fehlerhafte Proxy Adresse</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="51"/>
+        <source>Invalid amount for -paytxfee=&lt;amount&gt;</source>
+        <translation>Ungültige Angabe für -paytxfee=&lt;Betrag&gt;</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="52"/>
+        <source>Warning: -paytxfee is set very high.  This is the transaction fee you will pay if you send a transaction.</source>
+        <translation>Warnung: -paytxfee ist auf einen sehr hohen Wert gesetzt. Dies ist die Gebühr die beim senden einer Transaktion fällig wird.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="55"/>
+        <source>Warning: Disk space is low  </source>
+        <translation>Warnung: Festplattenplatz wird knapp.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="56"/>
+        <source>Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds  </source>
+        <translation>Fehler: Diese Transaktion erfordert eine Gebühr von mindestens %s. Die Gebühr wird fällig aufgrund der Größe, der Komplexität oder der Verwendung erst kürzlich erhaltener BitCoins</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="59"/>
+        <source>Error: Transaction creation failed  </source>
+        <translation>Fehler: Die Transaktion konnte nicht erstellt werden.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="60"/>
+        <source>Sending...</source>
+        <translation>Senden...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="61"/>
+        <source>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.</source>
+        <translation>Fehler: Die Transaktion wurde zurückgewiesen. Dies kann passieren wenn einige Ihrer BitCoins bereits ausgegeben wurde (zB aus einer Sicherungskopie Ihrer wallet.dat)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="65"/>
+        <source>Invalid amount</source>
+        <translation>Fehlerhafter Betrag</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="66"/>
+        <source>Insufficient funds</source>
+        <translation>Unzureichender Kontostand</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="67"/>
+        <source>Invalid bitcoin address</source>
+        <translation>Fehlerhafte Bitcoin Adresse</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="68"/>
+        <source>Unable to bind to port %d on this computer.  Bitcoin is probably already running.</source>
+        <translation>Fehler beim registrieren des Ports %d auf diesem Computer. Evtl. läuft BitCoin bereits</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="71"/>
+        <source>To use the %s option</source>
+        <translation>Um die Option %s zuu verwenden</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="72"/>
+        <source>Warning: %s, you must set rpcpassword=&lt;password&gt;
+in the configuration file: %s
+If the file does not exist, create it with owner-readable-only file permissions.
+</source>
+        <translation>Warnung: Sie müssen rpcpassword=password in der Konfigurationsdatei angeben.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="77"/>
+        <source>You must set rpcpassword=&lt;password&gt; in the configuration file:
+%s
+If the file does not exist, create it with owner-readable-only file permissions.</source>
+        <translation>Sie müssen rpcpassword=password in der Konfigurationsdatei angeben.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="82"/>
+        <source>Warning: Please check that your computer&apos;s date and time are correct.  If your clock is wrong Bitcoin will not work properly.</source>
+        <translation>Bitte prüfen Sie Ihre Datums- und Uhrzeiteinstellungen, ansonsten kann es sein das BitCoin nicht ordnungsgemäss funktioniert.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="85"/>
+        <source>-beta</source>
+        <translation>-beta</translation>
+    </message>
+</context>
+</TS>
diff --git a/src/qt/locale/bitcoin_nl.ts b/src/qt/locale/bitcoin_nl.ts
new file mode 100644 (file)
index 0000000..afe0dc8
--- /dev/null
@@ -0,0 +1,1441 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.0" language="nl_NL">
+<defaultcodec>UTF-8</defaultcodec>
+<context>
+    <name>AboutDialog</name>
+    <message>
+        <location filename="../forms/aboutdialog.ui" line="14"/>
+        <source>About Bitcoin</source>
+        <translation>Over Bitcoin
+</translation>
+    </message>
+    <message>
+        <location filename="../forms/aboutdialog.ui" line="53"/>
+        <source>&lt;b&gt;Bitcoin&lt;/b&gt; version</source>
+        <translation>&lt;b&gt;Bitcoin&lt;/b&gt; versie</translation>
+    </message>
+    <message>
+        <location filename="../forms/aboutdialog.ui" line="85"/>
+        <source>Copyright © 2009-2011 Bitcoin Developers
+
+This is experimental software.
+
+Distributed under the MIT/X11 software license, see the accompanying file license.txt or http://www.opensource.org/licenses/mit-license.php.
+
+This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit (http://www.openssl.org/) and cryptographic software written by Eric Young (eay@cryptsoft.com) and UPnP software written by Thomas Bernard.</source>
+        <translation>Copyright © 2009-2011 Bitcoin-ontwikkelaars
+
+Dit is experimentele software.
+
+Gedistributeerd onder de MIT/X11 software licentie, zie het bijgevoegde bestand 
+license.txt of kijk op http://www.opensource.org/licenses/mit-license.php.
+
+Dit product bevat software ontwikkeld door het OpenSSL project for gebruik 
+in de OpenSSL Toolkit (http://www.openssl.org/), en cryptografische 
+software geschreven door Eric Young (eay@cryptsoft.com)) en UPnP software geschreven
+door Thomas Bernard.
+</translation>
+    </message>
+</context>
+<context>
+    <name>AddressBookDialog</name>
+    <message>
+        <source>Address Book</source>
+        <translation type="obsolete">Adresboek</translation>
+    </message>
+    <message>
+        <source>Sending</source>
+        <translation type="obsolete">Versturen</translation>
+    </message>
+    <message>
+        <source>Receiving</source>
+        <translation type="obsolete">Ontvangen</translation>
+    </message>
+    <message>
+        <source>These are your Bitcoin addresses for receiving payments.  You may want to give a different one to each sender so you can keep track of who is paying you.  The highlighted address is displayed in the main window.</source>
+        <translation type="obsolete">Dit zijn je bitcoin-adressen voor het ontvangen van betalingen.  Het is een goed idee iedere afzender een ander adres te geven zodat je bij kunt houden wie je een betaling stuurt. Het geselecteerde adres is zichtbaar in het hoofdscherm.</translation>
+    </message>
+    <message>
+        <source>Create a new address</source>
+        <translation type="obsolete">Voeg een nieuw adres toe</translation>
+    </message>
+    <message>
+        <source>&amp;New Address...</source>
+        <translation type="obsolete">&amp;Nieuw adres...</translation>
+    </message>
+    <message>
+        <source>Copy the currently selected address to the system clipboard</source>
+        <translation type="obsolete">Kopieer het geselecteerde adres naar het plakbord</translation>
+    </message>
+    <message>
+        <source>&amp;Copy to Clipboard</source>
+        <translation type="obsolete">&amp;Kopieer naar plakbord</translation>
+    </message>
+    <message>
+        <source>Edit the currently selected address</source>
+        <translation type="obsolete">Bewerk het geselecteerde adres</translation>
+    </message>
+    <message>
+        <source>&amp;Edit...</source>
+        <translation type="obsolete">&amp;Bewerken...</translation>
+    </message>
+    <message>
+        <source>Delete the currently selected address from the list. Only sending addresses can be deleted.</source>
+        <translation type="obsolete">Verwijder het geselecteerde adres. Alleen verstuur-adressen kunnen worden verwijderd.</translation>
+    </message>
+    <message>
+        <source>&amp;Delete</source>
+        <translation type="obsolete">&amp;Verwijderen</translation>
+    </message>
+</context>
+<context>
+    <name>AddressBookPage</name>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="14"/>
+        <source>Address Book</source>
+        <translation type="unfinished">Adresboek</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="20"/>
+        <source>These are your Bitcoin addresses for receiving payments.  You may want to give a different one to each sender so you can keep track of who is paying you.</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="33"/>
+        <source>Double-click to edit address or label</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="57"/>
+        <source>Create a new address</source>
+        <translation type="unfinished">Voeg een nieuw adres toe</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="60"/>
+        <source>&amp;New Address...</source>
+        <translation type="unfinished">&amp;Nieuw adres...</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="71"/>
+        <source>Copy the currently selected address to the system clipboard</source>
+        <translation type="unfinished">Kopieer het geselecteerde adres naar het plakbord</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="74"/>
+        <source>&amp;Copy to Clipboard</source>
+        <translation type="unfinished">&amp;Kopieer naar plakbord</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="85"/>
+        <source>Delete the currently selected address from the list. Only sending addresses can be deleted.</source>
+        <translation type="unfinished">Verwijder het geselecteerde adres. Alleen verstuur-adressen kunnen worden verwijderd.</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="88"/>
+        <source>&amp;Delete</source>
+        <translation type="unfinished">&amp;Verwijderen</translation>
+    </message>
+</context>
+<context>
+    <name>AddressTableModel</name>
+    <message>
+        <location filename="../addresstablemodel.cpp" line="78"/>
+        <source>Label</source>
+        <translation>Label</translation>
+    </message>
+    <message>
+        <location filename="../addresstablemodel.cpp" line="78"/>
+        <source>Address</source>
+        <translation>Adres</translation>
+    </message>
+    <message>
+        <location filename="../addresstablemodel.cpp" line="114"/>
+        <source>(no label)</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Default receiving address</source>
+        <translation type="obsolete">Standaard ontvangst-adres</translation>
+    </message>
+</context>
+<context>
+    <name>BitcoinGUI</name>
+    <message>
+        <source>Bitcoin</source>
+        <translation type="obsolete">Bitcoin</translation>
+    </message>
+    <message>
+        <source>Your Bitcoin address:</source>
+        <translation type="obsolete">Uw bitcoin-adres:</translation>
+    </message>
+    <message>
+        <source>Your current default receiving address</source>
+        <translation type="obsolete">Uw huidig standaard ontvangst-adres</translation>
+    </message>
+    <message>
+        <source>&amp;New...</source>
+        <translation type="obsolete">&amp;Nieuw...</translation>
+    </message>
+    <message>
+        <source>Create new receiving address</source>
+        <translation type="obsolete">Maak nieuw ontvangst-adres</translation>
+    </message>
+    <message>
+        <source>&amp;Copy to clipboard</source>
+        <translation type="obsolete">&amp;Kopieer naar plakbord</translation>
+    </message>
+    <message>
+        <source>Copy current receiving address to the system clipboard</source>
+        <translation type="obsolete">Kopieer huidig ontvangst-adres naar plakbord</translation>
+    </message>
+    <message>
+        <source>Balance:</source>
+        <translation type="obsolete">Saldo:</translation>
+    </message>
+    <message>
+        <source>Your current balance</source>
+        <translation type="obsolete">Uw huidige saldo</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="112"/>
+        <source>Number of connections to other clients</source>
+        <translation>Aantal verbindingen met andere clients</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="117"/>
+        <source>Number of blocks in the block chain</source>
+        <translation>Aantal blokken in de block-chain</translation>
+    </message>
+    <message>
+        <source>Number of transactions in your wallet</source>
+        <translation type="obsolete">Aantal transacties in je portefeuille</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="120"/>
+        <source>Synchronizing with network...</source>
+        <translation>Synchroniseren met netwerk...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="123"/>
+        <source>Block chain synchronization in progress</source>
+        <translation>Bezig met blokken-database-synchronisatie</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="169"/>
+        <source>&amp;Exit</source>
+        <translation>A&amp;fsluiten</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="170"/>
+        <source>Quit application</source>
+        <translation>De applicatie afsluiten</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="158"/>
+        <source>&amp;Send coins</source>
+        <translation>&amp;Verstuur coins</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="159"/>
+        <source>Send coins to a bitcoin address</source>
+        <translation>Coins versturen naar een bitcoin-adres</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="148"/>
+        <source>&amp;Address Book</source>
+        <translation>&amp;Adresboek</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="50"/>
+        <source>Bitcoin Wallet</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="140"/>
+        <source>&amp;Overview</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="144"/>
+        <source>&amp;Transactions</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="149"/>
+        <source>Edit the list of stored addresses and labels</source>
+        <translation>Bewerk de lijst van adressen en labels</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="153"/>
+        <source>&amp;Receive coins</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="154"/>
+        <source>Show the list of addresses for receiving payments</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="171"/>
+        <source>&amp;About</source>
+        <translation>&amp;Over Bitcoin</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="172"/>
+        <source>Show information about Bitcoin</source>
+        <translation>Laat informatie zien over Bitcoin</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="177"/>
+        <source>&amp;Export...</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="178"/>
+        <source>Export data in current view to a file</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="193"/>
+        <source>[testnet]</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="408"/>
+        <source>Date: </source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="409"/>
+        <source>Amount: </source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="410"/>
+        <source>Type: </source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="411"/>
+        <source>Address: </source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Your &amp;Receiving Addresses...</source>
+        <translation type="obsolete">&amp;Uw ontvangstadressen...</translation>
+    </message>
+    <message>
+        <source>Show the list of receiving addresses and edit their labels</source>
+        <translation type="obsolete">Laat de lijst zien van ontvangst-adressen en bewerk de labels</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="173"/>
+        <source>&amp;Options...</source>
+        <translation>&amp;Opties...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="174"/>
+        <source>Modify configuration options for bitcoin</source>
+        <translation>Verander instellingen van Bitcoin</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="175"/>
+        <source>Open &amp;Bitcoin</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="176"/>
+        <source>Show the Bitcoin window</source>
+        <translation>Laat het Bitcoin-venster zien</translation>
+    </message>
+    <message>
+        <source>All transactions</source>
+        <translation type="obsolete">Alle transacties</translation>
+    </message>
+    <message>
+        <source>Sent/Received</source>
+        <translation type="obsolete">Verzonden/Ontvangen</translation>
+    </message>
+    <message>
+        <source>Sent</source>
+        <translation type="obsolete">Verzonden</translation>
+    </message>
+    <message>
+        <source>Received</source>
+        <translation type="obsolete">Ontvangen</translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../bitcoingui.cpp" line="298"/>
+        <source>%n connection(s)</source>
+        <translation>
+            <numerusform>%n verbinding</numerusform>
+            <numerusform>%n verbindingen</numerusform>
+        </translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../bitcoingui.cpp" line="317"/>
+        <source>%n block(s)</source>
+        <translation>
+            <numerusform>%n blok</numerusform>
+            <numerusform>%n blokken</numerusform>
+        </translation>
+    </message>
+    <message numerus="yes">
+        <source>%n transaction(s)</source>
+        <translation type="obsolete">
+            <numerusform>%n transactie</numerusform>
+            <numerusform>%n transacties</numerusform>
+        </translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="375"/>
+        <source>This transaction is over the size limit.  You can still send it for a fee of %1, which goes to the nodes that process your transaction and helps to support the network.  Do you want to pay the fee?</source>
+        <translation>Deze transactie overschrijdt de limiet.  Om de transactie alsnog te verwerken kun je een fooi betalen van %1. Deze zal betaald worden aan de node die uw transactie verwerkt. Wil je doorgaan en deze fooi betalen?</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="379"/>
+        <source>Sending...</source>
+        <translation>Versturen...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="407"/>
+        <source>Incoming transaction</source>
+        <translation>Binnenkomende transactie</translation>
+    </message>
+</context>
+<context>
+    <name>ClientModel</name>
+    <message>
+        <source>Sending...</source>
+        <translation type="obsolete">Versturen...</translation>
+    </message>
+</context>
+<context>
+    <name>EditAddressDialog</name>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="14"/>
+        <source>Edit Address</source>
+        <translation>Bewerk Adres</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="25"/>
+        <source>&amp;Label</source>
+        <translation>&amp;Label</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="42"/>
+        <source>&amp;Address</source>
+        <translation>&amp;Adres</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="35"/>
+        <source>The label associated with this address book entry</source>
+        <translation>Het label dat is geassocieerd met dit adres</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="52"/>
+        <source>The address associated with this address book entry. This can only be modified for sending addresses.</source>
+        <translation>Het adres dat is geassocieerd met de label. Dit kan alleen worden veranderd voor verzend-adressen.</translation>
+    </message>
+    <message>
+        <source>Set as default receiving address</source>
+        <translation type="obsolete">Stel in as standaard ontvangst-adres</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="20"/>
+        <source>New receiving address</source>
+        <translation>Nieuw ontvangst-adres</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="24"/>
+        <source>New sending address</source>
+        <translation>Nieuw verzend-adres</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="27"/>
+        <source>Edit receiving address</source>
+        <translation>Bewerk ontvangst-adres</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="31"/>
+        <source>Edit sending address</source>
+        <translation>Bewerk ontvangst-adres</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="89"/>
+        <source>The entered address &quot;%1&quot; is not a valid bitcoin address.</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="97"/>
+        <source>The entered address &quot;%1&quot; is already in the address book.</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>The address %1 is already in the address book.</source>
+        <translation type="obsolete">Het adres %1 staat al in het adresboek.</translation>
+    </message>
+</context>
+<context>
+    <name>MainOptionsPage</name>
+    <message>
+        <location filename="../optionsdialog.cpp" line="142"/>
+        <source>&amp;Start Bitcoin on window system startup</source>
+        <translation>&amp;Start Bitcoin wanneer het systeem opstart</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="143"/>
+        <source>Automatically start Bitcoin after the computer is turned on</source>
+        <translation>Start Bitcoin automatisch wanneer het systeem start</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="146"/>
+        <source>&amp;Minimize to the tray instead of the taskbar</source>
+        <translation>&amp;Minimaliseer tot systeemvak in plaats van de taakbalk</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="147"/>
+        <source>Show only a tray icon after minimizing the window</source>
+        <translation>Laat alleen een systeemvak-icoon zien wanneer het venster geminimaliseerd is</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="150"/>
+        <source>Map port using &amp;UPnP</source>
+        <translation>Portmapping via &amp;UPnP</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="151"/>
+        <source>Automatically open the Bitcoin client port on the router. This only works when your router supports UPnP and it is enabled.</source>
+        <translation>Open de Bitcoin-poort automatisch op de router. Dit werkt alleen als de router UPnP ondersteunt.</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="154"/>
+        <source>M&amp;inimize on close</source>
+        <translation>&amp;Minimaliseer bij sluiten van het venster</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="155"/>
+        <source>Minimize instead of exit the application when the window is closed. When this option is enabled, the application will be closed only after selecting Quit in the menu.</source>
+        <translation>Minimiliseer het venster in de plaats van de applicatie af te sluiten als het venster gesloten wordt. Wanneer deze optie aan staan, kan de applicatie alleen worden afgesloten door Afsluiten te kiezen in het menu.</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="158"/>
+        <source>&amp;Connect through SOCKS4 proxy:</source>
+        <translation>&amp;Verbind via socks4 proxy: </translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="159"/>
+        <source>Connect to the Bitcon network through a SOCKS4 proxy (e.g. when connecting through Tor)</source>
+        <translation>Verbind met het Bitcoin-netwerk door een SOCKS4 proxy (bijvoorbeeld Tor)</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="164"/>
+        <source>Proxy &amp;IP: </source>
+        <translation>Proxy &amp;IP:</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="170"/>
+        <source>IP address of the proxy (e.g. 127.0.0.1)</source>
+        <translation>IP adres van de proxy (bijv. 127.0.0.1)</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="173"/>
+        <source>&amp;Port: </source>
+        <translation>&amp;Poort:</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="179"/>
+        <source>Port of the proxy (e.g. 1234)</source>
+        <translation>Poort waarop de proxy luistert (bijv. 1234)</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="185"/>
+        <source>Optional transaction fee per KB that helps make sure your transactions are processed quickly.  Most transactions are 1KB.  Fee 0.01 recommended.</source>
+        <translation>Optionele transactiefooi per KB die helpt ervoor zorgen dat uw transacties snel verwerkt worden. De meeste transacties zijn 1KB. Fooi 0.01 is aangeraden.</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="191"/>
+        <source>Pay transaction &amp;fee</source>
+        <translation>Transactie&amp;fooi</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="194"/>
+        <source>Optional transaction fee per KB that helps make sure your transactions are processed quickly. Most transactions are 1KB. Fee 0.01 recommended.</source>
+        <translation>Optionele transactiefooi per KB die helpt ervoor zorgen dat uw transacties snel verwerkt worden. De meeste transacties zijn 1KB. Fooi 0.01 is aangeraden.</translation>
+    </message>
+</context>
+<context>
+    <name>OptionsDialog</name>
+    <message>
+        <location filename="../optionsdialog.cpp" line="54"/>
+        <source>Main</source>
+        <translation>Algemeen</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="74"/>
+        <source>Options</source>
+        <translation>Opties</translation>
+    </message>
+</context>
+<context>
+    <name>OverviewPage</name>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="14"/>
+        <source>Form</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="38"/>
+        <source>Balance:</source>
+        <translation type="unfinished">Saldo:</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="45"/>
+        <source>123.456 BTC</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="52"/>
+        <source>Number of transactions:</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="59"/>
+        <source>0</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../overviewpage.cpp" line="14"/>
+        <source>Your current balance</source>
+        <translation type="unfinished">Uw huidige saldo</translation>
+    </message>
+</context>
+<context>
+    <name>SendCoinsDialog</name>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="14"/>
+        <location filename="../sendcoinsdialog.cpp" line="56"/>
+        <location filename="../sendcoinsdialog.cpp" line="78"/>
+        <location filename="../sendcoinsdialog.cpp" line="84"/>
+        <location filename="../sendcoinsdialog.cpp" line="90"/>
+        <location filename="../sendcoinsdialog.cpp" line="96"/>
+        <source>Send Coins</source>
+        <translation>Verstuur coins</translation>
+    </message>
+    <message>
+        <source>&amp;Amount:</source>
+        <translation type="obsolete">&amp;Hoeveelheid:</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="95"/>
+        <source>Pay &amp;To:</source>
+        <translation>Betaal &amp;aan:</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="27"/>
+        <source>The address to send the payment to  (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source>
+        <translation>Voer een bitcoin-adres (bijvoorbeeld: 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="47"/>
+        <source>Alt+A</source>
+        <translation>Alt+A</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="60"/>
+        <source>Paste address from system clipboard</source>
+        <translation>Plak adres uit systeemplakbord</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="131"/>
+        <location filename="../sendcoinsdialog.cpp" line="23"/>
+        <source>Enter a label for this address to add it to your address book</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="140"/>
+        <source>&amp;Label:</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>&amp;Paste</source>
+        <translation type="obsolete">&amp;Plakken</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="37"/>
+        <source>Look up adress in address book</source>
+        <translation>Opzoeken in adresboek</translation>
+    </message>
+    <message>
+        <source>Address &amp;Book...</source>
+        <translation type="obsolete">Adres&amp;boek....</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="70"/>
+        <source>Alt+P</source>
+        <translation>Alt+P</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="82"/>
+        <source>A&amp;mount:</source>
+        <translation>&amp;Hoeveelheid:</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="113"/>
+        <source>Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source>
+        <translation>Voer een bitcoin-adres in (bijvoorbeeld: 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation>
+    </message>
+    <message>
+        <source>Add specified destination address to address book</source>
+        <translation type="obsolete">Voeg het ingevoerde doel-adres toe aan het adresboek</translation>
+    </message>
+    <message>
+        <source>A&amp;dd to address book as</source>
+        <translation type="obsolete">&amp;Voeg toe aan adresboek als</translation>
+    </message>
+    <message>
+        <source>Label to add address as</source>
+        <translation type="obsolete">Label om toe te kennen aan adres in adresboek</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="183"/>
+        <source>Confirm the send action</source>
+        <translation>Bevestig de zend-transactie</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="186"/>
+        <source>&amp;Send</source>
+        <translation>&amp;Versturen</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="206"/>
+        <source>Abort the send action</source>
+        <translation>De transactie annuleren</translation>
+    </message>
+    <message>
+        <source>The amount to pay must be a valid number.</source>
+        <translation type="obsolete">Het ingevoerde bedrag is geen geldig getal.</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="57"/>
+        <source>Must fill in an amount to pay.</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="65"/>
+        <source>Confirm send coins</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="66"/>
+        <source>Are you sure you want to send %1 BTC to %2 (%3)?</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="79"/>
+        <source>The recepient address is not valid, please recheck.</source>
+        <translation>Het verzendadres is niet geld.</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="85"/>
+        <source>The amount to pay must be larger than 0.</source>
+        <translation>Het ingevoerde gedrag moet groter zijn dan 0.</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="91"/>
+        <source>Amount exceeds your balance</source>
+        <translation>Hoeveelheid overschrijdt uw huidige balans</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="97"/>
+        <source>Total exceeds your balance when the %1 transaction fee is included</source>
+        <translation>Totaal overschrijdt uw huidige balans wanneer de %1 transactiefooi is meegerekend</translation>
+    </message>
+</context>
+<context>
+    <name>TransactionDescDialog</name>
+    <message>
+        <location filename="../forms/transactiondescdialog.ui" line="14"/>
+        <source>Transaction details</source>
+        <translation>Transactiedetails</translation>
+    </message>
+    <message>
+        <location filename="../forms/transactiondescdialog.ui" line="20"/>
+        <source>This pane shows a detailed description of the transaction</source>
+        <translation>Dit venster laat een uitgebreide beschrijving van de transactie zien</translation>
+    </message>
+</context>
+<context>
+    <name>TransactionTableModel</name>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="211"/>
+        <source>Status</source>
+        <translation>Status</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="211"/>
+        <source>Date</source>
+        <translation>Datum</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="211"/>
+        <source>Type</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="211"/>
+        <source>Address</source>
+        <translation type="unfinished">Adres</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="211"/>
+        <source>Amount</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="278"/>
+        <source>Offline (%1 confirmations)</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="281"/>
+        <source>Unconfirmed (%1/%2 confirmations)</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="284"/>
+        <source>Confirmed (%1 confirmations)</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../transactiontablemodel.cpp" line="293"/>
+        <source>Mined balance will be available in %n more blocks</source>
+        <translation type="unfinished">
+            <numerusform></numerusform>
+            <numerusform></numerusform>
+        </translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="299"/>
+        <source>This block was not received by any other nodes and will probably not be accepted!</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="302"/>
+        <source>Generated but not accepted</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="348"/>
+        <source>Received with</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="351"/>
+        <source>Received from IP</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="354"/>
+        <source>Sent to</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="357"/>
+        <source>Sent to IP</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="363"/>
+        <source>Mined</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="582"/>
+        <source>Type of transaction.</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="584"/>
+        <source>Destination address of transaction.</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="586"/>
+        <source>Amount removed from or added to balance.</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <source>Description</source>
+        <translation type="obsolete">Beschrijving</translation>
+    </message>
+    <message>
+        <source>Debit</source>
+        <translation type="obsolete">Debet</translation>
+    </message>
+    <message>
+        <source>Credit</source>
+        <translation type="obsolete">Credit</translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../transactiontablemodel.cpp" line="272"/>
+        <source>Open for %n block(s)</source>
+        <translation>
+            <numerusform>Open gedurende %n blok</numerusform>
+            <numerusform>Open gedurende %n blokken</numerusform>
+        </translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="275"/>
+        <source>Open until %1</source>
+        <translation>Open tot %1</translation>
+    </message>
+    <message>
+        <source>Offline (%1)</source>
+        <translation type="obsolete">Offline (%1)</translation>
+    </message>
+    <message>
+        <source>Unconfirmed (%1/%2)</source>
+        <translation type="obsolete">Niet bevestigd (%1/%2)</translation>
+    </message>
+    <message>
+        <source>Confirmed (%1)</source>
+        <translation type="obsolete">Bevestigd (%1)</translation>
+    </message>
+    <message>
+        <source>Received with: </source>
+        <translation type="obsolete">Ontvangen met:</translation>
+    </message>
+    <message>
+        <source>Received from IP: </source>
+        <translation type="obsolete">Ontvangen van IP:</translation>
+    </message>
+    <message>
+        <source>Sent to: </source>
+        <translation type="obsolete">Verzonden aan:</translation>
+    </message>
+    <message>
+        <source>Sent to IP: </source>
+        <translation type="obsolete">Verzonden aan IP:</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="360"/>
+        <source>Payment to yourself</source>
+        <translation>Betaling aan uzelf</translation>
+    </message>
+    <message numerus="yes">
+        <source>Generated (matures in %n more blocks)</source>
+        <translation type="obsolete">
+            <numerusform>Gegenereerd (wordt volwassen na %n blok)</numerusform>
+            <numerusform>Gegenereerd (wordt volwassen na %n blokken)</numerusform>
+        </translation>
+    </message>
+    <message>
+        <source>Generated</source>
+        <translation type="obsolete">Gegenereerd</translation>
+    </message>
+    <message>
+        <source>Generated - Warning: This block was not received by any other nodes and will probably not be accepted!</source>
+        <translation type="obsolete">Gegenereerd - Waarschuwing: Dit blok is niet ontvangen door andere nodes en zal waarschijnlijk niet geaccepteerd worden!</translation>
+    </message>
+    <message>
+        <source>Generated (not accepted)</source>
+        <translation type="obsolete">Gegenereerd (niet geaccepteerd)</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="578"/>
+        <source>Transaction status. Hover over this field to show number of confirmations.</source>
+        <translation>Transactiestatus. Hou de muiscursor boven dit veld om het aantal bevestigingen te laten zien.</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="580"/>
+        <source>Date and time that the transaction was received.</source>
+        <translation>Datum en tijd waarop deze transactie is ontvangen.</translation>
+    </message>
+    <message>
+        <source>Short description of the transaction.</source>
+        <translation type="obsolete">Korte beschrijving van de transactie.</translation>
+    </message>
+    <message>
+        <source>Amount removed from balance.</source>
+        <translation type="obsolete">Bedrag afgeschreven van saldo.</translation>
+    </message>
+    <message>
+        <source>Amount added to balance.</source>
+        <translation type="obsolete">Bedrag bijgeschreven bij saldo.</translation>
+    </message>
+</context>
+<context>
+    <name>TransactionView</name>
+    <message>
+        <location filename="../transactionview.cpp" line="39"/>
+        <location filename="../transactionview.cpp" line="52"/>
+        <source>All</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="40"/>
+        <source>Today</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="41"/>
+        <source>This week</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="42"/>
+        <source>This month</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="43"/>
+        <source>Last month</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="44"/>
+        <source>This year</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="45"/>
+        <source>Range...</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="53"/>
+        <source>Received with</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="55"/>
+        <source>Sent to</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="57"/>
+        <source>To yourself</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="58"/>
+        <source>Mined</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="59"/>
+        <source>Other</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="209"/>
+        <source>Export Transaction Data</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="211"/>
+        <source>Comma separated file (*.csv)</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="231"/>
+        <source>Error exporting</source>
+        <translation type="unfinished"></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="231"/>
+        <source>Could not write to file %1.</source>
+        <translation type="unfinished"></translation>
+    </message>
+</context>
+<context>
+    <name>WalletModel</name>
+    <message>
+        <location filename="../walletmodel.cpp" line="95"/>
+        <source>Sending...</source>
+        <translation type="unfinished">Versturen...</translation>
+    </message>
+</context>
+<context>
+    <name>bitcoin-core</name>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="3"/>
+        <source>Bitcoin version</source>
+        <translation>Bitcoin</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="4"/>
+        <source>Usage:</source>
+        <translation>Gebruik:</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="5"/>
+        <source>Send command to -server or bitcoind
+</source>
+        <translation>Zend commando naar -server of bitcoind
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="6"/>
+        <source>List commands
+</source>
+        <translation>List van commando&apos;s
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="7"/>
+        <source>Get help for a command
+</source>
+        <translation>Toon hulp voor een commando
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="8"/>
+        <source>Options:
+</source>
+        <translation>Opties:
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="9"/>
+        <source>Specify configuration file (default: bitcoin.conf)
+</source>
+        <translation>Specifieer configuratiebestand (standaard: bitcoin.conf)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="10"/>
+        <source>Specify pid file (default: bitcoind.pid)
+</source>
+        <translation>Specifieer pid-bestand (standaard: bitcoind.pid)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="11"/>
+        <source>Generate coins
+</source>
+        <translation>Genereer coins
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="12"/>
+        <source>Don&apos;t generate coins
+</source>
+        <translation>Genereer geen coins
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="13"/>
+        <source>Start minimized
+</source>
+        <translation>Geminimaliseerd starten
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="14"/>
+        <source>Specify data directory
+</source>
+        <translation>Stel datamap in
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="15"/>
+        <source>Specify connection timeout (in milliseconds)
+</source>
+        <translation>Gelieve de time-out tijd te specifieren (in milliseconden)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="16"/>
+        <source>Connect through socks4 proxy
+</source>
+        <translation>Verbind via socks4 proxy
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="17"/>
+        <source>Allow DNS lookups for addnode and connect
+</source>
+        <translation>Sta DNS-opzoeking toe voor addnode en connect
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="18"/>
+        <source>Add a node to connect to
+</source>
+        <translation>Voeg een node toe om mee te verbinden
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="19"/>
+        <source>Connect only to the specified node
+</source>
+        <translation>Verbind alleen met deze node
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="20"/>
+        <source>Don&apos;t accept connections from outside
+</source>
+        <translation>Sta geen verbindingen van buitenaf toe
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="21"/>
+        <source>Don&apos;t attempt to use UPnP to map the listening port
+</source>
+        <translation>Probeer geen UPnP te gebruiken om de poort waarop geluisterd wordt te mappen
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="22"/>
+        <source>Attempt to use UPnP to map the listening port
+</source>
+        <translation>Probeer UPnP te gebruiken om de poort waarop geluisterd wordt te mappen
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="23"/>
+        <source>Fee per KB to add to transactions you send
+</source>
+        <translation>Fooi per KB om aan transacties die gezonden worden toe te voegen
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="24"/>
+        <source>Accept command line and JSON-RPC commands
+</source>
+        <translation>Aanvaard commandolijn en JSON-RPC commando&apos;s
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="25"/>
+        <source>Run in the background as a daemon and accept commands
+</source>
+        <translation>Draai in de achtergrond als daemon en aanvaard commando&apos;s
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="26"/>
+        <source>Use the test network
+</source>
+        <translation>Gebruik het test-netwerk
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="27"/>
+        <source>Username for JSON-RPC connections
+</source>
+        <translation>Gebruikersnaam voor JSON-RPC verbindingen
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="28"/>
+        <source>Password for JSON-RPC connections
+</source>
+        <translation>Wachtwoord voor JSON-RPC verbindingen
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="29"/>
+        <source>Listen for JSON-RPC connections on &lt;port&gt; (default: 8332)
+</source>
+        <translation>Luister voor JSON-RPC verbindingen op &lt;poort&gt; (standaard: 8332)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="30"/>
+        <source>Allow JSON-RPC connections from specified IP address
+</source>
+        <translation>Enkel JSON-RPC verbindingen van opgegeven IP adres toestaan
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="31"/>
+        <source>Send commands to node running on &lt;ip&gt; (default: 127.0.0.1)
+</source>
+        <translation>Zend commando&apos;s naar proces dat op &lt;ip&gt; draait (standaard: 127.0.0.1)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="32"/>
+        <source>Set key pool size to &lt;n&gt; (default: 100)
+</source>
+        <translation>Stel sleutelpoelgrootte in op &lt;n&gt; (standaard: 100)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="33"/>
+        <source>Rescan the block chain for missing wallet transactions
+</source>
+        <translation>Doorzoek de blokken database op ontbrekende portefeuille-transacties
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="34"/>
+        <source>
+SSL options: (see the Bitcoin Wiki for SSL setup instructions)
+</source>
+        <translation>
+SSL opties: (zie de Bitcoin wiki voor SSL instructies)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="37"/>
+        <source>Use OpenSSL (https) for JSON-RPC connections
+</source>
+        <translation>Gebruik OpenSSL (https) voor JSON-RPC verbindingen
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="38"/>
+        <source>Server certificate file (default: server.cert)
+</source>
+        <translation>Certificaat-bestand voor server (standaard: server.cert)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="39"/>
+        <source>Server private key (default: server.pem)
+</source>
+        <translation>Geheime sleutel voor server (standaard: server.pem)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="40"/>
+        <source>Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)
+</source>
+        <translation>Aanvaardbare ciphers (standaard: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="43"/>
+        <source>This help message
+</source>
+        <translation>Dit helpbericht
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="44"/>
+        <source>Cannot obtain a lock on data directory %s.  Bitcoin is probably already running.</source>
+        <translation>Kan geen lock op de gegevensdirectory %s verkrijgen. Bitcoin draait vermoedelijk reeds.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="47"/>
+        <source>Error loading addr.dat      
+</source>
+        <translation>Fout bij laden van bestand addr.dat      
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="48"/>
+        <source>Error loading blkindex.dat      
+</source>
+        <translation>Fout bij laden van bestand addr.dat      
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="49"/>
+        <source>Error loading wallet.dat      
+</source>
+        <translation>Fout bij laden van bestand wallet.dat      
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="50"/>
+        <source>Invalid -proxy address</source>
+        <translation>Foutief -proxy adres</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="51"/>
+        <source>Invalid amount for -paytxfee=&lt;amount&gt;</source>
+        <translation>Ongeldig bedrag voor -paytxfee=&lt;bedrag&gt;</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="52"/>
+        <source>Warning: -paytxfee is set very high.  This is the transaction fee you will pay if you send a transaction.</source>
+        <translation>Waarschuwing: -paytxfee is zeer hoog ingesteld.  Dit is de fooi die betaald wordt bij het zenden van een transactie.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="55"/>
+        <source>Warning: Disk space is low  </source>
+        <translation>Waarschuwing: Weinig schijfruimte over  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="56"/>
+        <source>Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds  </source>
+        <translation>Fout: Deze transactie vergt een fooi van ten minste %s omwille van zijn bedrag, complexiteit, of gebruik van recent ontvangen coins  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="59"/>
+        <source>Error: Transaction creation failed  </source>
+        <translation>Fout: Aanmaken van transactie mislukt  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="60"/>
+        <source>Sending...</source>
+        <translation>Versturen...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="61"/>
+        <source>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.</source>
+        <translation>Fout: De transactie is afgekeurd.  Dit kan gebeuren als bepaalde coins in je Portefeuille al zijn uitgegeven. Dit kan veroorzaakt worden doordat je een kopie van wallet.dat gebruikt hebt en enkel daar je uitgave geregistreerd is.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="65"/>
+        <source>Invalid amount</source>
+        <translation>Foutieve hoeveelheid</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="66"/>
+        <source>Insufficient funds</source>
+        <translation>Onvoldoende saldo</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="67"/>
+        <source>Invalid bitcoin address</source>
+        <translation>Foutief bitcoin-adres</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="68"/>
+        <source>Unable to bind to port %d on this computer.  Bitcoin is probably already running.</source>
+        <translation>Kan niet binden met poort %d op deze computer. Bitcoin draait vermoedelijk reeds.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="71"/>
+        <source>To use the %s option</source>
+        <translation>Om de %s optie te gebruiken</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="72"/>
+        <source>Warning: %s, you must set rpcpassword=&lt;password&gt;
+in the configuration file: %s
+If the file does not exist, create it with owner-readable-only file permissions.
+</source>
+        <translation>Waarschuwing: %s, rpcpassword=&lt;password&gt; moet ingesteld zijn
+in het configuratie bestand: %s
+Als het bestand nog niet bestaat, maak het dan aan met enkel-leesbaar-door-eigenaar rechten.
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="77"/>
+        <source>You must set rpcpassword=&lt;password&gt; in the configuration file:
+%s
+If the file does not exist, create it with owner-readable-only file permissions.</source>
+        <translation>rpcpassword=&lt;password&gt; moet ingesteld in het configuratie bestand:
+%s
+Als het bestand nog niet bestaat, maak het dan aan met enkel-leesbaar-door-eigenaar rechten.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="82"/>
+        <source>Warning: Please check that your computer&apos;s date and time are correct.  If your clock is wrong Bitcoin will not work properly.</source>
+        <translation>Waarschuwing: Controleer of uw computers datum en tijd correct ingesteld zijn. Als uw klok fout staat zal Bitcoin niet correct werken.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="85"/>
+        <source>-beta</source>
+        <translation>-beta</translation>
+    </message>
+</context>
+</TS>
diff --git a/src/qt/locale/bitcoin_ru.ts b/src/qt/locale/bitcoin_ru.ts
new file mode 100644 (file)
index 0000000..6085602
--- /dev/null
@@ -0,0 +1,2173 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE TS>
+<TS version="2.0" language="ru_RU">
+<context>
+    <name>AboutDialog</name>
+    <message>
+        <location filename="../forms/aboutdialog.ui" line="14"/>
+        <source>About Bitcoin</source>
+        <translation>О Bitcoin&apos;е</translation>
+    </message>
+    <message>
+        <location filename="../forms/aboutdialog.ui" line="53"/>
+        <source>&lt;b&gt;Bitcoin&lt;/b&gt; version</source>
+        <translation>Версия Bitcoin&apos;а</translation>
+    </message>
+    <message utf8="true">
+        <location filename="../forms/aboutdialog.ui" line="85"/>
+        <source>Copyright © 2009-2011 Bitcoin Developers
+
+This is experimental software.
+
+Distributed under the MIT/X11 software license, see the accompanying file license.txt or http://www.opensource.org/licenses/mit-license.php.
+
+This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit (http://www.openssl.org/) and cryptographic software written by Eric Young (eay@cryptsoft.com) and UPnP software written by Thomas Bernard.</source>
+        <translation>Copyright © 2009-2011 Разработчики сети Bitcoin
+
+ВНИМАНИЕ: этот софт является экспериментальным!
+
+Распространяется под лицензией MIT/X11, за дополнительной информацией обращайтесь к прилагающемуся файлу license.txt или документу по данной ссылке: http://www.opensource.org/licenses/mit-license.php.
+
+Данный продукт включает в себя разработки проекта OpenSSL (http://www.openssl.org/), криптографические функции и алгоритмы, написанные Эриком Янгом (eay@cryptsoft.com) и функции для работы с UPnP за авторством Томаса Бернарда.</translation>
+    </message>
+</context>
+<context>
+    <name>AddressBookPage</name>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="14"/>
+        <source>Address Book</source>
+        <translation>Адресная книга</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="20"/>
+        <source>These are your Bitcoin addresses for receiving payments.  You may want to give a different one to each sender so you can keep track of who is paying you.</source>
+        <translation>Здесь перечислены Ваши адреса для получения платежей.  Вы можете использовать их для того, чтобы давать разным людям разные адреса и таким образом иметь возможность отслеживать кто и сколько Вам платил, а так же поддерживать бо́льшую анонимность..</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="33"/>
+        <source>Double-click to edit address or label</source>
+        <translation>Для того, чтобы изменить адрес или метку давжды кликните по изменяемому объекту</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="57"/>
+        <source>Create a new address</source>
+        <translation>Создать новый адрес</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="60"/>
+        <source>&amp;New Address...</source>
+        <translation>&amp;Создать адрес...</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="71"/>
+        <source>Copy the currently selected address to the system clipboard</source>
+        <translation>Копировать текущий выделенный адрес в буфер обмена</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="74"/>
+        <source>&amp;Copy to Clipboard</source>
+        <translation>&amp;Kопировать</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="85"/>
+        <source>Delete the currently selected address from the list. Only sending addresses can be deleted.</source>
+        <translation>Удалить выделенный адрес из списка (могут быть удалены только записи из адресной книги).</translation>
+    </message>
+    <message>
+        <location filename="../forms/addressbookpage.ui" line="88"/>
+        <source>&amp;Delete</source>
+        <translation>&amp;Удалить</translation>
+    </message>
+    <message>
+        <location filename="../addressbookpage.cpp" line="197"/>
+        <source>Export Address Book Data</source>
+        <translation>Экспортировать адресную книгу</translation>
+    </message>
+    <message>
+        <location filename="../addressbookpage.cpp" line="199"/>
+        <source>Comma separated file (*.csv)</source>
+        <translation>Текст, разделённый запятыми (*.csv)</translation>
+    </message>
+    <message>
+        <location filename="../addressbookpage.cpp" line="212"/>
+        <source>Error exporting</source>
+        <translation>Ошибка экспорта</translation>
+    </message>
+    <message>
+        <location filename="../addressbookpage.cpp" line="212"/>
+        <source>Could not write to file %1.</source>
+        <translation>Невозможно записать в файл %1.</translation>
+    </message>
+</context>
+<context>
+    <name>AddressTableModel</name>
+    <message>
+        <location filename="../addresstablemodel.cpp" line="78"/>
+        <source>Label</source>
+        <translation>Метка</translation>
+    </message>
+    <message>
+        <location filename="../addresstablemodel.cpp" line="78"/>
+        <source>Address</source>
+        <translation>Адрес</translation>
+    </message>
+    <message>
+        <location filename="../addresstablemodel.cpp" line="114"/>
+        <source>(no label)</source>
+        <translation>[нет метки]</translation>
+    </message>
+</context>
+<context>
+    <name>BitcoinGUI</name>
+    <message>
+        <location filename="../bitcoingui.cpp" line="53"/>
+        <source>Bitcoin Wallet</source>
+        <translation>Bitcoin-бумажник</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="61"/>
+        <source>&amp;File</source>
+        <translation>&amp;Файл</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="67"/>
+        <source>&amp;Settings</source>
+        <translation>&amp;Настройки</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="70"/>
+        <source>&amp;Help</source>
+        <translation>&amp;Помощь</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="74"/>
+        <source>Tabs toolbar</source>
+        <translation>Панель вкладок</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="82"/>
+        <source>Actions toolbar</source>
+        <translation>Панель действий</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="130"/>
+        <source>Synchronizing with network...</source>
+        <translation>Синхронизация с сетью...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="133"/>
+        <source>Block chain synchronization in progress</source>
+        <translation>Идёт синхронизация цепочки блоков</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="157"/>
+        <source>&amp;Overview</source>
+        <translation>О&amp;бзор</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="158"/>
+        <source>Show general overview of wallet</source>
+        <translation>Показать общий обзор действий с бумажником</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="162"/>
+        <source>&amp;Transactions</source>
+        <translation>&amp;Транзакции</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="163"/>
+        <source>Browse transaction history</source>
+        <translation>Показать историю транзакций</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="167"/>
+        <source>&amp;Address Book</source>
+        <translation>&amp;Адресная книга</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="168"/>
+        <source>Edit the list of stored addresses and labels</source>
+        <translation>Изменить список сохранённых адресов и меток к ним</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="172"/>
+        <source>&amp;Receive coins</source>
+        <translation>&amp;Получение</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="173"/>
+        <source>Show the list of addresses for receiving payments</source>
+        <translation>Показать список адресов для получения платежей</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="177"/>
+        <source>&amp;Send coins</source>
+        <translation>Отп&amp;равка</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="178"/>
+        <source>Send coins to a bitcoin address</source>
+        <translation>Отправить монеты на указанный адрес</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="188"/>
+        <source>&amp;Exit</source>
+        <translation>Вы&amp;ход</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="189"/>
+        <source>Quit application</source>
+        <translation>Закрыть приложение</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="190"/>
+        <source>&amp;About</source>
+        <translation>&amp;Информация</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="191"/>
+        <source>Show information about Bitcoin</source>
+        <translation>Показать информацию о Bitcoin&apos;е</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="192"/>
+        <source>&amp;Options...</source>
+        <translation>Оп&amp;ции...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="193"/>
+        <source>Modify configuration options for bitcoin</source>
+        <translation>Изменить настройки</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="194"/>
+        <source>Open &amp;Bitcoin</source>
+        <translation>&amp;Показать бумажник</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="195"/>
+        <source>Show the Bitcoin window</source>
+        <translation>Показать окно бумажника</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="196"/>
+        <source>&amp;Export...</source>
+        <translation>&amp;Экспорт...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="197"/>
+        <source>Export the current view to a file</source>
+        <translation>Экспортировать в файл</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="211"/>
+        <source>[testnet]</source>
+        <translation>[тестовая сеть]</translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../bitcoingui.cpp" line="304"/>
+        <source>%n active connection(s) to Bitcoin network</source>
+        <translation>
+            <numerusform>%n активное соединение с сетью</numerusform>
+            <numerusform>%n активных соединений с сетью</numerusform>
+            <numerusform>%n активных соединений с сетью</numerusform>
+        </translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="318"/>
+        <source>Downloaded %1 of %2 blocks of transaction history.</source>
+        <translation>Загружено %1 из %2 блоков истории транзакций.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="324"/>
+        <source>Downloaded %1 blocks of transaction history.</source>
+        <translation>Загружено %1 блоков истории транзакций.</translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../bitcoingui.cpp" line="335"/>
+        <source>%n second(s) ago</source>
+        <translation>
+            <numerusform>%n секунду назад</numerusform>
+            <numerusform>%n секунды назад</numerusform>
+            <numerusform>%n секунд назад</numerusform>
+        </translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../bitcoingui.cpp" line="339"/>
+        <source>%n minute(s) ago</source>
+        <translation>
+            <numerusform>%n минуту назад</numerusform>
+            <numerusform>%n минуты назад</numerusform>
+            <numerusform>%n минут назад</numerusform>
+        </translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../bitcoingui.cpp" line="343"/>
+        <source>%n hour(s) ago</source>
+        <translation>
+            <numerusform>%n час назад</numerusform>
+            <numerusform>%n часа назад</numerusform>
+            <numerusform>%n часов назад</numerusform>
+        </translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../bitcoingui.cpp" line="347"/>
+        <source>%n day(s) ago</source>
+        <translation>
+            <numerusform>%n день назад</numerusform>
+            <numerusform>%n дня назад</numerusform>
+            <numerusform>%n дней назад</numerusform>
+        </translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="353"/>
+        <source>Up to date</source>
+        <translation>Синхронизированно</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="358"/>
+        <source>Catching up...</source>
+        <translation>Синхронизируется...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="364"/>
+        <source>Last received block was generated %1.</source>
+        <translation>Последний полученный блок был сгенерирован %1.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="421"/>
+        <source>This transaction is over the size limit.  You can still send it for a fee of %1, which goes to the nodes that process your transaction and helps to support the network.  Do you want to pay the fee?</source>
+        <translation>Данная транзакция превышает предельно допустимый размер.  Но Вы можете всё равно совершить ей, добавив комиссию в %1, которая отправится тем узлам, которые обработают Вашу транзакцию и поможет поддержать сеть.  Вы хотите добавить комиссию?</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="426"/>
+        <source>Sending...</source>
+        <translation>Отправка...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="449"/>
+        <source>Sent transaction</source>
+        <translation>Исходящая транзакция</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="450"/>
+        <source>Incoming transaction</source>
+        <translation>Входящая транзакция</translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="451"/>
+        <source>Date: </source>
+        <translation>Дата: </translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="452"/>
+        <source>Amount: </source>
+        <translation>Количество: </translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="453"/>
+        <source>Type: </source>
+        <translation>Тип: </translation>
+    </message>
+    <message>
+        <location filename="../bitcoingui.cpp" line="454"/>
+        <source>Address: </source>
+        <translation>Адрес: </translation>
+    </message>
+</context>
+<context>
+    <name>DisplayOptionsPage</name>
+    <message>
+        <location filename="../optionsdialog.cpp" line="254"/>
+        <source>&amp;Unit to show amounts in: </source>
+        <translation>&amp;Измерять монеты в: </translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="258"/>
+        <source>Choose the default subdivision unit to show in the interface, and when sending coins</source>
+        <translation>Единица измерения количества монет при отображении и при отправке</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="265"/>
+        <source>Display addresses in transaction list</source>
+        <translation>Показывать адреса в списке транзакций</translation>
+    </message>
+</context>
+<context>
+    <name>EditAddressDialog</name>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="14"/>
+        <source>Edit Address</source>
+        <translation>Изменить адрес</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="25"/>
+        <source>&amp;Label</source>
+        <translation>&amp;Метка</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="35"/>
+        <source>The label associated with this address book entry</source>
+        <translation>Метка, связанная с данной записью</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="42"/>
+        <source>&amp;Address</source>
+        <translation>&amp;Адрес</translation>
+    </message>
+    <message>
+        <location filename="../forms/editaddressdialog.ui" line="52"/>
+        <source>The address associated with this address book entry. This can only be modified for sending addresses.</source>
+        <translation>Адрес, связанный с данной записью.</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="20"/>
+        <source>New receiving address</source>
+        <translation>Новый адрес для получения</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="24"/>
+        <source>New sending address</source>
+        <translation>Новый адрес для отправки</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="27"/>
+        <source>Edit receiving address</source>
+        <translation>Изменение адреса для получения</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="31"/>
+        <source>Edit sending address</source>
+        <translation>Изменение адреса для отправки</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="87"/>
+        <source>The entered address &quot;%1&quot; is already in the address book.</source>
+        <translation>Введённый адрес «%1» уже находится в адресной книге.</translation>
+    </message>
+    <message>
+        <location filename="../editaddressdialog.cpp" line="92"/>
+        <source>The entered address &quot;%1&quot; is not a valid bitcoin address.</source>
+        <translation>Введённый адрес «%1» не является правильным Bitcoin-адресом.</translation>
+    </message>
+</context>
+<context>
+    <name>MainOptionsPage</name>
+    <message>
+        <location filename="../optionsdialog.cpp" line="162"/>
+        <source>&amp;Start Bitcoin on window system startup</source>
+        <translation>&amp;Запускать бумажник при входе в систему</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="163"/>
+        <source>Automatically start Bitcoin after the computer is turned on</source>
+        <translation>Автоматически запускать бумажник, когда включается компьютер</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="166"/>
+        <source>&amp;Minimize to the tray instead of the taskbar</source>
+        <translation>&amp;Cворачивать в системный лоток вместо панели задач</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="167"/>
+        <source>Show only a tray icon after minimizing the window</source>
+        <translation>Показывать только иконку в системном лотке при сворачивании окна</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="170"/>
+        <source>Map port using &amp;UPnP</source>
+        <translation>Пробросить порт через &amp;UPnP</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="171"/>
+        <source>Automatically open the Bitcoin client port on the router. This only works when your router supports UPnP and it is enabled.</source>
+        <translation>Автоматически открыть порт для Bitcoin-клиента на роутере. Работает ТОЛЬКО если Ваш роутер поддерживает UPnP и данная функция включена.</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="174"/>
+        <source>M&amp;inimize on close</source>
+        <translation>С&amp;ворачивать вместо закрытия</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="175"/>
+        <source>Minimize instead of exit the application when the window is closed. When this option is enabled, the application will be closed only after selecting Quit in the menu.</source>
+        <translation>Сворачивать вместо закрытия. Если данная опция будет выбрана — приложение закроется только после выбора соответствующего пункта в меню.</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="178"/>
+        <source>&amp;Connect through SOCKS4 proxy:</source>
+        <translation>&amp;Подключаться через SOCKS4 прокси:</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="179"/>
+        <source>Connect to the Bitcon network through a SOCKS4 proxy (e.g. when connecting through Tor)</source>
+        <translation>Подключаться к сети Bitcoin через SOCKS4 прокси (например, при использовании Tor)</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="184"/>
+        <source>Proxy &amp;IP: </source>
+        <translation>&amp;IP Прокси: </translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="190"/>
+        <source>IP address of the proxy (e.g. 127.0.0.1)</source>
+        <translation>IP-адрес прокси (например 127.0.0.1)</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="193"/>
+        <source>&amp;Port: </source>
+        <translation>По&amp;рт: </translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="199"/>
+        <source>Port of the proxy (e.g. 1234)</source>
+        <translation>Порт прокси-сервера (например 1234)</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="205"/>
+        <source>Optional transaction fee per KB that helps make sure your transactions are processed quickly.  Most transactions are 1KB.  Fee 0.01 recommended.</source>
+        <translation>Опциональная комиссия за кадый KB транзакции, которое позволяет быть уверенным, что Ваша транзакция будет обработана быстро.  Большинство транщакций занимают 1 KB.  Рекомендованная комиссия: 0.01 BTC.</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="211"/>
+        <source>Pay transaction &amp;fee</source>
+        <translation>Добавлять ко&amp;миссию</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="214"/>
+        <source>Optional transaction fee per KB that helps make sure your transactions are processed quickly. Most transactions are 1KB. Fee 0.01 recommended.</source>
+        <translation>Опциональная комиссия за кадый KB транзакции, которая позволяет быть уверенным, что Ваша транзакция будет обработана быстро.  Большинство транзакций занимают 1 KB.  Рекомендованная комиссия: 0.01 BTC.</translation>
+    </message>
+</context>
+<context>
+    <name>OptionsDialog</name>
+    <message>
+        <location filename="../optionsdialog.cpp" line="71"/>
+        <source>Main</source>
+        <translation>Основное</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="76"/>
+        <source>Display</source>
+        <translation>Отображение</translation>
+    </message>
+    <message>
+        <location filename="../optionsdialog.cpp" line="96"/>
+        <source>Options</source>
+        <translation>Опции</translation>
+    </message>
+</context>
+<context>
+    <name>OverviewPage</name>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="14"/>
+        <source>Form</source>
+        <translation>Форма</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="40"/>
+        <source>Balance:</source>
+        <translation>Баланс:</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="47"/>
+        <source>123.456 BTC</source>
+        <translation>123.456 BTC</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="54"/>
+        <source>Number of transactions:</source>
+        <translation>Количество транзакций:</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="61"/>
+        <source>0</source>
+        <translation>0</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="68"/>
+        <source>Unconfirmed:</source>
+        <translation>Не подтверждено:</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="75"/>
+        <source>0 BTC</source>
+        <translation>0 BTC</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="82"/>
+        <source>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
+&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
+p, li { white-space: pre-wrap; }
+&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;Ubuntu&apos;; font-size:11pt; font-weight:400; font-style:normal;&quot;&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-weight:600;&quot;&gt;Wallet&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</source>
+        <translation>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
+&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
+p, li { white-space: pre-wrap; }
+&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:&apos;Ubuntu&apos;; font-size:11pt; font-weight:400; font-style:normal;&quot;&gt;
+&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-weight:600;&quot;&gt;Бумажник&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</translation>
+    </message>
+    <message>
+        <location filename="../forms/overviewpage.ui" line="122"/>
+        <source>&lt;b&gt;Recent transactions&lt;/b&gt;</source>
+        <translation>&lt;b&gt;Последние транзакции&lt;/b&gt;</translation>
+    </message>
+    <message>
+        <location filename="../overviewpage.cpp" line="102"/>
+        <source>Your current balance</source>
+        <translation>Ваш текущий баланс</translation>
+    </message>
+    <message>
+        <location filename="../overviewpage.cpp" line="107"/>
+        <source>Total of transactions that have yet to be confirmed, and do not yet count toward the current balance</source>
+        <translation>Общая сумма всех транзакций, которые до сих пор не подтверждены, и до сих пор не учитываются в текущем балансе</translation>
+    </message>
+    <message>
+        <location filename="../overviewpage.cpp" line="110"/>
+        <source>Total number of transactions in wallet</source>
+        <translation>Общая количество транзакций в Вашем бумажнике</translation>
+    </message>
+</context>
+<context>
+    <name>SendCoinsDialog</name>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="14"/>
+        <location filename="../sendcoinsdialog.cpp" line="91"/>
+        <location filename="../sendcoinsdialog.cpp" line="96"/>
+        <location filename="../sendcoinsdialog.cpp" line="101"/>
+        <location filename="../sendcoinsdialog.cpp" line="106"/>
+        <location filename="../sendcoinsdialog.cpp" line="112"/>
+        <location filename="../sendcoinsdialog.cpp" line="117"/>
+        <location filename="../sendcoinsdialog.cpp" line="123"/>
+        <source>Send Coins</source>
+        <translation>Отправка</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="67"/>
+        <source>Send to multiple recipients at once</source>
+        <translation>Отправить нескольким получателям одновременно</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="70"/>
+        <source>&amp;Add recipient...</source>
+        <translation>&amp;Добавить получателя...</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="100"/>
+        <source>Confirm the send action</source>
+        <translation>Подтвердить отправку</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsdialog.ui" line="103"/>
+        <source>&amp;Send</source>
+        <translation>&amp;Отправить</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="74"/>
+        <source>&lt;b&gt;%1&lt;/b&gt; to %2 (%3)</source>
+        <translation>&lt;b&gt;%1&lt;/b&gt; адресату %2 (%3)</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="77"/>
+        <source>Confirm send coins</source>
+        <translation>Подтвердите отправку монет</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="78"/>
+        <source>Are you sure you want to send %1?</source>
+        <translation>Вы уверены, что хотите отправить %1?</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="78"/>
+        <source> and </source>
+        <translation> и </translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="92"/>
+        <source>The recepient address is not valid, please recheck.</source>
+        <translation>Адрес получателя неверный, пожалуйста, перепроверьте.</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="97"/>
+        <source>The amount to pay must be larger than 0.</source>
+        <translation>Количество монет для отправки должно быть больше 0.</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="102"/>
+        <source>Amount exceeds your balance</source>
+        <translation>Количество отправляемых монет превышает Ваш баланс</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="107"/>
+        <source>Total exceeds your balance when the %1 transaction fee is included</source>
+        <translation>Сумма превысит Ваш баланс, если комиссия в %1 будет добавлена к транзакции</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="113"/>
+        <source>Duplicate address found, can only send to each address once in one send operation</source>
+        <translation>Обнаружен дублирующийся адрес. Отправка на один и тот же адрес возможна только один раз за одну операцию отправки</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="118"/>
+        <source>Error: Transaction creation failed  </source>
+        <translation>Ошибка: Создание транзакции не удалось  </translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsdialog.cpp" line="124"/>
+        <source>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.</source>
+        <translation>Ошибка: В транзакции отказано.  Такое может произойти, если некоторые монеты уже были потрачены, например, если Вы используете одну копию бумажника (wallet.dat), а монеты были потрачены из другой копии, но не были отмечены как потраченные в этой.  Или в случае кражи (компрометации) Вашего бумажника.</translation>
+    </message>
+</context>
+<context>
+    <name>SendCoinsEntry</name>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="14"/>
+        <source>Form</source>
+        <translation>Форма</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="29"/>
+        <source>A&amp;mount:</source>
+        <translation>Ко&amp;личество:</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="42"/>
+        <source>Pay &amp;To:</source>
+        <translation>Полу&amp;чатель:</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="66"/>
+        <location filename="../sendcoinsentry.cpp" line="22"/>
+        <source>Enter a label for this address to add it to your address book</source>
+        <translation>Введите метку для данного адреса (для добавления в адресную книгу)</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="75"/>
+        <source>&amp;Label:</source>
+        <translation>&amp;Метка:</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="93"/>
+        <source>The address to send the payment to  (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source>
+        <translation>Адрес получателя платежа (например 1LA5FtQhnnWnkK6zjFfutR7Stiit4wKd63)</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="103"/>
+        <source>Choose adress from address book</source>
+        <translation>Выбрать адрес из адресной книги</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="113"/>
+        <source>Alt+A</source>
+        <translation></translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="126"/>
+        <source>Paste address from clipboard</source>
+        <translation>Вставить адрес из буфера обмена</translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="136"/>
+        <source>Alt+P</source>
+        <translation></translation>
+    </message>
+    <message>
+        <location filename="../forms/sendcoinsentry.ui" line="146"/>
+        <source>Remove this recipient</source>
+        <translation>Удалить этого получателя</translation>
+    </message>
+    <message>
+        <location filename="../sendcoinsentry.cpp" line="21"/>
+        <source>Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source>
+        <translation>Введите Bitcoin-адрес (например 1LA5FtQhnnWnkK6zjFfutR7Stiit4wKd63)</translation>
+    </message>
+</context>
+<context>
+    <name>TransactionDesc</name>
+    <message>
+        <location filename="../transactiondesc.cpp" line="34"/>
+        <source>Open for %1 blocks</source>
+        <translation type="unfinished">Открыто до получения %1 блоков</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="36"/>
+        <source>Open until %1</source>
+        <translation type="unfinished">Открыто до %1</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="42"/>
+        <source>%1/offline?</source>
+        <translation>%1/оффлайн?</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="44"/>
+        <source>%1/unconfirmed</source>
+        <translation>%1/не подтверждено</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="46"/>
+        <source>%1 confirmations</source>
+        <translation>%1 подтверждений</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="63"/>
+        <source>&lt;b&gt;Status:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Статус:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="68"/>
+        <source>, has not been successfully broadcast yet</source>
+        <translation>, ещё не было успешно разослано</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="70"/>
+        <source>, broadcast through %1 node</source>
+        <translation>, разослано через %1 узел</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="72"/>
+        <source>, broadcast through %1 nodes</source>
+        <translation>, разослано через %1 узлов</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="76"/>
+        <source>&lt;b&gt;Date:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Дата:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="83"/>
+        <source>&lt;b&gt;Source:&lt;/b&gt; Generated&lt;br&gt;</source>
+        <translation>&lt;b&gt;Источник:&lt;/b&gt; [сгенерированно]&lt;br&gt;</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="89"/>
+        <location filename="../transactiondesc.cpp" line="106"/>
+        <source>&lt;b&gt;From:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Отправитель:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="106"/>
+        <source>unknown</source>
+        <translation>неизвестно</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="107"/>
+        <location filename="../transactiondesc.cpp" line="130"/>
+        <location filename="../transactiondesc.cpp" line="189"/>
+        <source>&lt;b&gt;To:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Получатель:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="110"/>
+        <source> (yours, label: </source>
+        <translation> (Ваш, метка:</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="112"/>
+        <source> (yours)</source>
+        <translation> (ваш)</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="147"/>
+        <location filename="../transactiondesc.cpp" line="161"/>
+        <location filename="../transactiondesc.cpp" line="206"/>
+        <location filename="../transactiondesc.cpp" line="223"/>
+        <source>&lt;b&gt;Credit:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Кредит:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="149"/>
+        <source>(%1 matures in %2 more blocks)</source>
+        <translation type="unfinished">(%1 «созреет» через %2 блоков)</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="153"/>
+        <source>(not accepted)</source>
+        <translation>(не принято)</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="197"/>
+        <location filename="../transactiondesc.cpp" line="205"/>
+        <location filename="../transactiondesc.cpp" line="220"/>
+        <source>&lt;b&gt;Debit:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Дебет:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="211"/>
+        <source>&lt;b&gt;Transaction fee:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Комиссия:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="227"/>
+        <source>&lt;b&gt;Net amount:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Общая сумма:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="233"/>
+        <source>Message:</source>
+        <translation>Сообщение:</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="235"/>
+        <source>Comment:</source>
+        <translation>Комментарий:</translation>
+    </message>
+    <message>
+        <location filename="../transactiondesc.cpp" line="238"/>
+        <source>Generated coins must wait 120 blocks before they can be spent.  When you generated this block, it was broadcast to the network to be added to the block chain.  If it fails to get into the chain, it will change to &quot;not accepted&quot; and not be spendable.  This may occasionally happen if another node generates a block within a few seconds of yours.</source>
+        <translation></translation>
+    </message>
+</context>
+<context>
+    <name>TransactionDescDialog</name>
+    <message>
+        <location filename="../forms/transactiondescdialog.ui" line="14"/>
+        <source>Transaction details</source>
+        <translation>Детали транзакции</translation>
+    </message>
+    <message>
+        <location filename="../forms/transactiondescdialog.ui" line="20"/>
+        <source>This pane shows a detailed description of the transaction</source>
+        <translation>Данный диалог показывает детализированную статистику по выбранной транзакции</translation>
+    </message>
+</context>
+<context>
+    <name>TransactionTableModel</name>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="213"/>
+        <source>Date</source>
+        <translation>Дата</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="213"/>
+        <source>Type</source>
+        <translation>Тип</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="213"/>
+        <source>Address</source>
+        <translation>Адрес</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="213"/>
+        <source>Amount</source>
+        <translation>Количество</translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../transactiontablemodel.cpp" line="274"/>
+        <source>Open for %n block(s)</source>
+        <translation type="unfinished">
+            <numerusform>Открыто до получения %n блока</numerusform>
+            <numerusform>Открыто до получения %n блоков</numerusform>
+            <numerusform>Открыто до получения %n блоков</numerusform>
+        </translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="277"/>
+        <source>Open until %1</source>
+        <translation type="unfinished">Открыто до %1</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="280"/>
+        <source>Offline (%1 confirmations)</source>
+        <translation>Оффлайн (%1 подтверждений)</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="283"/>
+        <source>Unconfirmed (%1 of %2 confirmations)</source>
+        <translation>Не подтверждено (%1 из %2 подтверждений)</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="286"/>
+        <source>Confirmed (%1 confirmations)</source>
+        <translation>Подтверждено (%1 подтверждений)</translation>
+    </message>
+    <message numerus="yes">
+        <location filename="../transactiontablemodel.cpp" line="295"/>
+        <source>Mined balance will be available in %n more blocks</source>
+        <translation>
+            <numerusform>Добытыми монетами можно будет воспользоваться через %n блок</numerusform>
+            <numerusform>Добытыми монетами можно будет воспользоваться через %n блока</numerusform>
+            <numerusform>Добытыми монетами можно будет воспользоваться через %n блоков</numerusform>
+        </translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="301"/>
+        <source>This block was not received by any other nodes and will probably not be accepted!</source>
+        <translation>Этот блок не был получен другими узлами и, возможно, не будет принят!</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="304"/>
+        <source>Generated but not accepted</source>
+        <translation>Сгенерированно, но не подтверждено</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="347"/>
+        <source>Received with</source>
+        <translation>Получено</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="349"/>
+        <source>Received from IP</source>
+        <translation>Получено с IP-адреса </translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="351"/>
+        <source>Sent to</source>
+        <translation>Отправлено</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="353"/>
+        <source>Sent to IP</source>
+        <translation>Отправлено на IP-адрес </translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="355"/>
+        <source>Payment to yourself</source>
+        <translation>Отправлено себе</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="357"/>
+        <source>Mined</source>
+        <translation>Добыто</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="395"/>
+        <source>(n/a)</source>
+        <translation>[не доступно]</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="594"/>
+        <source>Transaction status. Hover over this field to show number of confirmations.</source>
+        <translation>Статус транзакции. Подведите курсор к нужному полю для того, чтобы увидеть количество подтверждений.</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="596"/>
+        <source>Date and time that the transaction was received.</source>
+        <translation>Дата и время, когда транзакция была получена.</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="598"/>
+        <source>Type of transaction.</source>
+        <translation>Тип транзакции.</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="600"/>
+        <source>Destination address of transaction.</source>
+        <translation>Адрес назначения транзакции.</translation>
+    </message>
+    <message>
+        <location filename="../transactiontablemodel.cpp" line="602"/>
+        <source>Amount removed from or added to balance.</source>
+        <translation>Сумма, добавленная, или снятая с баланса.</translation>
+    </message>
+</context>
+<context>
+    <name>TransactionView</name>
+    <message>
+        <location filename="../transactionview.cpp" line="48"/>
+        <location filename="../transactionview.cpp" line="61"/>
+        <source>All</source>
+        <translation>Все</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="49"/>
+        <source>Today</source>
+        <translation>Сегодня</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="50"/>
+        <source>This week</source>
+        <translation>На этой неделе</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="51"/>
+        <source>This month</source>
+        <translation>В этом месяце</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="52"/>
+        <source>Last month</source>
+        <translation>За последний месяц</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="53"/>
+        <source>This year</source>
+        <translation>В этом году</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="54"/>
+        <source>Range...</source>
+        <translation>Промежуток...</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="62"/>
+        <source>Received with</source>
+        <translation>Получено на</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="64"/>
+        <source>Sent to</source>
+        <translation>Отправлено на</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="66"/>
+        <source>To yourself</source>
+        <translation>Отправленные себе</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="67"/>
+        <source>Mined</source>
+        <translation>Добытые</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="68"/>
+        <source>Other</source>
+        <translation>Другое</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="74"/>
+        <source>Enter address or label to search</source>
+        <translation>Введите адрес или метку для поиска</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="80"/>
+        <source>Min amount</source>
+        <translation>Мин. сумма</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="108"/>
+        <source>Copy address</source>
+        <translation>Копировать адрес</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="109"/>
+        <source>Copy label</source>
+        <translation>Копировать метку</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="110"/>
+        <source>Edit label</source>
+        <translation>Изменить метку</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="111"/>
+        <source>Show details...</source>
+        <translation>Показать детали...</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="244"/>
+        <source>Export Transaction Data</source>
+        <translation>Экспортировать данные транзакций</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="246"/>
+        <source>Comma separated file (*.csv)</source>
+        <translation>Текс, разделённый запятыми (*.csv)</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="254"/>
+        <source>Confirmed</source>
+        <translation>Подтверждено</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="255"/>
+        <source>Date</source>
+        <translation>Дата</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="256"/>
+        <source>Type</source>
+        <translation>Тип</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="257"/>
+        <source>Label</source>
+        <translation>Метка</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="258"/>
+        <source>Address</source>
+        <translation>Адрес</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="259"/>
+        <source>Amount</source>
+        <translation>Количество</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="260"/>
+        <source>ID</source>
+        <translation></translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="264"/>
+        <source>Error exporting</source>
+        <translation>Ошибка экспорта</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="264"/>
+        <source>Could not write to file %1.</source>
+        <translation>Невозможно записать в файл %1.</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="352"/>
+        <source>Range:</source>
+        <translation>Промежуток от:</translation>
+    </message>
+    <message>
+        <location filename="../transactionview.cpp" line="360"/>
+        <source>to</source>
+        <translation>до</translation>
+    </message>
+</context>
+<context>
+    <name>WalletModel</name>
+    <message>
+        <location filename="../walletmodel.cpp" line="139"/>
+        <source>Sending...</source>
+        <translation>Отправка....</translation>
+    </message>
+</context>
+<context>
+    <name>bitcoin-core</name>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="3"/>
+        <source>Bitcoin version</source>
+        <translation>Версия</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="4"/>
+        <source>Usage:</source>
+        <translation>Использование:</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="5"/>
+        <source>Send command to -server or bitcoind
+</source>
+        <translation>Отправить команду на сервер ( -server ) или демону
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="6"/>
+        <source>List commands
+</source>
+        <translation>Список команд
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="7"/>
+        <source>Get help for a command
+</source>
+        <translation>Получить помощь по команде</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="8"/>
+        <source>Options:
+</source>
+        <translation>Опции:
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="9"/>
+        <source>Specify configuration file (default: bitcoin.conf)
+</source>
+        <translation>Указать конфигурационный файл вместо используемого по умолчанию (bitcoin.conf)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="10"/>
+        <source>Specify pid file (default: bitcoind.pid)
+</source>
+        <translation>Указать pid-файл вместо используемого по умолчанию (bitcoin.pid)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="11"/>
+        <source>Generate coins
+</source>
+        <translation>Включить добычу монет
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="12"/>
+        <source>Don&apos;t generate coins
+</source>
+        <translation>Выключить добычу монет
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="13"/>
+        <source>Start minimized
+</source>
+        <translation>Запускать минимизированным
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="14"/>
+        <source>Specify data directory
+</source>
+        <translation>Указать рабочую директорию
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="15"/>
+        <source>Specify connection timeout (in milliseconds)
+</source>
+        <translation>Указать таймаут соединения (в миллисекундах)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="16"/>
+        <source>Connect through socks4 proxy
+</source>
+        <translation>Соединяться через socks4-прокси
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="17"/>
+        <source>Allow DNS lookups for addnode and connect
+</source>
+        <translation>Разрешить поиск в DNS для комманд &quot;addnode&quot; и &quot;connect&quot;
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="18"/>
+        <source>Add a node to connect to
+</source>
+        <translation>Добавить узел для соединения
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="19"/>
+        <source>Connect only to the specified node
+</source>
+        <translation>Соединяться только с указанным узлом
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="20"/>
+        <source>Don&apos;t accept connections from outside
+</source>
+        <translation>Не принимать внешние соединения
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="21"/>
+        <source>Don&apos;t attempt to use UPnP to map the listening port
+</source>
+        <translation>Не пытаться использовать UPnP
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="22"/>
+        <source>Attempt to use UPnP to map the listening port
+</source>
+        <translation>Попытаться использовать UPnP для проброса прослушиваемого порта на роутере
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="23"/>
+        <source>Fee per KB to add to transactions you send
+</source>
+        <translation>Комиссия (за каждый KB транзакции)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="24"/>
+        <source>Accept command line and JSON-RPC commands
+</source>
+        <translation>Принимать команды из командной строки и через JSON-RPC
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="25"/>
+        <source>Run in the background as a daemon and accept commands
+</source>
+        <translation>Запустить в бекграунде (как демон) и принимать команды
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="26"/>
+        <source>Use the test network
+</source>
+        <translation>Использовать тестовую сеть
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="27"/>
+        <source>Username for JSON-RPC connections
+</source>
+        <translation>Имя пользователя для JSON-RPC соединений
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="28"/>
+        <source>Password for JSON-RPC connections
+</source>
+        <translation>Пароль для JSON-RPC соединений
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="29"/>
+        <source>Listen for JSON-RPC connections on &lt;port&gt; (default: 8332)
+</source>
+        <translation>Слушать &lt;порт&gt; для JSON-RPC соединений (по умолчанию: 8332)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="30"/>
+        <source>Allow JSON-RPC connections from specified IP address
+</source>
+        <translation>Разрешить JSON-RPC соединения с указанного адреса
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="31"/>
+        <source>Send commands to node running on &lt;ip&gt; (default: 127.0.0.1)
+</source>
+        <translation>Отправлять команды на узел,запущенный на &lt;IP&gt; (по умолчанию: 127.0.0.1)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="32"/>
+        <source>Set key pool size to &lt;n&gt; (default: 100)
+</source>
+        <translation>Установить размер key pool&apos;а в &lt;n&gt; (по умолчанию: 100)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="33"/>
+        <source>Rescan the block chain for missing wallet transactions
+</source>
+        <translation>Просканировать цепочку блоков в поисках пропущенных транзакций для бумажника
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="34"/>
+        <source>
+SSL options: (see the Bitcoin Wiki for SSL setup instructions)
+</source>
+        <translation>Опции SSL: (см. Bitcoin Wiki для инструкций)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="37"/>
+        <source>Use OpenSSL (https) for JSON-RPC connections
+</source>
+        <translation>Использовать OpenSSL (https) для JSON-RPC соединений
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="38"/>
+        <source>Server certificate file (default: server.cert)
+</source>
+        <translation>Сертификат (публичный ключ) сервера (по умолчанию: server.cert)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="39"/>
+        <source>Server private key (default: server.pem)
+</source>
+        <translation>Закрытый ключ сервера (по умолчанию: server.pem)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="40"/>
+        <source>Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)
+</source>
+        <translation>Допустимые Cipher&apos;ы для сервера (по умолчанию: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="43"/>
+        <source>This help message
+</source>
+        <translation>Данная справка
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="44"/>
+        <source>Cannot obtain a lock on data directory %s.  Bitcoin is probably already running.</source>
+        <translation>Невозможно установить блокировку на рабочую директорию %s.  Возможно, бумажник уже запущен.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="47"/>
+        <source>Loading addresses...</source>
+        <translation>Загрузка адресов...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="48"/>
+        <source>Error loading addr.dat      
+</source>
+        <translation>Ошибка при загрузке addr.dat      
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="49"/>
+        <source>Loading block index...</source>
+        <translation>Загрузка индекса блоков...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="50"/>
+        <source>Error loading blkindex.dat      
+</source>
+        <translation>Ошибка при загрузке blkindex.dat      
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="51"/>
+        <source>Loading wallet...</source>
+        <translation>Загрузка бумажника...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="52"/>
+        <source>Error loading wallet.dat: Wallet corrupted      
+</source>
+        <translation>Ошибка загрузки wallet.dat: Бумажник повреждён</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="53"/>
+        <source>Error loading wallet.dat: Wallet requires newer version of Bitcoin      
+</source>
+        <translation>Ошибка загрузки wallet.dat: Для данного бумажника требуется более новая версия Bitcoin      
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="55"/>
+        <source>Error loading wallet.dat      
+</source>
+        <translation>Ошибка при загрузке wallet.dat      
+</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="56"/>
+        <source>Rescanning...</source>
+        <translation>Сканирование...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="57"/>
+        <source>Done loading</source>
+        <translation>Загрузка завершена</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="58"/>
+        <source>Invalid -proxy address</source>
+        <translation>Ошибка в адресе прокси</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="59"/>
+        <source>Invalid amount for -paytxfee=&lt;amount&gt;</source>
+        <translation>Ошибка в сумме комиссии</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="60"/>
+        <source>Warning: -paytxfee is set very high.  This is the transaction fee you will pay if you send a transaction.</source>
+        <translation>ВНИМАНИЕ: Установлена слишком большая комиссия (-paytxfee=).  Данный параметр отвечает за комиссию, которую Вы будете добавлять к сумме при осуществлении транзакций.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="63"/>
+        <source>Error: CreateThread(StartNode) failed</source>
+        <translation>Ошибка: Созданиние потока (запуск узла) не удался</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="64"/>
+        <source>Warning: Disk space is low  </source>
+        <translation>ВНИМАНИЕ: На диске заканчивается свободное пространство  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="68"/>
+        <source>This transaction is over the size limit.  You can still send it for a fee of %s, which goes to the nodes that process your transaction and helps to support the network.  Do you want to pay the fee?</source>
+        <translation>Данная транзакция превышает предельно допустимый размер.  Но Вы можете всё равно совершить ей, добавив комиссию в %s, которая отправится тем узлам, которые обработают Вашу транзакцию и поможет поддержать сеть.  Вы хотите добавить комиссию?</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="72"/>
+        <source>Enter the current passphrase to the wallet.</source>
+        <translation>Введите текущий пароль от бумажника.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="73"/>
+        <source>Passphrase</source>
+        <translation>Пароль</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="74"/>
+        <source>Please supply the current wallet decryption passphrase.</source>
+        <translation>Пожалуйста, укажите текущий пароль для расшифровки бумажника.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="75"/>
+        <source>The passphrase entered for the wallet decryption was incorrect.</source>
+        <translation>Указанный пароль не подходит.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="76"/>
+        <source>Status</source>
+        <translation>Статус</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="77"/>
+        <source>Date</source>
+        <translation>Дата</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="78"/>
+        <source>Description</source>
+        <translation>Описание</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="79"/>
+        <source>Debit</source>
+        <translation>Дебет</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="80"/>
+        <source>Credit</source>
+        <translation>Кредит</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="81"/>
+        <source>Open for %d blocks</source>
+        <translation>Открыто до получения %d блоков</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="82"/>
+        <source>Open until %s</source>
+        <translation>Открыто до %s</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="83"/>
+        <source>%d/offline?</source>
+        <translation>%d/оффлайн?</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="84"/>
+        <source>%d/unconfirmed</source>
+        <translation>%d/не подтверждено</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="85"/>
+        <source>%d confirmations</source>
+        <translation>%d подтверждений</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="86"/>
+        <source>Generated</source>
+        <translation>Сгенерированно</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="87"/>
+        <source>Generated (%s matures in %d more blocks)</source>
+        <translation>Сгенерированно (%s «созреет» через %d блоков)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="88"/>
+        <source>Generated - Warning: This block was not received by any other nodes and will probably not be accepted!</source>
+        <translation>Сгенерированно - ВНИМАНИЕ: Данный блок не был получен ни одним другим узлом и, возможно, не будет подтверждён!</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="91"/>
+        <source>Generated (not accepted)</source>
+        <translation>Сгенерированно (не подтверждено)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="92"/>
+        <source>From: </source>
+        <translation>Отправитель: </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="93"/>
+        <source>Received with: </source>
+        <translation>Получатель: </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="94"/>
+        <source>Payment to yourself</source>
+        <translation>Отправлено себе</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="95"/>
+        <source>To: </source>
+        <translation>Получатель: </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="96"/>
+        <source>    Generating</source>
+        <translation>    Генерация</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="97"/>
+        <source>(not connected)</source>
+        <translation>(не подключено)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="98"/>
+        <source>     %d connections     %d blocks     %d transactions</source>
+        <translation>     %d подключений     %d блоков     %d транзакций</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="99"/>
+        <source>Wallet already encrypted.</source>
+        <translation>Бумажник уже зашифрован.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="100"/>
+        <source>Enter the new passphrase to the wallet.
+Please use a passphrase of 10 or more random characters, or eight or more words.</source>
+        <translation>Введите новый пароль для бумажника.
+Пожалуйста, используейте пароль из 10 и более случайных символов или из 8 и более слов.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="104"/>
+        <source>Error: The supplied passphrase was too short.</source>
+        <translation>ОШИБКА: Указанный пароль слишком короткий.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="105"/>
+        <source>WARNING: If you encrypt your wallet and lose your passphrase, you will LOSE ALL OF YOUR BITCOINS!
+Are you sure you wish to encrypt your wallet?</source>
+        <translation>ВНИМАНИЕ: Если Вы зашифруете Ваш бумажник и потеряете Ваш пароль — Вы ПОТЕРЯЕТЕ ВСЕ ВАШИ БИТКОИНЫ!!!
+Вы уверены, что хотите зашифровать бумажник?</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="109"/>
+        <source>Please re-enter your new wallet passphrase.</source>
+        <translation>Пожалуйста, повторите ввод нового пароля.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="110"/>
+        <source>Error: the supplied passphrases didn&apos;t match.</source>
+        <translation>ОШИБКА: указанные пароли не совпадают.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="111"/>
+        <source>Wallet encryption failed.</source>
+        <translation>Шифрование бумажника не удалось.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="112"/>
+        <source>Wallet Encrypted.
+Remember that encrypting your wallet cannot fully protect your bitcoins from being stolen by malware infecting your computer.</source>
+        <translation>Бумажник зашифрован.
+Запомните, что шифрование Вашего бумажника не может ПОЛНОСТЬЮ гарантировать защиту Ваших биткоинов от того, чтобы быть украденными с помощью шпионского ПО на Вашем компьютере. Пожалуйста, следите за безопасностью Вашего компьютера самостоятельно.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="116"/>
+        <source>Wallet is unencrypted, please encrypt it first.</source>
+        <translation>Бумажник не зашифрован. Сначала зашифруйте его.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="117"/>
+        <source>Enter the new passphrase for the wallet.</source>
+        <translation>Введите новый пароль для бумажника.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="118"/>
+        <source>Re-enter the new passphrase for the wallet.</source>
+        <translation>Пожалуйста, повторите ввод нового пароля.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="119"/>
+        <source>Wallet Passphrase Changed.</source>
+        <translation>Пароль от бумажника изменён.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="120"/>
+        <source>New Receiving Address</source>
+        <translation>Новый адрес для получения</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="121"/>
+        <source>You should use a new address for each payment you receive.
+
+Label</source>
+        <translation>Вы должны использовать новый адрес для каждого платежа, который Вы получаете.
+
+Метка</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="125"/>
+        <source>&lt;b&gt;Status:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Статус:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="126"/>
+        <source>, has not been successfully broadcast yet</source>
+        <translation>, ещё не было успешно разослано</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="127"/>
+        <source>, broadcast through %d node</source>
+        <translation>, разослано через %d узел</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="128"/>
+        <source>, broadcast through %d nodes</source>
+        <translation>, разослано через %d узлов</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="129"/>
+        <source>&lt;b&gt;Date:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Дата:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="130"/>
+        <source>&lt;b&gt;Source:&lt;/b&gt; Generated&lt;br&gt;</source>
+        <translation>&lt;b&gt;Источник:&lt;/b&gt; [сгенерированно]&lt;br&gt;</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="131"/>
+        <source>&lt;b&gt;From:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Отправитель:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="132"/>
+        <source>unknown</source>
+        <translation>неизвестно</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="133"/>
+        <source>&lt;b&gt;To:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Получатель:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="134"/>
+        <source> (yours, label: </source>
+        <translation> (Ваш, метка: </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="135"/>
+        <source> (yours)</source>
+        <translation> (ваш)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="136"/>
+        <source>&lt;b&gt;Credit:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Кредит:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="137"/>
+        <source>(%s matures in %d more blocks)</source>
+        <translation>(%s «созреет» через %d блоков)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="138"/>
+        <source>(not accepted)</source>
+        <translation>(не принято)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="139"/>
+        <source>&lt;b&gt;Debit:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Дебет:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="140"/>
+        <source>&lt;b&gt;Transaction fee:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Комиссия:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="141"/>
+        <source>&lt;b&gt;Net amount:&lt;/b&gt; </source>
+        <translation>&lt;b&gt;Общая сумма:&lt;/b&gt; </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="142"/>
+        <source>Message:</source>
+        <translation>Сообщение:</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="143"/>
+        <source>Comment:</source>
+        <translation>Комментарий:</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="144"/>
+        <source>Generated coins must wait 120 blocks before they can be spent.  When you generated this block, it was broadcast to the network to be added to the block chain.  If it fails to get into the chain, it will change to &quot;not accepted&quot; and not be spendable.  This may occasionally happen if another node generates a block within a few seconds of yours.</source>
+        <translation>Сгенерированные монеты должны подождать 120 блоков прежде, чем они смогут быть отправлены.  Когда Вы сгенерировали этот блок он был отправлен в сеть, чтобы он был добавлен к цепочке блоков.  Если данная процедура не удастся, статус изменится на «не подтверждено» и монеты будут непередаваемыми.  Такое может случайно происходить в случае, если другой узел сгенерирует блок на несколько секунд раньше.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="150"/>
+        <source>Cannot write autostart/bitcoin.desktop file</source>
+        <translation>Не возможно записать файл autostart/bitcoin.desktop</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="151"/>
+        <source>Main</source>
+        <translation>Основное</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="152"/>
+        <source>&amp;Start Bitcoin on window system startup</source>
+        <translation>&amp;Запускать бумажник при входе в систему</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="153"/>
+        <source>&amp;Minimize on close</source>
+        <translation>С&amp;ворачивать вместо закрытия</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="154"/>
+        <source>version %s</source>
+        <translation>версия %s</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="155"/>
+        <source>Error in amount  </source>
+        <translation>Ошибка в количестве  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="156"/>
+        <source>Send Coins</source>
+        <translation>Отправка</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="157"/>
+        <source>Amount exceeds your balance  </source>
+        <translation>Сумма превышает Ваш баланс  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="158"/>
+        <source>Total exceeds your balance when the </source>
+        <translation>Общая сумма превысит Ваш баланс, если к транзакции будет добавлено ещё</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="159"/>
+        <source> transaction fee is included  </source>
+        <translation>в качестве комиссии  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="160"/>
+        <source>Payment sent  </source>
+        <translation>Платёж отправлен</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="162"/>
+        <source>Invalid address  </source>
+        <translation>Ошибочный адрес  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="163"/>
+        <source>Sending %s to %s</source>
+        <translation>Отправка %s адресату %s</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="164"/>
+        <source>CANCELLED</source>
+        <translation>ОТМЕНЕНО</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="165"/>
+        <source>Cancelled</source>
+        <translation>Отменено</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="166"/>
+        <source>Transfer cancelled  </source>
+        <translation>Транзакция отменена  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="167"/>
+        <source>Error: </source>
+        <translation>ОШИБКА: </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="169"/>
+        <source>Connecting...</source>
+        <translation>Подключение...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="170"/>
+        <source>Unable to connect</source>
+        <translation>Невозможно подключиться</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="171"/>
+        <source>Requesting public key...</source>
+        <translation>Запрашивается открытый ключ...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="172"/>
+        <source>Received public key...</source>
+        <translation>Получается публичный ключ...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="173"/>
+        <source>Recipient is not accepting transactions sent by IP address</source>
+        <translation>Получатель не принимает транзакции, отправленные на IP адрес</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="174"/>
+        <source>Transfer was not accepted</source>
+        <translation>Передача была отвергнута</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="175"/>
+        <source>Invalid response received</source>
+        <translation>Получен неверный ответ</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="176"/>
+        <source>Creating transaction...</source>
+        <translation>Создание транзакции...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="177"/>
+        <source>This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds</source>
+        <translation>Данная транзакция требует добавления комиссии (по крайней мере в %s) из-за её размера, сложности, или из-за использования недавно полученных монет</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="180"/>
+        <source>Transaction creation failed</source>
+        <translation>Создание транзакции провалилось</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="181"/>
+        <source>Transaction aborted</source>
+        <translation>Транзакция отменена</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="182"/>
+        <source>Lost connection, transaction cancelled</source>
+        <translation>Потеряно соединение, транзакция отменена</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="183"/>
+        <source>Sending payment...</source>
+        <translation>Отправка платежа...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="184"/>
+        <source>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.</source>
+        <translation>В транзакции отказано.  Такое может произойти, если некоторые монеты уже были потрачены, например, если Вы используете одну копию бумажника (wallet.dat), а монеты были потрачены из другой копии, но не были отмечены как потраченные в этой.  Или в случае кражи (компрометации) Вашего бумажника.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="188"/>
+        <source>Waiting for confirmation...</source>
+        <translation>Ожидание подтверждения...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="189"/>
+        <source>The payment was sent, but the recipient was unable to verify it.
+The transaction is recorded and will credit to the recipient,
+but the comment information will be blank.</source>
+        <translation>Платёж был отправлен, но получатель не смог подтвердить его.
+Транзакция записана и будет зачислена получателю,
+но комментарий к платежу будет пустым.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="193"/>
+        <source>Payment was sent, but an invalid response was received</source>
+        <translation>Платёж был отправлен, но был получен неверный ответ</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="194"/>
+        <source>Payment completed</source>
+        <translation>Платёж завершён</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="195"/>
+        <source>Name</source>
+        <translation>Имя</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="196"/>
+        <source>Address</source>
+        <translation>Адрес</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="197"/>
+        <source>Label</source>
+        <translation>Метка</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="198"/>
+        <source>Bitcoin Address</source>
+        <translation>Bitcoin-адрес</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="199"/>
+        <source>This is one of your own addresses for receiving payments and cannot be entered in the address book.  </source>
+        <translation>Это один из Ваших личных адресов для получения платежей. Он не может быть добавлен в адресную книгу.  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="202"/>
+        <source>Edit Address</source>
+        <translation>Изменить адрес</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="203"/>
+        <source>Edit Address Label</source>
+        <translation>Изменить метку</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="204"/>
+        <source>Add Address</source>
+        <translation>Добавить адрес</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="205"/>
+        <source>Bitcoin</source>
+        <translation></translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="206"/>
+        <source>Bitcoin - Generating</source>
+        <translation>Bitcoin - Генерация</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="207"/>
+        <source>Bitcoin - (not connected)</source>
+        <translation>Bitcoin - (нет связи)</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="208"/>
+        <source>&amp;Open Bitcoin</source>
+        <translation>&amp;Показать бумажник</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="209"/>
+        <source>&amp;Send Bitcoins</source>
+        <translation>Отп&amp;равка</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="210"/>
+        <source>O&amp;ptions...</source>
+        <translation>Оп&amp;ции...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="211"/>
+        <source>E&amp;xit</source>
+        <translation>Вы&amp;ход</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="212"/>
+        <source>Program has crashed and will terminate.  </source>
+        <translation>Программа экстренно завершилась и будет уничтожена.  </translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="216"/>
+        <source>beta</source>
+        <translation>бета</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="161"/>
+        <source>Sending...</source>
+        <translation>Отправка...</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="168"/>
+        <source>Insufficient funds</source>
+        <translation>Недостаточно монет</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="65"/>
+        <source>Unable to bind to port %d on this computer.  Bitcoin is probably already running.</source>
+        <translation>Невозможно забиндить порт %d на данном компьютере.  Возможно, бумажник ужк запущен.</translation>
+    </message>
+    <message>
+        <location filename="../bitcoinstrings.cpp" line="213"/>
+        <source>Warning: Please check that your computer&apos;s date and time are correct.  If your clock is wrong Bitcoin will not work properly.</source>
+        <translation>ВНИМАНИЕ: Проверьте дату и время, установленные на Вашем компьютере. Если Ваши часы идут не правильно Bitcoin может наботать не корректно.</translation>
+    </message>
+</context>
+</TS>
diff --git a/src/qt/monitoreddatamapper.cpp b/src/qt/monitoreddatamapper.cpp
new file mode 100644 (file)
index 0000000..88948d0
--- /dev/null
@@ -0,0 +1,36 @@
+#include "monitoreddatamapper.h"
+
+#include <QWidget>
+#include <QMetaObject>
+#include <QMetaProperty>
+
+MonitoredDataMapper::MonitoredDataMapper(QObject *parent) :
+    QDataWidgetMapper(parent)
+{
+}
+
+
+void MonitoredDataMapper::addMapping(QWidget *widget, int section)
+{
+    QDataWidgetMapper::addMapping(widget, section);
+    addChangeMonitor(widget);
+}
+
+void MonitoredDataMapper::addMapping(QWidget *widget, int section, const QByteArray &propertyName)
+{
+    QDataWidgetMapper::addMapping(widget, section, propertyName);
+    addChangeMonitor(widget);
+}
+
+void MonitoredDataMapper::addChangeMonitor(QWidget *widget)
+{
+    // Watch user property of widget for changes, and connect
+    //  the signal to our viewModified signal.
+    QMetaProperty prop = widget->metaObject()->userProperty();
+    int signal = prop.notifySignalIndex();
+    int method = this->metaObject()->indexOfMethod("viewModified()");
+    if(signal != -1 && method != -1)
+    {
+        QMetaObject::connect(widget, signal, this, method);
+    }
+}
diff --git a/src/qt/monitoreddatamapper.h b/src/qt/monitoreddatamapper.h
new file mode 100644 (file)
index 0000000..4dd2d1a
--- /dev/null
@@ -0,0 +1,32 @@
+#ifndef MONITOREDDATAMAPPER_H
+#define MONITOREDDATAMAPPER_H
+
+#include <QDataWidgetMapper>
+
+QT_BEGIN_NAMESPACE
+class QWidget;
+QT_END_NAMESPACE
+
+/* Data <-> Widget mapper that watches for changes,
+   to be able to notify when 'dirty' (for example, to
+   enable a commit/apply button).
+ */
+class MonitoredDataMapper : public QDataWidgetMapper
+{
+    Q_OBJECT
+public:
+    explicit MonitoredDataMapper(QObject *parent=0);
+
+    void addMapping(QWidget *widget, int section);
+    void addMapping(QWidget *widget, int section, const QByteArray &propertyName);
+private:
+    void addChangeMonitor(QWidget *widget);
+
+signals:
+    void viewModified();
+
+};
+
+
+
+#endif // MONITOREDDATAMAPPER_H
diff --git a/src/qt/notificator.cpp b/src/qt/notificator.cpp
new file mode 100644 (file)
index 0000000..86ccfc8
--- /dev/null
@@ -0,0 +1,224 @@
+#include "notificator.h"
+
+#include <QMetaType>
+#include <QVariant>
+#include <QIcon>
+#include <QApplication>
+#include <QStyle>
+#include <QByteArray>
+#include <QSystemTrayIcon>
+#include <QMessageBox>
+
+#ifdef QT_DBUS
+#include <QtDBus/QtDBus>
+#include <stdint.h>
+#endif
+
+// https://wiki.ubuntu.com/NotificationDevelopmentGuidelines recommends at least 128
+const int FREEDESKTOP_NOTIFICATION_ICON_SIZE = 128;
+
+Notificator::Notificator(const QString &programName, QSystemTrayIcon *trayicon, QWidget *parent):
+    QObject(parent),
+    parent(parent),
+    programName(programName),
+    mode(None),
+    trayIcon(trayicon)
+#ifdef QT_DBUS
+    ,interface(0)
+#endif
+{
+    if(trayicon && trayicon->supportsMessages())
+    {
+        mode = QSystemTray;
+    }
+#ifdef QT_DBUS
+    interface = new QDBusInterface("org.freedesktop.Notifications",
+          "/org/freedesktop/Notifications", "org.freedesktop.Notifications");
+    if(interface->isValid())
+    {
+        mode = Freedesktop;
+    }
+#endif
+}
+
+Notificator::~Notificator()
+{
+#ifdef QT_DBUS
+    delete interface;
+#endif
+}
+
+#ifdef QT_DBUS
+
+// Loosely based on http://www.qtcentre.org/archive/index.php/t-25879.html
+class FreedesktopImage
+{
+public:
+    FreedesktopImage() {}
+    FreedesktopImage(const QImage &img);
+
+    static int metaType();
+
+    // Image to variant that can be marshaled over DBus
+    static QVariant toVariant(const QImage &img);
+
+private:
+    int width, height, stride;
+    bool hasAlpha;
+    int channels;
+    int bitsPerSample;
+    QByteArray image;
+
+    friend QDBusArgument &operator<<(QDBusArgument &a, const FreedesktopImage &i);
+    friend const QDBusArgument &operator>>(const QDBusArgument &a, FreedesktopImage &i);
+};
+
+Q_DECLARE_METATYPE(FreedesktopImage);
+
+// Image configuration settings
+const int CHANNELS = 4;
+const int BYTES_PER_PIXEL = 4;
+const int BITS_PER_SAMPLE = 8;
+
+FreedesktopImage::FreedesktopImage(const QImage &img):
+    width(img.width()),
+    height(img.height()),
+    stride(img.width() * BYTES_PER_PIXEL),
+    hasAlpha(true),
+    channels(CHANNELS),
+    bitsPerSample(BITS_PER_SAMPLE)
+{
+    // Convert 00xAARRGGBB to RGBA bytewise (endian-independent) format
+    QImage tmp = img.convertToFormat(QImage::Format_ARGB32);
+    const uint32_t *data = reinterpret_cast<const uint32_t*>(tmp.constBits());
+
+    unsigned int num_pixels = width * height;
+    image.resize(num_pixels * BYTES_PER_PIXEL);
+
+    for(unsigned int ptr = 0; ptr < num_pixels; ++ptr)
+    {
+        image[ptr*BYTES_PER_PIXEL+0] = data[ptr] >> 16; // R
+        image[ptr*BYTES_PER_PIXEL+1] = data[ptr] >> 8;  // G
+        image[ptr*BYTES_PER_PIXEL+2] = data[ptr];       // B
+        image[ptr*BYTES_PER_PIXEL+3] = data[ptr] >> 24; // A
+    }
+}
+
+QDBusArgument &operator<<(QDBusArgument &a, const FreedesktopImage &i)
+{
+    a.beginStructure();
+    a << i.width << i.height << i.stride << i.hasAlpha << i.bitsPerSample << i.channels << i.image;
+    a.endStructure();
+    return a;
+}
+
+const QDBusArgument &operator>>(const QDBusArgument &a, FreedesktopImage &i)
+{
+    a.beginStructure();
+    a >> i.width >> i.height >> i.stride >> i.hasAlpha >> i.bitsPerSample >> i.channels >> i.image;
+    a.endStructure();
+    return a;
+}
+
+int FreedesktopImage::metaType()
+{
+    return qDBusRegisterMetaType<FreedesktopImage>();
+}
+
+QVariant FreedesktopImage::toVariant(const QImage &img)
+{
+    FreedesktopImage fimg(img);
+    return QVariant(FreedesktopImage::metaType(), &fimg);
+}
+
+void Notificator::notifyDBus(Class cls, const QString &title, const QString &text, const QIcon &icon, int millisTimeout)
+{
+    Q_UNUSED(cls);
+    // Arguments for DBus call:
+    QList<QVariant> args;
+
+    // Program Name:
+    args.append(programName);
+
+    // Unique ID of this notification type:
+    args.append(0U);
+
+    // Application Icon, empty string
+    args.append(QString());
+
+    // Summary
+    args.append(title);
+
+    // Body
+    args.append(text);
+
+    // Actions (none, actions are deprecated)
+    QStringList actions;
+    args.append(actions);
+
+    // Hints
+    QVariantMap hints;
+
+    // If no icon specified, set icon based on class
+    QIcon tmpicon;
+    if(icon.isNull())
+    {
+        QStyle::StandardPixmap sicon = QStyle::SP_MessageBoxQuestion;
+        switch(cls)
+        {
+        case Information: sicon = QStyle::SP_MessageBoxInformation; break;
+        case Warning: sicon = QStyle::SP_MessageBoxWarning; break;
+        case Critical: sicon = QStyle::SP_MessageBoxCritical; break;
+        default: break;
+        }
+        tmpicon = QApplication::style()->standardIcon(sicon);
+    }
+    else
+    {
+        tmpicon = icon;
+    }
+    hints["icon_data"] = FreedesktopImage::toVariant(tmpicon.pixmap(FREEDESKTOP_NOTIFICATION_ICON_SIZE).toImage());
+    args.append(hints);
+
+    // Timeout (in msec)
+    args.append(millisTimeout);
+
+    // "Fire and forget"
+    interface->callWithArgumentList(QDBus::NoBlock, "Notify", args);
+}
+#endif
+
+void Notificator::notifySystray(Class cls, const QString &title, const QString &text, const QIcon &icon, int millisTimeout)
+{
+    Q_UNUSED(icon);
+    QSystemTrayIcon::MessageIcon sicon = QSystemTrayIcon::NoIcon;
+    switch(cls) // Set icon based on class
+    {
+    case Information: sicon = QSystemTrayIcon::Information; break;
+    case Warning: sicon = QSystemTrayIcon::Warning; break;
+    case Critical: sicon = QSystemTrayIcon::Critical; break;
+    }
+    trayIcon->showMessage(title, text, sicon, millisTimeout);
+}
+
+void Notificator::notify(Class cls, const QString &title, const QString &text, const QIcon &icon, int millisTimeout)
+{
+    switch(mode)
+    {
+#ifdef QT_DBUS
+    case Freedesktop:
+        notifyDBus(cls, title, text, icon, millisTimeout);
+        break;
+#endif
+    case QSystemTray:
+        notifySystray(cls, title, text, icon, millisTimeout);
+        break;
+    default:
+        if(cls == Critical)
+        {
+            // Fall back to old fashioned popup dialog if critical and no other notification available
+            QMessageBox::critical(parent, title, text, QMessageBox::Ok, QMessageBox::Ok);
+        }
+        break;
+    }
+}
diff --git a/src/qt/notificator.h b/src/qt/notificator.h
new file mode 100644 (file)
index 0000000..13f6a90
--- /dev/null
@@ -0,0 +1,63 @@
+#ifndef NOTIFICATOR_H
+#define NOTIFICATOR_H
+
+#include <QObject>
+#include <QIcon>
+
+QT_BEGIN_NAMESPACE
+class QSystemTrayIcon;
+#ifdef QT_DBUS
+class QDBusInterface;
+#endif
+QT_END_NAMESPACE
+
+// Cross-platform desktop notification client
+class Notificator: public QObject
+{
+    Q_OBJECT
+public:
+    // Create a new notificator
+    // Ownership of trayIcon is not transferred to this object
+    Notificator(const QString &programName=QString(), QSystemTrayIcon *trayIcon=0, QWidget *parent=0);
+    ~Notificator();
+
+    // Message class
+    enum Class
+    {
+        Information,
+        Warning,
+        Critical,
+    };
+
+public slots:
+
+    /* Show notification message.
+     *
+     *  cls: general message class
+     *  title: title shown with message
+     *  text: message content
+     *  icon: optional icon to show with message
+     *  millisTimeout: notification timeout in milliseconds (default 10 seconds)
+     */
+    void notify(Class cls, const QString &title, const QString &text,
+                const QIcon &icon = QIcon(), int millisTimeout = 10000);
+
+private:
+    QWidget *parent;
+    enum Mode {
+        None,
+        Freedesktop, // Use DBus org.freedesktop.Notifications
+        QSystemTray, // Use QSystemTray::showMessage
+    };
+    QString programName;
+    Mode mode;
+    QSystemTrayIcon *trayIcon;
+#ifdef QT_DBUS
+    QDBusInterface *interface;
+
+    void notifyDBus(Class cls, const QString &title, const QString &text, const QIcon &icon, int millisTimeout);
+#endif
+    void notifySystray(Class cls, const QString &title, const QString &text, const QIcon &icon, int millisTimeout);
+};
+
+#endif // NOTIFICATOR_H
diff --git a/src/qt/optionsdialog.cpp b/src/qt/optionsdialog.cpp
new file mode 100644 (file)
index 0000000..0eeb6f8
--- /dev/null
@@ -0,0 +1,277 @@
+#include "optionsdialog.h"
+#include "optionsmodel.h"
+#include "bitcoinamountfield.h"
+#include "monitoreddatamapper.h"
+#include "guiutil.h"
+#include "bitcoinunits.h"
+#include "qvaluecombobox.h"
+
+#include <QHBoxLayout>
+#include <QVBoxLayout>
+#include <QPushButton>
+#include <QListWidget>
+#include <QStackedWidget>
+
+#include <QCheckBox>
+#include <QLabel>
+#include <QLineEdit>
+#include <QIntValidator>
+#include <QDoubleValidator>
+#include <QRegExpValidator>
+#include <QDialogButtonBox>
+
+/* First page of options */
+class MainOptionsPage : public QWidget
+{
+public:
+    explicit MainOptionsPage(QWidget *parent=0);
+
+    void setMapper(MonitoredDataMapper *mapper);
+private:
+    QCheckBox *bitcoin_at_startup;
+    QCheckBox *minimize_to_tray;
+    QCheckBox *map_port_upnp;
+    QCheckBox *minimize_on_close;
+    QCheckBox *connect_socks4;
+    QLineEdit *proxy_ip;
+    QLineEdit *proxy_port;
+    BitcoinAmountField *fee_edit;
+
+signals:
+
+public slots:
+
+};
+
+class DisplayOptionsPage : public QWidget
+{
+public:
+    explicit DisplayOptionsPage(QWidget *parent=0);
+
+    void setMapper(MonitoredDataMapper *mapper);
+private:
+    QValueComboBox *unit;
+    QCheckBox *display_addresses;
+signals:
+
+public slots:
+
+};
+
+OptionsDialog::OptionsDialog(QWidget *parent):
+    QDialog(parent), contents_widget(0), pages_widget(0),
+    model(0), main_page(0), display_page(0)
+{
+    contents_widget = new QListWidget();
+    contents_widget->setMaximumWidth(128);
+
+    pages_widget = new QStackedWidget();
+    pages_widget->setMinimumWidth(300);
+
+    QListWidgetItem *item_main = new QListWidgetItem(tr("Main"));
+    contents_widget->addItem(item_main);
+    main_page = new MainOptionsPage(this);
+    pages_widget->addWidget(main_page);
+
+    QListWidgetItem *item_display = new QListWidgetItem(tr("Display"));
+    contents_widget->addItem(item_display);
+    display_page = new DisplayOptionsPage(this);
+    pages_widget->addWidget(display_page);
+
+    contents_widget->setCurrentRow(0);
+
+    QHBoxLayout *main_layout = new QHBoxLayout();
+    main_layout->addWidget(contents_widget);
+    main_layout->addWidget(pages_widget, 1);
+
+    QVBoxLayout *layout = new QVBoxLayout();
+    layout->addLayout(main_layout);
+
+    QDialogButtonBox *buttonbox = new QDialogButtonBox();
+    buttonbox->setStandardButtons(QDialogButtonBox::Apply|QDialogButtonBox::Ok|QDialogButtonBox::Cancel);
+    apply_button = buttonbox->button(QDialogButtonBox::Apply);
+    layout->addWidget(buttonbox);
+
+    setLayout(layout);
+    setWindowTitle(tr("Options"));
+
+    /* Widget-to-option mapper */
+    mapper = new MonitoredDataMapper(this);
+    mapper->setSubmitPolicy(QDataWidgetMapper::ManualSubmit);
+    mapper->setOrientation(Qt::Vertical);
+    /* enable apply button when data modified */
+    connect(mapper, SIGNAL(viewModified()), this, SLOT(enableApply()));
+    /* disable apply button when new data loaded */
+    connect(mapper, SIGNAL(currentIndexChanged(int)), this, SLOT(disableApply()));
+
+    /* Event bindings */
+    connect(contents_widget, SIGNAL(currentRowChanged(int)), this, SLOT(changePage(int)));
+    connect(buttonbox->button(QDialogButtonBox::Ok), SIGNAL(clicked()), this, SLOT(okClicked()));
+    connect(buttonbox->button(QDialogButtonBox::Cancel), SIGNAL(clicked()), this, SLOT(cancelClicked()));
+    connect(buttonbox->button(QDialogButtonBox::Apply), SIGNAL(clicked()), this, SLOT(applyClicked()));
+}
+
+void OptionsDialog::setModel(OptionsModel *model)
+{
+    this->model = model;
+
+    mapper->setModel(model);
+    main_page->setMapper(mapper);
+    display_page->setMapper(mapper);
+
+    mapper->toFirst();
+}
+
+void OptionsDialog::changePage(int index)
+{
+    pages_widget->setCurrentIndex(index);
+}
+
+void OptionsDialog::okClicked()
+{
+    mapper->submit();
+    accept();
+}
+
+void OptionsDialog::cancelClicked()
+{
+    reject();
+}
+
+void OptionsDialog::applyClicked()
+{
+    mapper->submit();
+    apply_button->setEnabled(false);
+}
+
+void OptionsDialog::enableApply()
+{
+    apply_button->setEnabled(true);
+}
+
+void OptionsDialog::disableApply()
+{
+    apply_button->setEnabled(false);
+}
+
+MainOptionsPage::MainOptionsPage(QWidget *parent):
+        QWidget(parent)
+{
+    QVBoxLayout *layout = new QVBoxLayout();
+
+    bitcoin_at_startup = new QCheckBox(tr("&Start Bitcoin on window system startup"));
+    bitcoin_at_startup->setToolTip(tr("Automatically start Bitcoin after the computer is turned on"));
+    layout->addWidget(bitcoin_at_startup);
+
+    minimize_to_tray = new QCheckBox(tr("&Minimize to the tray instead of the taskbar"));
+    minimize_to_tray->setToolTip(tr("Show only a tray icon after minimizing the window"));
+    layout->addWidget(minimize_to_tray);
+
+    map_port_upnp = new QCheckBox(tr("Map port using &UPnP"));
+    map_port_upnp->setToolTip(tr("Automatically open the Bitcoin client port on the router. This only works when your router supports UPnP and it is enabled."));
+    layout->addWidget(map_port_upnp);
+
+    minimize_on_close = new QCheckBox(tr("M&inimize on close"));
+    minimize_on_close->setToolTip(tr("Minimize instead of exit the application when the window is closed. When this option is enabled, the application will be closed only after selecting Quit in the menu."));
+    layout->addWidget(minimize_on_close);
+
+    connect_socks4 = new QCheckBox(tr("&Connect through SOCKS4 proxy:"));
+    connect_socks4->setToolTip(tr("Connect to the Bitcon network through a SOCKS4 proxy (e.g. when connecting through Tor)"));
+    layout->addWidget(connect_socks4);
+
+    QHBoxLayout *proxy_hbox = new QHBoxLayout();
+    proxy_hbox->addSpacing(18);
+    QLabel *proxy_ip_label = new QLabel(tr("Proxy &IP: "));
+    proxy_hbox->addWidget(proxy_ip_label);
+    proxy_ip = new QLineEdit();
+    proxy_ip->setMaximumWidth(140);
+    proxy_ip->setEnabled(false);
+    proxy_ip->setValidator(new QRegExpValidator(QRegExp("[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}"), this));
+    proxy_ip->setToolTip(tr("IP address of the proxy (e.g. 127.0.0.1)"));
+    proxy_ip_label->setBuddy(proxy_ip);
+    proxy_hbox->addWidget(proxy_ip);
+    QLabel *proxy_port_label = new QLabel(tr("&Port: "));
+    proxy_hbox->addWidget(proxy_port_label);
+    proxy_port = new QLineEdit();
+    proxy_port->setMaximumWidth(55);
+    proxy_port->setValidator(new QIntValidator(0, 65535, this));
+    proxy_port->setEnabled(false);
+    proxy_port->setToolTip(tr("Port of the proxy (e.g. 1234)"));
+    proxy_port_label->setBuddy(proxy_port);
+    proxy_hbox->addWidget(proxy_port);
+    proxy_hbox->addStretch(1);
+
+    layout->addLayout(proxy_hbox);
+    QLabel *fee_help = new QLabel(tr("Optional transaction fee per KB that helps make sure your transactions are processed quickly.  Most transactions are 1KB.  Fee 0.01 recommended."));
+    fee_help->setWordWrap(true);
+    layout->addWidget(fee_help);
+
+    QHBoxLayout *fee_hbox = new QHBoxLayout();
+    fee_hbox->addSpacing(18);
+    QLabel *fee_label = new QLabel(tr("Pay transaction &fee"));
+    fee_hbox->addWidget(fee_label);
+    fee_edit = new BitcoinAmountField();
+    fee_edit->setToolTip(tr("Optional transaction fee per KB that helps make sure your transactions are processed quickly. Most transactions are 1KB. Fee 0.01 recommended."));
+
+    fee_label->setBuddy(fee_edit);
+    fee_hbox->addWidget(fee_edit);
+    fee_hbox->addStretch(1);
+
+    layout->addLayout(fee_hbox);
+
+    layout->addStretch(1); // Extra space at bottom
+
+    setLayout(layout);
+
+    connect(connect_socks4, SIGNAL(toggled(bool)), proxy_ip, SLOT(setEnabled(bool)));
+    connect(connect_socks4, SIGNAL(toggled(bool)), proxy_port, SLOT(setEnabled(bool)));
+
+#ifndef USE_UPNP
+    map_port_upnp->setDisabled(true);
+#endif
+}
+
+void MainOptionsPage::setMapper(MonitoredDataMapper *mapper)
+{
+    // Map model to widgets
+    mapper->addMapping(bitcoin_at_startup, OptionsModel::StartAtStartup);
+    mapper->addMapping(minimize_to_tray, OptionsModel::MinimizeToTray);
+    mapper->addMapping(map_port_upnp, OptionsModel::MapPortUPnP);
+    mapper->addMapping(minimize_on_close, OptionsModel::MinimizeOnClose);
+    mapper->addMapping(connect_socks4, OptionsModel::ConnectSOCKS4);
+    mapper->addMapping(proxy_ip, OptionsModel::ProxyIP);
+    mapper->addMapping(proxy_port, OptionsModel::ProxyPort);
+    mapper->addMapping(fee_edit, OptionsModel::Fee);
+}
+
+DisplayOptionsPage::DisplayOptionsPage(QWidget *parent):
+        QWidget(parent)
+{
+    QVBoxLayout *layout = new QVBoxLayout();
+
+    QHBoxLayout *unit_hbox = new QHBoxLayout();
+    unit_hbox->addSpacing(18);
+    QLabel *unit_label = new QLabel(tr("&Unit to show amounts in: "));
+    unit_hbox->addWidget(unit_label);
+    unit = new QValueComboBox(this);
+    unit->setModel(new BitcoinUnits(this));
+    unit->setToolTip(tr("Choose the default subdivision unit to show in the interface, and when sending coins"));
+
+    unit_label->setBuddy(unit);
+    unit_hbox->addWidget(unit);
+
+    layout->addLayout(unit_hbox);
+
+    display_addresses = new QCheckBox(tr("Display addresses in transaction list"), this);
+    layout->addWidget(display_addresses);
+
+    layout->addStretch();
+
+    setLayout(layout);
+}
+
+void DisplayOptionsPage::setMapper(MonitoredDataMapper *mapper)
+{
+    mapper->addMapping(unit, OptionsModel::DisplayUnit);
+    mapper->addMapping(display_addresses, OptionsModel::DisplayAddresses);
+}
diff --git a/src/qt/optionsdialog.h b/src/qt/optionsdialog.h
new file mode 100644 (file)
index 0000000..d5238a3
--- /dev/null
@@ -0,0 +1,50 @@
+#ifndef OPTIONSDIALOG_H
+#define OPTIONSDIALOG_H
+
+#include <QDialog>
+
+QT_BEGIN_NAMESPACE
+class QStackedWidget;
+class QListWidget;
+class QListWidgetItem;
+class QPushButton;
+QT_END_NAMESPACE
+class OptionsModel;
+class MainOptionsPage;
+class DisplayOptionsPage;
+class MonitoredDataMapper;
+
+class OptionsDialog : public QDialog
+{
+    Q_OBJECT
+public:
+    explicit OptionsDialog(QWidget *parent=0);
+
+    void setModel(OptionsModel *model);
+
+signals:
+
+public slots:
+    void changePage(int index);
+
+private slots:
+    void okClicked();
+    void cancelClicked();
+    void applyClicked();
+    void enableApply();
+    void disableApply();
+private:
+    QListWidget *contents_widget;
+    QStackedWidget *pages_widget;
+    OptionsModel *model;
+    MonitoredDataMapper *mapper;
+    QPushButton *apply_button;
+
+    // Pages
+    MainOptionsPage *main_page;
+    DisplayOptionsPage *display_page;
+
+    void setupMainPage();
+};
+
+#endif // OPTIONSDIALOG_H
diff --git a/src/qt/optionsmodel.cpp b/src/qt/optionsmodel.cpp
new file mode 100644 (file)
index 0000000..efc216d
--- /dev/null
@@ -0,0 +1,162 @@
+#include "optionsmodel.h"
+#include "bitcoinunits.h"
+
+#include "headers.h"
+
+OptionsModel::OptionsModel(CWallet *wallet, QObject *parent) :
+    QAbstractListModel(parent),
+    wallet(wallet),
+    nDisplayUnit(BitcoinUnits::BTC),
+    bDisplayAddresses(false)
+{
+    // Read our specific settings from the wallet db
+    CWalletDB walletdb(wallet->strWalletFile);
+    walletdb.ReadSetting("nDisplayUnit", nDisplayUnit);
+    walletdb.ReadSetting("bDisplayAddresses", bDisplayAddresses);
+}
+
+int OptionsModel::rowCount(const QModelIndex & parent) const
+{
+    return OptionIDRowCount;
+}
+
+QVariant OptionsModel::data(const QModelIndex & index, int role) const
+{
+    if(role == Qt::EditRole)
+    {
+        switch(index.row())
+        {
+        case StartAtStartup:
+            return QVariant();
+        case MinimizeToTray:
+            return QVariant(fMinimizeToTray);
+        case MapPortUPnP:
+            return QVariant(fUseUPnP);
+        case MinimizeOnClose:
+            return QVariant(fMinimizeOnClose);
+        case ConnectSOCKS4:
+            return QVariant(fUseProxy);
+        case ProxyIP:
+            return QVariant(QString::fromStdString(addrProxy.ToStringIP()));
+        case ProxyPort:
+            return QVariant(QString::fromStdString(addrProxy.ToStringPort()));
+        case Fee:
+            return QVariant(nTransactionFee);
+        case DisplayUnit:
+            return QVariant(nDisplayUnit);
+        case DisplayAddresses:
+            return QVariant(bDisplayAddresses);
+        default:
+            return QVariant();
+        }
+    }
+    return QVariant();
+}
+
+bool OptionsModel::setData(const QModelIndex & index, const QVariant & value, int role)
+{
+    bool successful = true; /* set to false on parse error */
+    if(role == Qt::EditRole)
+    {
+        CWalletDB walletdb(wallet->strWalletFile);
+        switch(index.row())
+        {
+        case StartAtStartup:
+            successful = false; /*TODO*/
+            break;
+        case MinimizeToTray:
+            fMinimizeToTray = value.toBool();
+            walletdb.WriteSetting("fMinimizeToTray", fMinimizeToTray);
+            break;
+        case MapPortUPnP:
+            fUseUPnP = value.toBool();
+            walletdb.WriteSetting("fUseUPnP", fUseUPnP);
+#ifdef USE_UPNP
+            MapPort(fUseUPnP);
+#endif
+            break;
+        case MinimizeOnClose:
+            fMinimizeOnClose = value.toBool();
+            walletdb.WriteSetting("fMinimizeOnClose", fMinimizeOnClose);
+            break;
+        case ConnectSOCKS4:
+            fUseProxy = value.toBool();
+            walletdb.WriteSetting("fUseProxy", fUseProxy);
+            break;
+        case ProxyIP:
+            {
+                // Use CAddress to parse and check IP
+                CAddress addr(value.toString().toStdString() + ":1");
+                if (addr.ip != INADDR_NONE)
+                {
+                    addrProxy.ip = addr.ip;
+                    walletdb.WriteSetting("addrProxy", addrProxy);
+                }
+                else
+                {
+                    successful = false;
+                }
+            }
+            break;
+        case ProxyPort:
+            {
+                int nPort = atoi(value.toString().toAscii().data());
+                if (nPort > 0 && nPort < USHRT_MAX)
+                {
+                    addrProxy.port = htons(nPort);
+                    walletdb.WriteSetting("addrProxy", addrProxy);
+                }
+                else
+                {
+                    successful = false;
+                }
+            }
+            break;
+        case Fee: {
+            nTransactionFee = value.toLongLong();
+            walletdb.WriteSetting("nTransactionFee", nTransactionFee);
+            }
+            break;
+        case DisplayUnit: {
+            int unit = value.toInt();
+            nDisplayUnit = unit;
+            walletdb.WriteSetting("nDisplayUnit", nDisplayUnit);
+            emit displayUnitChanged(unit);
+            }
+        case DisplayAddresses: {
+            bDisplayAddresses = value.toBool();
+            walletdb.WriteSetting("bDisplayAddresses", bDisplayAddresses);
+            }
+        default:
+            break;
+        }
+    }
+    emit dataChanged(index, index);
+
+    return successful;
+}
+
+qint64 OptionsModel::getTransactionFee()
+{
+    return nTransactionFee;
+}
+
+bool OptionsModel::getMinimizeToTray()
+{
+    return fMinimizeToTray;
+}
+
+bool OptionsModel::getMinimizeOnClose()
+{
+    return fMinimizeOnClose;
+}
+
+int OptionsModel::getDisplayUnit()
+{
+    return nDisplayUnit;
+}
+
+bool OptionsModel::getDisplayAddresses()
+{
+    return bDisplayAddresses;
+}
diff --git a/src/qt/optionsmodel.h b/src/qt/optionsmodel.h
new file mode 100644 (file)
index 0000000..7f489c5
--- /dev/null
@@ -0,0 +1,56 @@
+#ifndef OPTIONSMODEL_H
+#define OPTIONSMODEL_H
+
+#include <QAbstractListModel>
+
+class CWallet;
+
+/* Interface from QT to configuration data structure for bitcoin client.
+   To QT, the options are presented as a list with the different options
+   laid out vertically.
+   This can be changed to a tree once the settings become sufficiently
+   complex.
+ */
+class OptionsModel : public QAbstractListModel
+{
+    Q_OBJECT
+public:
+    explicit OptionsModel(CWallet *wallet, QObject *parent = 0);
+
+    enum OptionID {
+        StartAtStartup, // bool
+        MinimizeToTray, // bool
+        MapPortUPnP, // bool
+        MinimizeOnClose, // bool
+        ConnectSOCKS4, // bool
+        ProxyIP, // QString
+        ProxyPort, // QString
+        Fee, // qint64
+        DisplayUnit, // BitcoinUnits::Unit
+        DisplayAddresses, // bool
+        OptionIDRowCount
+    };
+
+    int rowCount(const QModelIndex & parent = QModelIndex()) const;
+    QVariant data(const QModelIndex & index, int role = Qt::DisplayRole) const;
+    bool setData(const QModelIndex & index, const QVariant & value, int role = Qt::EditRole);
+
+    /* Explicit getters */
+    qint64 getTransactionFee();
+    bool getMinimizeToTray();
+    bool getMinimizeOnClose();
+    int getDisplayUnit();
+    bool getDisplayAddresses();
+private:
+    // Wallet stores persistent options
+    CWallet *wallet;
+    int nDisplayUnit;
+    bool bDisplayAddresses;
+signals:
+    void displayUnitChanged(int unit);
+
+public slots:
+
+};
+
+#endif // OPTIONSMODEL_H
diff --git a/src/qt/overviewpage.cpp b/src/qt/overviewpage.cpp
new file mode 100644 (file)
index 0000000..7bade9a
--- /dev/null
@@ -0,0 +1,173 @@
+#include "overviewpage.h"
+#include "ui_overviewpage.h"
+
+#include "walletmodel.h"
+#include "bitcoinunits.h"
+#include "optionsmodel.h"
+#include "transactiontablemodel.h"
+#include "transactionfilterproxy.h"
+#include "guiutil.h"
+#include "guiconstants.h"
+
+#include <QAbstractItemDelegate>
+#include <QPainter>
+
+#define DECORATION_SIZE 64
+#define NUM_ITEMS 3
+
+class TxViewDelegate : public QAbstractItemDelegate
+{
+    //Q_OBJECT
+public:
+    TxViewDelegate(): QAbstractItemDelegate(), unit(BitcoinUnits::BTC)
+    {
+
+    }
+
+    inline void paint(QPainter *painter, const QStyleOptionViewItem &option,
+                      const QModelIndex &index ) const
+    {
+        painter->save();
+
+        QIcon icon = qvariant_cast<QIcon>(index.data(Qt::DecorationRole));
+        QRect mainRect = option.rect;
+        QRect decorationRect(mainRect.topLeft(), QSize(DECORATION_SIZE, DECORATION_SIZE));
+        int xspace = DECORATION_SIZE + 8;
+        int ypad = 6;
+        int halfheight = (mainRect.height() - 2*ypad)/2;
+        QRect amountRect(mainRect.left() + xspace, mainRect.top()+ypad, mainRect.width() - xspace, halfheight);
+        QRect addressRect(mainRect.left() + xspace, mainRect.top()+ypad+halfheight, mainRect.width() - xspace, halfheight);
+        icon.paint(painter, decorationRect);
+
+        QDateTime date = index.data(TransactionTableModel::DateRole).toDateTime();
+        QString address = index.data(Qt::DisplayRole).toString();
+        qint64 amount = index.data(TransactionTableModel::AmountRole).toLongLong();
+        bool confirmed = index.data(TransactionTableModel::ConfirmedRole).toBool();
+        QVariant value = index.data(Qt::ForegroundRole);
+        QColor foreground = option.palette.color(QPalette::Text);
+        if(qVariantCanConvert<QColor>(value))
+        {
+            foreground = qvariant_cast<QColor>(value);
+        }
+
+        painter->setPen(foreground);
+        painter->drawText(addressRect, Qt::AlignLeft|Qt::AlignVCenter, address);
+
+        if(amount < 0)
+        {
+            foreground = COLOR_NEGATIVE;
+        }
+        else if(!confirmed)
+        {
+            foreground = COLOR_UNCONFIRMED;
+        }
+        else
+        {
+            foreground = option.palette.color(QPalette::Text);
+        }
+        painter->setPen(foreground);
+        QString amountText = BitcoinUnits::formatWithUnit(unit, amount, true);
+        if(!confirmed)
+        {
+            amountText = QString("[") + amountText + QString("]");
+        }
+        painter->drawText(amountRect, Qt::AlignRight|Qt::AlignVCenter, amountText);
+
+        painter->setPen(option.palette.color(QPalette::Text));
+        painter->drawText(amountRect, Qt::AlignLeft|Qt::AlignVCenter, GUIUtil::dateTimeStr(date));
+
+        painter->restore();
+    }
+
+    inline QSize sizeHint(const QStyleOptionViewItem &option, const QModelIndex &index) const
+    {
+        return QSize(DECORATION_SIZE, DECORATION_SIZE);
+    }
+
+    int unit;
+
+};
+
+OverviewPage::OverviewPage(QWidget *parent) :
+    QWidget(parent),
+    ui(new Ui::OverviewPage),
+    currentBalance(-1),
+    currentUnconfirmedBalance(-1),
+    txdelegate(new TxViewDelegate())
+{
+    ui->setupUi(this);
+
+    // Balance: <balance>
+    ui->labelBalance->setFont(QFont("Monospace", -1, QFont::Bold));
+    ui->labelBalance->setToolTip(tr("Your current balance"));
+    ui->labelBalance->setTextInteractionFlags(Qt::TextSelectableByMouse|Qt::TextSelectableByKeyboard);
+
+    // Unconfirmed balance: <balance>
+    ui->labelUnconfirmed->setFont(QFont("Monospace", -1, QFont::Bold));
+    ui->labelUnconfirmed->setToolTip(tr("Total of transactions that have yet to be confirmed, and do not yet count toward the current balance"));
+    ui->labelUnconfirmed->setTextInteractionFlags(Qt::TextSelectableByMouse|Qt::TextSelectableByKeyboard);
+
+    ui->labelNumTransactions->setToolTip(tr("Total number of transactions in wallet"));
+
+    // Recent transactions
+    ui->listTransactions->setStyleSheet("background:transparent");
+    ui->listTransactions->setItemDelegate(txdelegate);
+    ui->listTransactions->setIconSize(QSize(DECORATION_SIZE, DECORATION_SIZE));
+    ui->listTransactions->setSelectionMode(QAbstractItemView::NoSelection);
+    ui->listTransactions->setMinimumHeight(NUM_ITEMS * (DECORATION_SIZE + 2));
+
+    connect(ui->listTransactions, SIGNAL(clicked(QModelIndex)), this, SIGNAL(transactionClicked(QModelIndex)));
+}
+
+OverviewPage::~OverviewPage()
+{
+    delete ui;
+}
+
+void OverviewPage::setBalance(qint64 balance, qint64 unconfirmedBalance)
+{
+    int unit = model->getOptionsModel()->getDisplayUnit();
+    currentBalance = balance;
+    currentUnconfirmedBalance = unconfirmedBalance;
+    ui->labelBalance->setText(BitcoinUnits::formatWithUnit(unit, balance));
+    ui->labelUnconfirmed->setText(BitcoinUnits::formatWithUnit(unit, unconfirmedBalance));
+}
+
+void OverviewPage::setNumTransactions(int count)
+{
+    ui->labelNumTransactions->setText(QLocale::system().toString(count));
+}
+
+void OverviewPage::setModel(WalletModel *model)
+{
+    this->model = model;
+
+    // Set up transaction list
+    TransactionFilterProxy *filter = new TransactionFilterProxy();
+    filter->setSourceModel(model->getTransactionTableModel());
+    filter->setLimit(NUM_ITEMS);
+    filter->setDynamicSortFilter(true);
+    filter->setSortRole(Qt::EditRole);
+    filter->sort(TransactionTableModel::Status, Qt::DescendingOrder);
+
+    ui->listTransactions->setModel(filter);
+    ui->listTransactions->setModelColumn(TransactionTableModel::ToAddress);
+
+    // Keep up to date with wallet
+    setBalance(model->getBalance(), model->getUnconfirmedBalance());
+    connect(model, SIGNAL(balanceChanged(qint64, qint64)), this, SLOT(setBalance(qint64, qint64)));
+
+    setNumTransactions(model->getNumTransactions());
+    connect(model, SIGNAL(numTransactionsChanged(int)), this, SLOT(setNumTransactions(int)));
+
+    connect(model->getOptionsModel(), SIGNAL(displayUnitChanged(int)), this, SLOT(displayUnitChanged()));
+}
+
+void OverviewPage::displayUnitChanged()
+{
+    if(currentBalance != -1)
+        setBalance(currentBalance, currentUnconfirmedBalance);
+
+    txdelegate->unit = model->getOptionsModel()->getDisplayUnit();
+    ui->listTransactions->update();
+}
diff --git a/src/qt/overviewpage.h b/src/qt/overviewpage.h
new file mode 100644 (file)
index 0000000..4b4cc92
--- /dev/null
@@ -0,0 +1,45 @@
+#ifndef OVERVIEWPAGE_H
+#define OVERVIEWPAGE_H
+
+#include <QWidget>
+
+QT_BEGIN_NAMESPACE
+class QModelIndex;
+QT_END_NAMESPACE
+
+namespace Ui {
+    class OverviewPage;
+}
+class WalletModel;
+class TxViewDelegate;
+
+class OverviewPage : public QWidget
+{
+    Q_OBJECT
+
+public:
+    explicit OverviewPage(QWidget *parent = 0);
+    ~OverviewPage();
+
+    void setModel(WalletModel *model);
+
+public slots:
+    void setBalance(qint64 balance, qint64 unconfirmedBalance);
+    void setNumTransactions(int count);
+
+signals:
+    void transactionClicked(const QModelIndex &index);
+
+private:
+    Ui::OverviewPage *ui;
+    WalletModel *model;
+    qint64 currentBalance;
+    qint64 currentUnconfirmedBalance;
+
+    TxViewDelegate *txdelegate;
+
+private slots:
+    void displayUnitChanged();
+};
+
+#endif // OVERVIEWPAGE_H
diff --git a/src/qt/qvalidatedlineedit.cpp b/src/qt/qvalidatedlineedit.cpp
new file mode 100644 (file)
index 0000000..8ca230c
--- /dev/null
@@ -0,0 +1,45 @@
+#include "qvalidatedlineedit.h"
+
+#include "guiconstants.h"
+
+QValidatedLineEdit::QValidatedLineEdit(QWidget *parent) :
+    QLineEdit(parent), valid(true)
+{
+    connect(this, SIGNAL(textChanged(QString)), this, SLOT(markValid()));
+}
+
+void QValidatedLineEdit::setValid(bool valid)
+{
+    if(valid == this->valid)
+    {
+        return;
+    }
+
+    if(valid)
+    {
+        setStyleSheet("");
+    }
+    else
+    {
+        setStyleSheet(STYLE_INVALID);
+    }
+    this->valid = valid;
+}
+
+void QValidatedLineEdit::focusInEvent(QFocusEvent *evt)
+{
+    // Clear invalid flag on focus
+    setValid(true);
+    QLineEdit::focusInEvent(evt);
+}
+
+void QValidatedLineEdit::markValid()
+{
+    setValid(true);
+}
+
+void QValidatedLineEdit::clear()
+{
+    setValid(true);
+    QLineEdit::clear();
+}
diff --git a/src/qt/qvalidatedlineedit.h b/src/qt/qvalidatedlineedit.h
new file mode 100644 (file)
index 0000000..f7b9486
--- /dev/null
@@ -0,0 +1,28 @@
+#ifndef QVALIDATEDLINEEDIT_H
+#define QVALIDATEDLINEEDIT_H
+
+#include <QLineEdit>
+
+// Line edit that can be marked as "invalid". When marked as invalid,
+// it will get a red background until it is focused.
+class QValidatedLineEdit : public QLineEdit
+{
+    Q_OBJECT
+public:
+    explicit QValidatedLineEdit(QWidget *parent = 0);
+    void clear();
+
+protected:
+    void focusInEvent(QFocusEvent *evt);
+
+private:
+    bool valid;
+
+public slots:
+    void setValid(bool valid);
+
+private slots:
+    void markValid();
+};
+
+#endif // QVALIDATEDLINEEDIT_H
diff --git a/src/qt/qvaluecombobox.cpp b/src/qt/qvaluecombobox.cpp
new file mode 100644 (file)
index 0000000..c0ad8c1
--- /dev/null
@@ -0,0 +1,27 @@
+#include "qvaluecombobox.h"
+
+QValueComboBox::QValueComboBox(QWidget *parent) :
+        QComboBox(parent), role(Qt::UserRole)
+{
+    connect(this, SIGNAL(currentIndexChanged(int)), this, SLOT(handleSelectionChanged(int)));
+}
+
+int QValueComboBox::value() const
+{
+    return itemData(currentIndex(), role).toInt();
+}
+
+void QValueComboBox::setValue(int value)
+{
+    setCurrentIndex(findData(value, role));
+}
+
+void QValueComboBox::setRole(int role)
+{
+    this->role = role;
+}
+
+void QValueComboBox::handleSelectionChanged(int idx)
+{
+    emit valueChanged();
+}
diff --git a/src/qt/qvaluecombobox.h b/src/qt/qvaluecombobox.h
new file mode 100644 (file)
index 0000000..2a3533d
--- /dev/null
@@ -0,0 +1,33 @@
+#ifndef QVALUECOMBOBOX_H
+#define QVALUECOMBOBOX_H
+
+#include <QComboBox>
+
+// QComboBox that can be used with QDataWidgetMapper to select
+// ordinal values from a model.
+class QValueComboBox : public QComboBox
+{
+    Q_OBJECT
+    Q_PROPERTY(int value READ value WRITE setValue NOTIFY valueChanged USER true);
+public:
+    explicit QValueComboBox(QWidget *parent = 0);
+
+    int value() const;
+    void setValue(int value);
+
+    // Model role to use as value
+    void setRole(int role);
+
+signals:
+    void valueChanged();
+
+public slots:
+
+private:
+    int role;
+
+private slots:
+    void handleSelectionChanged(int idx);
+};
+
+#endif // QVALUECOMBOBOX_H
diff --git a/src/qt/res/bitcoin-qt.rc b/src/qt/res/bitcoin-qt.rc
new file mode 100644 (file)
index 0000000..1a1ab53
--- /dev/null
@@ -0,0 +1 @@
+IDI_ICON1 ICON DISCARDABLE "icons/bitcoin.ico"
diff --git a/src/qt/res/icons/add.png b/src/qt/res/icons/add.png
new file mode 100644 (file)
index 0000000..f98e2a8
Binary files /dev/null and b/src/qt/res/icons/add.png differ
diff --git a/src/qt/res/icons/address-book.png b/src/qt/res/icons/address-book.png
new file mode 100644 (file)
index 0000000..1086fbe
Binary files /dev/null and b/src/qt/res/icons/address-book.png differ
diff --git a/src/qt/res/icons/bitcoin.icns b/src/qt/res/icons/bitcoin.icns
new file mode 100644 (file)
index 0000000..3c75708
Binary files /dev/null and b/src/qt/res/icons/bitcoin.icns differ
diff --git a/src/qt/res/icons/bitcoin.ico b/src/qt/res/icons/bitcoin.ico
new file mode 100644 (file)
index 0000000..01afd3c
Binary files /dev/null and b/src/qt/res/icons/bitcoin.ico differ
diff --git a/src/qt/res/icons/bitcoin.png b/src/qt/res/icons/bitcoin.png
new file mode 100644 (file)
index 0000000..bf43144
Binary files /dev/null and b/src/qt/res/icons/bitcoin.png differ
diff --git a/src/qt/res/icons/bitcoin_testnet.png b/src/qt/res/icons/bitcoin_testnet.png
new file mode 100644 (file)
index 0000000..ee2dc40
Binary files /dev/null and b/src/qt/res/icons/bitcoin_testnet.png differ
diff --git a/src/qt/res/icons/clock1.png b/src/qt/res/icons/clock1.png
new file mode 100644 (file)
index 0000000..448e47f
Binary files /dev/null and b/src/qt/res/icons/clock1.png differ
diff --git a/src/qt/res/icons/clock2.png b/src/qt/res/icons/clock2.png
new file mode 100644 (file)
index 0000000..c1a6e99
Binary files /dev/null and b/src/qt/res/icons/clock2.png differ
diff --git a/src/qt/res/icons/clock3.png b/src/qt/res/icons/clock3.png
new file mode 100644 (file)
index 0000000..e429a40
Binary files /dev/null and b/src/qt/res/icons/clock3.png differ
diff --git a/src/qt/res/icons/clock4.png b/src/qt/res/icons/clock4.png
new file mode 100644 (file)
index 0000000..ba036f4
Binary files /dev/null and b/src/qt/res/icons/clock4.png differ
diff --git a/src/qt/res/icons/clock5.png b/src/qt/res/icons/clock5.png
new file mode 100644 (file)
index 0000000..411d7a7
Binary files /dev/null and b/src/qt/res/icons/clock5.png differ
diff --git a/src/qt/res/icons/configure.png b/src/qt/res/icons/configure.png
new file mode 100644 (file)
index 0000000..95bd319
Binary files /dev/null and b/src/qt/res/icons/configure.png differ
diff --git a/src/qt/res/icons/connect0_16.png b/src/qt/res/icons/connect0_16.png
new file mode 100644 (file)
index 0000000..66f3ae4
Binary files /dev/null and b/src/qt/res/icons/connect0_16.png differ
diff --git a/src/qt/res/icons/connect1_16.png b/src/qt/res/icons/connect1_16.png
new file mode 100644 (file)
index 0000000..76000be
Binary files /dev/null and b/src/qt/res/icons/connect1_16.png differ
diff --git a/src/qt/res/icons/connect2_16.png b/src/qt/res/icons/connect2_16.png
new file mode 100644 (file)
index 0000000..6d9a372
Binary files /dev/null and b/src/qt/res/icons/connect2_16.png differ
diff --git a/src/qt/res/icons/connect3_16.png b/src/qt/res/icons/connect3_16.png
new file mode 100644 (file)
index 0000000..a211700
Binary files /dev/null and b/src/qt/res/icons/connect3_16.png differ
diff --git a/src/qt/res/icons/connect4_16.png b/src/qt/res/icons/connect4_16.png
new file mode 100644 (file)
index 0000000..e2fe97d
Binary files /dev/null and b/src/qt/res/icons/connect4_16.png differ
diff --git a/src/qt/res/icons/edit.png b/src/qt/res/icons/edit.png
new file mode 100644 (file)
index 0000000..1d69145
Binary files /dev/null and b/src/qt/res/icons/edit.png differ
diff --git a/src/qt/res/icons/editcopy.png b/src/qt/res/icons/editcopy.png
new file mode 100644 (file)
index 0000000..f882aa2
Binary files /dev/null and b/src/qt/res/icons/editcopy.png differ
diff --git a/src/qt/res/icons/editpaste.png b/src/qt/res/icons/editpaste.png
new file mode 100644 (file)
index 0000000..a192060
Binary files /dev/null and b/src/qt/res/icons/editpaste.png differ
diff --git a/src/qt/res/icons/export.png b/src/qt/res/icons/export.png
new file mode 100644 (file)
index 0000000..69d59a3
Binary files /dev/null and b/src/qt/res/icons/export.png differ
diff --git a/src/qt/res/icons/history.png b/src/qt/res/icons/history.png
new file mode 100644 (file)
index 0000000..60f1351
Binary files /dev/null and b/src/qt/res/icons/history.png differ
diff --git a/src/qt/res/icons/key.png b/src/qt/res/icons/key.png
new file mode 100644 (file)
index 0000000..757cad4
Binary files /dev/null and b/src/qt/res/icons/key.png differ
diff --git a/src/qt/res/icons/lock_closed.png b/src/qt/res/icons/lock_closed.png
new file mode 100644 (file)
index 0000000..ce8da0b
Binary files /dev/null and b/src/qt/res/icons/lock_closed.png differ
diff --git a/src/qt/res/icons/lock_open.png b/src/qt/res/icons/lock_open.png
new file mode 100644 (file)
index 0000000..6a3a8ed
Binary files /dev/null and b/src/qt/res/icons/lock_open.png differ
diff --git a/src/qt/res/icons/notsynced.png b/src/qt/res/icons/notsynced.png
new file mode 100644 (file)
index 0000000..c9e7118
Binary files /dev/null and b/src/qt/res/icons/notsynced.png differ
diff --git a/src/qt/res/icons/overview.png b/src/qt/res/icons/overview.png
new file mode 100644 (file)
index 0000000..6b94b43
Binary files /dev/null and b/src/qt/res/icons/overview.png differ
diff --git a/src/qt/res/icons/quit.png b/src/qt/res/icons/quit.png
new file mode 100644 (file)
index 0000000..0dde6f3
Binary files /dev/null and b/src/qt/res/icons/quit.png differ
diff --git a/src/qt/res/icons/receive.png b/src/qt/res/icons/receive.png
new file mode 100644 (file)
index 0000000..e8f418a
Binary files /dev/null and b/src/qt/res/icons/receive.png differ
diff --git a/src/qt/res/icons/remove.png b/src/qt/res/icons/remove.png
new file mode 100644 (file)
index 0000000..a44b6d1
Binary files /dev/null and b/src/qt/res/icons/remove.png differ
diff --git a/src/qt/res/icons/send.png b/src/qt/res/icons/send.png
new file mode 100644 (file)
index 0000000..55ce550
Binary files /dev/null and b/src/qt/res/icons/send.png differ
diff --git a/src/qt/res/icons/synced.png b/src/qt/res/icons/synced.png
new file mode 100644 (file)
index 0000000..8e428b6
Binary files /dev/null and b/src/qt/res/icons/synced.png differ
diff --git a/src/qt/res/icons/toolbar.png b/src/qt/res/icons/toolbar.png
new file mode 100644 (file)
index 0000000..84c18e2
Binary files /dev/null and b/src/qt/res/icons/toolbar.png differ
diff --git a/src/qt/res/icons/toolbar_testnet.png b/src/qt/res/icons/toolbar_testnet.png
new file mode 100644 (file)
index 0000000..90ed6d9
Binary files /dev/null and b/src/qt/res/icons/toolbar_testnet.png differ
diff --git a/src/qt/res/icons/transaction0.png b/src/qt/res/icons/transaction0.png
new file mode 100644 (file)
index 0000000..4578666
Binary files /dev/null and b/src/qt/res/icons/transaction0.png differ
diff --git a/src/qt/res/icons/transaction2.png b/src/qt/res/icons/transaction2.png
new file mode 100644 (file)
index 0000000..01bb558
Binary files /dev/null and b/src/qt/res/icons/transaction2.png differ
diff --git a/src/qt/res/icons/tx_inout.png b/src/qt/res/icons/tx_inout.png
new file mode 100644 (file)
index 0000000..5f092f9
Binary files /dev/null and b/src/qt/res/icons/tx_inout.png differ
diff --git a/src/qt/res/icons/tx_input.png b/src/qt/res/icons/tx_input.png
new file mode 100644 (file)
index 0000000..0f5fea3
Binary files /dev/null and b/src/qt/res/icons/tx_input.png differ
diff --git a/src/qt/res/icons/tx_mined.png b/src/qt/res/icons/tx_mined.png
new file mode 100644 (file)
index 0000000..613f30f
Binary files /dev/null and b/src/qt/res/icons/tx_mined.png differ
diff --git a/src/qt/res/icons/tx_output.png b/src/qt/res/icons/tx_output.png
new file mode 100644 (file)
index 0000000..9ae39fb
Binary files /dev/null and b/src/qt/res/icons/tx_output.png differ
diff --git a/src/qt/res/images/about.png b/src/qt/res/images/about.png
new file mode 100644 (file)
index 0000000..c9ab951
Binary files /dev/null and b/src/qt/res/images/about.png differ
diff --git a/src/qt/res/images/splash2.jpg b/src/qt/res/images/splash2.jpg
new file mode 100644 (file)
index 0000000..3846e6f
Binary files /dev/null and b/src/qt/res/images/splash2.jpg differ
diff --git a/src/qt/res/movies/update_spinner.mng b/src/qt/res/movies/update_spinner.mng
new file mode 100644 (file)
index 0000000..7df3baa
Binary files /dev/null and b/src/qt/res/movies/update_spinner.mng differ
diff --git a/src/qt/res/src/bitcoin.svg b/src/qt/res/src/bitcoin.svg
new file mode 100644 (file)
index 0000000..96f1017
--- /dev/null
@@ -0,0 +1,115 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:xlink="http://www.w3.org/1999/xlink"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   id="svg2"
+   version="1.1"
+   inkscape:version="0.48.0 r9654"
+   width="256"
+   height="256"
+   sodipodi:docname="bitcoin.svg"
+   inkscape:export-filename="/store/orion/projects/bitcoin/BC_Logo_icon32.png"
+   inkscape:export-xdpi="11.25"
+   inkscape:export-ydpi="11.25"
+   style="display:inline">
+  <metadata
+     id="metadata8">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title></dc:title>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <defs
+     id="defs6">
+    <linearGradient
+       id="linearGradient3800">
+      <stop
+         style="stop-color:#fbba6c;stop-opacity:1;"
+         offset="0"
+         id="stop3802" />
+      <stop
+         style="stop-color:#f89825;stop-opacity:1;"
+         offset="1"
+         id="stop3804" />
+    </linearGradient>
+    <filter
+       inkscape:collect="always"
+       id="filter3788">
+      <feGaussianBlur
+         inkscape:collect="always"
+         stdDeviation="7.7328864"
+         id="feGaussianBlur3790" />
+    </filter>
+    <radialGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3800"
+       id="radialGradient3806"
+       cx="137.01819"
+       cy="136.81316"
+       fx="137.01819"
+       fy="136.81316"
+       r="120.22619"
+       gradientTransform="matrix(1,0,0,0.99768745,0,0.29784356)"
+       gradientUnits="userSpaceOnUse" />
+  </defs>
+  <sodipodi:namedview
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1"
+     objecttolerance="10"
+     gridtolerance="10"
+     guidetolerance="10"
+     inkscape:pageopacity="0"
+     inkscape:pageshadow="2"
+     inkscape:window-width="1204"
+     inkscape:window-height="972"
+     id="namedview4"
+     showgrid="false"
+     inkscape:zoom="1"
+     inkscape:cx="-54.927212"
+     inkscape:cy="128"
+     inkscape:window-x="238"
+     inkscape:window-y="143"
+     inkscape:window-maximized="0"
+     inkscape:current-layer="layer1" />
+  <g
+     inkscape:groupmode="layer"
+     id="layer2"
+     inkscape:label="Shadow"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:nodetypes="sssssssssssscssssscsssscscssssssssssscscsssssssscscssssscssscssssssscsssssssss"
+       inkscape:connector-curvature="0"
+       id="path2986"
+       d="M 111.77934,251.6677 C 67.147549,243.82973 30.788461,211.94464 17.111244,168.64858 7.1011053,136.9609 11.409199,100.0445 28.433065,71.630835 45.23974,43.579693 71.151762,24.409692 103.78036,15.888094 c 12.1652,-3.177178 33.00458,-3.99623 46.6577,-1.833789 45.59908,7.22219 82.56109,39.080427 96.48709,83.164011 10.01013,31.687684 5.70204,68.604084 -11.32183,97.017744 -16.8025,28.04418 -42.64131,47.16473 -75.34729,55.75648 -7.52834,1.97768 -11.60054,2.41566 -24.95273,2.68377 -10.90952,0.21906 -18.34974,-0.0999 -23.52396,-1.00861 z m 20.17619,-31.35425 c 0.63075,-2.39846 2.14458,-8.28561 3.36407,-13.08254 1.56481,-6.15521 2.69488,-8.60563 3.84031,-8.32722 0.89267,0.21696 7.39067,0.68131 14.43998,1.03189 16.31195,0.81124 23.9944,-1.14509 31.43693,-8.00537 7.63877,-7.04117 11.30337,-15.63267 11.82635,-27.72636 0.37592,-8.69327 0.10152,-10.44523 -2.27687,-14.53617 -1.48738,-2.55836 -5.17935,-6.48313 -8.20438,-8.7217 l -5.50006,-4.07013 4.37131,-1.87838 c 9.83682,-4.22697 14.47489,-11.84516 15.1401,-24.86816 0.41587,-8.14174 0.12573,-9.95645 -2.32406,-14.536178 -3.41249,-6.379435 -11.7129,-12.875301 -21.81801,-17.074696 -4.15735,-1.727672 -7.66196,-3.187464 -7.78803,-3.243983 -0.12607,-0.05651 1.28534,-6.088871 3.13645,-13.405229 1.85112,-7.316357 3.26253,-13.372021 3.13645,-13.457031 -0.12607,-0.08501 -2.84573,-0.778731 -6.04368,-1.541604 -3.19796,-0.762872 -6.6666,-1.640092 -7.70811,-1.949379 -1.54868,-0.459905 -2.47321,1.773902 -5.07541,12.262964 -2.215,8.928331 -3.69157,12.825303 -4.85951,12.825303 -2.30435,0 -12.01076,-2.489633 -12.01076,-3.080685 0,-0.263336 1.37739,-5.975631 3.06085,-12.693987 1.68345,-6.718356 2.78086,-12.49516 2.43868,-12.837341 -1.06646,-1.066455 -13.66473,-4.07084 -14.61292,-3.484827 -0.49474,0.305758 -2.13899,5.806491 -3.65393,12.223852 -1.51493,6.417361 -3.0693,12.177423 -3.45416,12.800138 -0.42537,0.68826 -6.84309,-0.416984 -16.36715,-2.818708 -8.617084,-2.173005 -15.989649,-3.583696 -16.383486,-3.13487 -0.393848,0.448826 -1.334199,3.432558 -2.089673,6.630515 -0.755474,3.197957 -1.623352,6.656241 -1.928612,7.685075 -0.438573,1.478093 0.970946,2.194444 6.717302,3.413902 7.407149,1.571906 12.549199,5.114005 12.549199,8.644526 0,3.559986 -18.770806,76.736553 -20.092504,78.329103 -1.007682,1.21419 -2.807318,1.40957 -7.196833,0.78135 -11.551776,-1.65329 -10.897277,-1.95681 -14.648875,6.7937 -1.878049,4.38054 -3.41465,8.32832 -3.41465,8.77286 0,0.44453 6.14881,2.29784 13.664008,4.11848 7.515199,1.82065 14.792647,3.72851 16.172114,4.23971 l 2.508106,0.92945 -3.31877,13.11716 c -1.825323,7.21442 -3.215633,13.21726 -3.089563,13.33965 0.549874,0.53382 15.058297,4.01313 15.382497,3.68892 0.19792,-0.19791 1.74688,-5.83164 3.44215,-12.51942 1.69526,-6.68778 3.30839,-12.52544 3.58472,-12.97256 0.443,-0.71676 11.73522,1.68597 12.76544,2.7162 0.21981,0.21981 -1.08467,6.26629 -2.89884,13.43664 l -3.29849,13.03696 4.8136,1.23571 c 2.6475,0.67965 5.33693,1.42786 5.97652,1.66271 3.63321,1.33406 5.19855,0.40079 6.2902,-3.75024 z m 0.68716,-43.88623 c -0.63959,-0.21166 -5.21848,-1.29512 -10.17531,-2.40768 -4.95684,-1.11255 -9.01243,-2.23295 -9.01243,-2.48975 0,-0.65492 8.11353,-33.1852 8.69895,-34.87745 0.34957,-1.01046 3.32218,-0.62569 10.96233,1.41895 12.84914,3.43866 18.00073,5.54314 23.11146,9.44128 8.35514,6.37277 10.49752,14.36232 5.75489,21.46161 -3.94917,5.91153 -9.15813,8.03413 -19.45529,7.92788 -4.79693,-0.0496 -9.245,-0.26317 -9.8846,-0.47484 z m 2.50991,-54.7082 c -3.73627,-0.93479 -7.21128,-1.958 -7.72221,-2.27376 -0.72057,-0.44534 6.3168,-31.740173 7.3756,-32.798964 0.64276,-0.642776 19.09068,4.708848 22.8588,6.631196 2.34875,1.19824 5.92162,4.059214 7.93975,6.357724 2.94919,3.358944 3.66929,5.201504 3.66929,9.388734 0,4.31035 -0.68714,5.95944 -3.98073,9.55341 -3.93586,4.2948 -4.08991,4.34657 -13.664,4.59252 -5.49512,0.14117 -12.62142,-0.48635 -16.4765,-1.45086 z"
+       style="opacity:0.8176923;fill:#000000;fill-opacity:1;filter:url(#filter3788)" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer1"
+     inkscape:label="Front"
+     style="display:inline">
+    <path
+       style="fill:url(#radialGradient3806);fill-opacity:1;display:inline"
+       d="M 107.77934,247.6677 C 63.147549,239.82973 26.788461,207.94464 13.111244,164.64858 3.1011053,132.9609 7.4091993,96.044496 24.433065,67.630835 41.23974,39.579693 67.151762,20.409692 99.780356,11.888094 111.94556,8.7109163 132.78494,7.8918643 146.43806,10.054305 c 45.59908,7.22219 82.56109,39.080427 96.48709,83.164011 10.01013,31.687684 5.70204,68.604084 -11.32183,97.017744 -16.8025,28.04418 -42.64131,47.16473 -75.34729,55.75648 -7.52834,1.97768 -11.60054,2.41566 -24.95273,2.68377 -10.90952,0.21906 -18.34974,-0.0999 -23.52396,-1.00861 z m 20.17619,-31.35425 c 0.63075,-2.39846 2.14458,-8.28561 3.36407,-13.08254 1.56481,-6.15521 2.69488,-8.60563 3.84031,-8.32722 0.89267,0.21696 7.39067,0.68131 14.43998,1.03189 16.31195,0.81124 23.9944,-1.14509 31.43693,-8.00537 7.63877,-7.04117 11.30337,-15.63267 11.82635,-27.72636 0.37592,-8.69327 0.10152,-10.44523 -2.27687,-14.53617 -1.48738,-2.55836 -5.17935,-6.48313 -8.20438,-8.7217 l -5.50006,-4.07013 4.37131,-1.87838 c 9.83682,-4.22697 14.47489,-11.84516 15.1401,-24.86816 0.41587,-8.141744 0.12573,-9.956454 -2.32406,-14.536178 -3.41249,-6.379435 -11.7129,-12.875301 -21.81801,-17.074696 -4.15735,-1.727672 -7.66196,-3.187464 -7.78803,-3.243983 -0.12607,-0.05651 1.28534,-6.088871 3.13645,-13.405229 1.85112,-7.316357 3.26253,-13.372021 3.13645,-13.457031 -0.12607,-0.08501 -2.84573,-0.778731 -6.04368,-1.541604 -3.19796,-0.762872 -6.6666,-1.640092 -7.70811,-1.949379 -1.54868,-0.459905 -2.47321,1.773902 -5.07541,12.262964 -2.215,8.928331 -3.69157,12.825303 -4.85951,12.825303 -2.30435,0 -12.01076,-2.489633 -12.01076,-3.080685 0,-0.263336 1.37739,-5.975631 3.06085,-12.693987 1.68345,-6.718356 2.78086,-12.49516 2.43868,-12.837341 -1.06646,-1.066455 -13.66473,-4.07084 -14.61292,-3.484827 -0.49474,0.305758 -2.13899,5.806491 -3.65393,12.223852 -1.51493,6.417361 -3.0693,12.177423 -3.45416,12.800138 -0.42537,0.68826 -6.84309,-0.416984 -16.36715,-2.818708 -8.617084,-2.173005 -15.989649,-3.583696 -16.383486,-3.13487 -0.393848,0.448826 -1.334199,3.432558 -2.089673,6.630515 -0.755474,3.197957 -1.623352,6.656241 -1.928612,7.685075 -0.438573,1.478093 0.970946,2.194444 6.717302,3.413902 7.407145,1.571906 12.549199,5.114005 12.549199,8.644526 0,3.559986 -18.770806,76.736553 -20.092504,78.329103 -1.007682,1.21419 -2.807318,1.40957 -7.196833,0.78135 -11.551776,-1.65329 -10.897277,-1.95681 -14.648875,6.7937 -1.878049,4.38054 -3.41465,8.32832 -3.41465,8.77286 0,0.44453 6.14881,2.29784 13.664008,4.11848 7.515199,1.82065 14.792647,3.72851 16.172114,4.23971 l 2.508106,0.92945 -3.31877,13.11716 c -1.825323,7.21442 -3.215633,13.21726 -3.089563,13.33965 0.549874,0.53382 15.058293,4.01313 15.382493,3.68892 0.19792,-0.19791 1.74688,-5.83164 3.442154,-12.51942 1.69526,-6.68778 3.30839,-12.52544 3.58472,-12.97256 0.443,-0.71676 11.73522,1.68597 12.76544,2.7162 0.21981,0.21981 -1.08467,6.26629 -2.89884,13.43664 l -3.29849,13.03696 4.8136,1.23571 c 2.6475,0.67965 5.33693,1.42786 5.97652,1.66271 3.63321,1.33406 5.19855,0.40079 6.2902,-3.75024 z m 0.68716,-43.88623 c -0.63959,-0.21166 -5.21848,-1.29512 -10.17531,-2.40768 -4.95684,-1.11255 -9.01243,-2.23295 -9.01243,-2.48975 0,-0.65492 8.11353,-33.1852 8.69895,-34.87745 0.34957,-1.01046 3.32218,-0.62569 10.96233,1.41895 12.84914,3.43866 18.00073,5.54314 23.11146,9.44128 8.35514,6.37277 10.49752,14.36232 5.75489,21.46161 -3.94917,5.91153 -9.15813,8.03413 -19.45529,7.92788 -4.79693,-0.0496 -9.245,-0.26317 -9.8846,-0.47484 z m 2.50991,-54.7082 c -3.73627,-0.93479 -7.21128,-1.958 -7.72221,-2.27376 -0.72057,-0.44534 6.3168,-31.740173 7.3756,-32.798964 0.64276,-0.642776 19.09068,4.708848 22.8588,6.631196 2.34875,1.19824 5.92162,4.059214 7.93975,6.357724 2.94919,3.35894 3.66929,5.201504 3.66929,9.388734 0,4.31035 -0.68714,5.95944 -3.98073,9.55341 -3.93586,4.2948 -4.08991,4.34657 -13.664,4.59252 -5.49512,0.14117 -12.62142,-0.48635 -16.4765,-1.45086 z"
+       id="path2987"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="sssssssssssscssssscsssscscssssssssssscscsssssssscscssssscssscssssssscsssssssss"
+       inkscape:export-xdpi="11.98"
+       inkscape:export-ydpi="11.98" />
+  </g>
+</svg>
diff --git a/src/qt/res/src/clock1.svg b/src/qt/res/src/clock1.svg
new file mode 100644 (file)
index 0000000..793dc7f
--- /dev/null
@@ -0,0 +1,261 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:xlink="http://www.w3.org/1999/xlink"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="16px"
+   height="16px"
+   id="svg2987"
+   version="1.1"
+   inkscape:version="0.48.0 r9654"
+   sodipodi:docname="clock0.svg">
+  <defs
+     id="defs2989">
+    <linearGradient
+       id="linearGradient4465">
+      <stop
+         id="stop4467"
+         offset="0"
+         style="stop-color:#c1c1c1;stop-opacity:1;" />
+      <stop
+         id="stop4469"
+         offset="1"
+         style="stop-color:#8c8c8c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4424">
+      <stop
+         style="stop-color:#000000;stop-opacity:1;"
+         offset="0"
+         id="stop4426" />
+      <stop
+         style="stop-color:#b3b3b3;stop-opacity:1;"
+         offset="1"
+         id="stop4428" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4357">
+      <stop
+         id="stop4359"
+         offset="0"
+         style="stop-color:#ffffff;stop-opacity:1;" />
+      <stop
+         style="stop-color:#ff84a6;stop-opacity:0.49803922;"
+         offset="0.36363637"
+         id="stop4473" />
+      <stop
+         id="stop4361"
+         offset="1"
+         style="stop-color:#ff0a4d;stop-opacity:0;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4347">
+      <stop
+         id="stop4349"
+         offset="0"
+         style="stop-color:#909090;stop-opacity:1;" />
+      <stop
+         id="stop4351"
+         offset="1"
+         style="stop-color:#3c3c3c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient3767">
+      <stop
+         style="stop-color:#ff8282;stop-opacity:1;"
+         offset="0"
+         id="stop3769" />
+      <stop
+         style="stop-color:#ff1919;stop-opacity:1;"
+         offset="1"
+         id="stop3771" />
+    </linearGradient>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4347"
+       id="linearGradient3779"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574"
+       gradientUnits="userSpaceOnUse" />
+    <filter
+       inkscape:collect="always"
+       id="filter4339">
+      <feGaussianBlur
+         inkscape:collect="always"
+         stdDeviation="0.3240906"
+         id="feGaussianBlur4341" />
+    </filter>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3767"
+       id="linearGradient4345"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4424"
+       id="linearGradient4430"
+       x1="10.740074"
+       y1="16.148634"
+       x2="6.3055735"
+       y2="-1.2798394"
+       gradientUnits="userSpaceOnUse" />
+    <radialGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4357"
+       id="radialGradient4440"
+       gradientUnits="userSpaceOnUse"
+       gradientTransform="matrix(1.5712985,0.01074232,-0.01353758,1.9801676,-4.5655476,-0.68355868)"
+       cx="8.1975746"
+       cy="-0.080271922"
+       fx="8.1975746"
+       fy="-0.080271922"
+       r="7.7781744" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4465"
+       id="linearGradient4471"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="1"
+     inkscape:cx="0.31530906"
+     inkscape:cy="12.478576"
+     inkscape:current-layer="layer4"
+     showgrid="true"
+     inkscape:grid-bbox="true"
+     inkscape:document-units="px"
+     inkscape:window-width="1920"
+     inkscape:window-height="1127"
+     inkscape:window-x="0"
+     inkscape:window-y="25"
+     inkscape:window-maximized="1"
+     showguides="true"
+     inkscape:guide-bbox="true" />
+  <metadata
+     id="metadata2992">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title></dc:title>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     inkscape:groupmode="layer"
+     id="layer4"
+     inkscape:label="Shadow"
+     style="display:inline">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient3779);fill-opacity:1;stroke:none;display:inline;filter:url(#filter4339)"
+       id="path2997"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       transform="translate(0,-0.08838835)" />
+  </g>
+  <g
+     id="layer1"
+     inkscape:label="Clock"
+     inkscape:groupmode="layer"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       sodipodi:ry="7.7781744"
+       sodipodi:rx="7.7781744"
+       sodipodi:cy="8.1334372"
+       sodipodi:cx="8.0433397"
+       id="path4343"
+       style="fill:url(#linearGradient4345);fill-opacity:1;stroke:none"
+       sodipodi:type="arc" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer5"
+     inkscape:label="Block"
+     sodipodi:insensitive="true"
+     style="display:inline">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient4471);fill-opacity:1;stroke:none;display:inline"
+       id="path4462"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="M 14.4287,3.6919089 A 7.7781744,7.7781744 0 1 1 8.0707322,0.35531099 L 8.0433397,8.1334372 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       sodipodi:start="5.675432"
+       sodipodi:end="10.999096" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer2"
+     inkscape:label="Ticks"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       id="use4309"
+       transform="matrix(0.77323696,-0.44642857,0.44642857,0.77323696,-1.9715899,5.5529328)"
+       style="fill:url(#linearGradient4430);fill-opacity:1;stroke:none"
+       d="M 8.875,2.03125 C 8.875,2.5317581 8.4832492,2.9375 8,2.9375 7.5167508,2.9375 7.125,2.5317581 7.125,2.03125 7.125,1.5307419 7.5167508,1.125 8,1.125 c 0.4832492,0 0.875,0.4057419 0.875,0.90625 z M 5.8484195,2.6358993 C 6.0986735,3.069352 5.9622783,3.6166102 5.5437722,3.8582348 5.1252661,4.0998594 4.583129,3.944352 4.332875,3.5108993 4.082621,3.0774465 4.2190162,2.5301884 4.6375222,2.2885638 5.0560283,2.0469392 5.5981654,2.2024466 5.8484195,2.6358993 z M 3.5296488,4.6728304 C 3.9631015,4.9230844 4.1186089,5.4652215 3.8769843,5.8837276 3.6353597,6.3022337 3.0881015,6.4386289 2.6546488,6.1883748 2.221196,5.9381208 2.0656886,5.3959837 2.3073132,4.9774776 2.5489379,4.5589715 3.096196,4.4225763 3.5296488,4.6728304 z m -0.989649,2.9234201 c 0.5005081,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.4057419,0.875 -0.90625,0.875 -0.5005081,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.4057419,-0.875 0.90625,-0.875 z M 3.144649,10.622831 c 0.4334527,-0.250254 0.9807109,-0.113859 1.2223355,0.304647 0.2416246,0.418506 0.086117,0.960643 -0.3473355,1.210897 C 3.5861963,12.388629 3.0389381,12.252234 2.7973135,11.833728 2.5556889,11.415222 2.7111963,10.873085 3.144649,10.622831 z m 2.036931,2.31877 c 0.2502541,-0.433452 0.7923912,-0.58896 1.2108973,-0.347335 0.4185061,0.241624 0.5549012,0.788883 0.3046472,1.222335 -0.2502541,0.433453 -0.7923912,0.58896 -1.2108972,0.347336 C 5.0677212,13.922312 4.931326,13.375054 5.18158,12.941601 z m 2.9234201,0.989649 c 0,-0.500508 0.3917508,-0.90625 0.875,-0.90625 0.4832492,0 0.875,0.405742 0.875,0.90625 0,0.500509 -0.3917508,0.90625 -0.875,0.90625 -0.4832492,0 -0.875,-0.405741 -0.875,-0.90625 z M 11.13158,13.326601 c -0.250254,-0.433453 -0.113859,-0.980711 0.304647,-1.222335 0.418507,-0.241625 0.960644,-0.08612 1.210898,0.347335 0.250254,0.433453 0.113859,0.980711 -0.304648,1.222336 -0.418506,0.241624 -0.960643,0.08612 -1.210897,-0.347336 z m 2.318771,-2.036931 c -0.433453,-0.250254 -0.58896,-0.792391 -0.347335,-1.210897 0.241624,-0.4185064 0.788882,-0.5549016 1.222335,-0.3046476 0.433453,0.2502536 0.58896,0.7923916 0.347336,1.2108976 -0.241625,0.418506 -0.788883,0.554901 -1.222336,0.304647 z M 14.44,8.36625 c -0.500508,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.405742,-0.875 0.90625,-0.875 0.500508,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.405742,0.875 -0.90625,0.875 z M 13.835351,5.3396697 C 13.401898,5.5899238 12.85464,5.4535286 12.613016,5.0350225 12.371391,4.6165164 12.526898,4.0743793 12.960351,3.8241252 c 0.433453,-0.250254 0.980711,-0.1138588 1.222336,0.3046473 0.241624,0.4185061 0.08612,0.9606432 -0.347336,1.2108972 z M 11.79842,3.0208989 C 11.548166,3.4543516 11.006029,3.609859 10.587523,3.3682344 10.169017,3.1266098 10.032621,2.5793516 10.282875,2.1458989 10.533129,1.7124461 11.075267,1.5569388 11.493773,1.7985634 11.912279,2.040188 12.048674,2.5874462 11.79842,3.0208989 z"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="m 7.875,2.8017767 0,5.25"
+       id="path4436"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="M 7.7781746,7.4629419 10.783378,7.6397186"
+       id="path4438"
+       inkscape:connector-curvature="0" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer3"
+     inkscape:label="Shine"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#radialGradient4440);fill-opacity:1;stroke:none"
+       id="path4353"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.3686199"
+       sodipodi:ry="7.4368792"
+       d="m 15.41196,8.1334372 a 7.3686199,7.4368792 0 1 1 -14.73724019,0 7.3686199,7.4368792 0 1 1 14.73724019,0 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)" />
+  </g>
+</svg>
diff --git a/src/qt/res/src/clock2.svg b/src/qt/res/src/clock2.svg
new file mode 100644 (file)
index 0000000..6a78adf
--- /dev/null
@@ -0,0 +1,262 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:xlink="http://www.w3.org/1999/xlink"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="16px"
+   height="16px"
+   id="svg2987"
+   version="1.1"
+   inkscape:version="0.48.0 r9654"
+   sodipodi:docname="clock0.svg">
+  <defs
+     id="defs2989">
+    <linearGradient
+       id="linearGradient4465">
+      <stop
+         id="stop4467"
+         offset="0"
+         style="stop-color:#c1c1c1;stop-opacity:1;" />
+      <stop
+         id="stop4469"
+         offset="1"
+         style="stop-color:#8c8c8c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4424">
+      <stop
+         style="stop-color:#000000;stop-opacity:1;"
+         offset="0"
+         id="stop4426" />
+      <stop
+         style="stop-color:#b3b3b3;stop-opacity:1;"
+         offset="1"
+         id="stop4428" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4357">
+      <stop
+         id="stop4359"
+         offset="0"
+         style="stop-color:#ffffff;stop-opacity:1;" />
+      <stop
+         style="stop-color:#ff848d;stop-opacity:0.49803922;"
+         offset="0.36363637"
+         id="stop4473" />
+      <stop
+         id="stop4361"
+         offset="1"
+         style="stop-color:#ff0a1b;stop-opacity:0;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4347">
+      <stop
+         id="stop4349"
+         offset="0"
+         style="stop-color:#909090;stop-opacity:1;" />
+      <stop
+         id="stop4351"
+         offset="1"
+         style="stop-color:#3c3c3c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient3767">
+      <stop
+         style="stop-color:#ffae82;stop-opacity:1;"
+         offset="0"
+         id="stop3769" />
+      <stop
+         style="stop-color:#ff6a19;stop-opacity:1;"
+         offset="1"
+         id="stop3771" />
+    </linearGradient>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4347"
+       id="linearGradient3779"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574"
+       gradientUnits="userSpaceOnUse" />
+    <filter
+       inkscape:collect="always"
+       id="filter4339">
+      <feGaussianBlur
+         inkscape:collect="always"
+         stdDeviation="0.3240906"
+         id="feGaussianBlur4341" />
+    </filter>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3767"
+       id="linearGradient4345"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4424"
+       id="linearGradient4430"
+       x1="10.740074"
+       y1="16.148634"
+       x2="6.3055735"
+       y2="-1.2798394"
+       gradientUnits="userSpaceOnUse" />
+    <radialGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4357"
+       id="radialGradient4440"
+       gradientUnits="userSpaceOnUse"
+       gradientTransform="matrix(1.5712985,0.01074232,-0.01353758,1.9801676,-4.5655476,-0.68355868)"
+       cx="8.1975746"
+       cy="-0.080271922"
+       fx="8.1975746"
+       fy="-0.080271922"
+       r="7.7781744" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4465"
+       id="linearGradient4471"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="1"
+     inkscape:cx="10.569917"
+     inkscape:cy="10.828475"
+     inkscape:current-layer="layer5"
+     showgrid="true"
+     inkscape:grid-bbox="true"
+     inkscape:document-units="px"
+     inkscape:window-width="1920"
+     inkscape:window-height="1127"
+     inkscape:window-x="0"
+     inkscape:window-y="25"
+     inkscape:window-maximized="1"
+     showguides="true"
+     inkscape:guide-bbox="true" />
+  <metadata
+     id="metadata2992">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title></dc:title>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     inkscape:groupmode="layer"
+     id="layer4"
+     inkscape:label="Shadow"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient3779);fill-opacity:1;stroke:none;display:inline;filter:url(#filter4339)"
+       id="path2997"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       transform="translate(0,-0.08838835)" />
+  </g>
+  <g
+     id="layer1"
+     inkscape:label="Clock"
+     inkscape:groupmode="layer"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       sodipodi:ry="7.7781744"
+       sodipodi:rx="7.7781744"
+       sodipodi:cy="8.1334372"
+       sodipodi:cx="8.0433397"
+       id="path4343"
+       style="fill:url(#linearGradient4345);fill-opacity:1;stroke:none"
+       sodipodi:type="arc" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer5"
+     inkscape:label="Block"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient4471);fill-opacity:1;stroke:none;display:inline"
+       id="path4462"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="M 15.197954,11.184912 A 7.7781744,7.7781744 0 1 1 8.0707322,0.35531099 L 8.0433397,8.1334372 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       sodipodi:start="0.4031442"
+       sodipodi:end="4.7159107" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer2"
+     inkscape:label="Ticks"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       id="use4309"
+       transform="matrix(0.77323696,-0.44642857,0.44642857,0.77323696,-1.9715899,5.5529328)"
+       style="fill:url(#linearGradient4430);fill-opacity:1;stroke:none"
+       d="M 8.875,2.03125 C 8.875,2.5317581 8.4832492,2.9375 8,2.9375 7.5167508,2.9375 7.125,2.5317581 7.125,2.03125 7.125,1.5307419 7.5167508,1.125 8,1.125 c 0.4832492,0 0.875,0.4057419 0.875,0.90625 z M 5.8484195,2.6358993 C 6.0986735,3.069352 5.9622783,3.6166102 5.5437722,3.8582348 5.1252661,4.0998594 4.583129,3.944352 4.332875,3.5108993 4.082621,3.0774465 4.2190162,2.5301884 4.6375222,2.2885638 5.0560283,2.0469392 5.5981654,2.2024466 5.8484195,2.6358993 z M 3.5296488,4.6728304 C 3.9631015,4.9230844 4.1186089,5.4652215 3.8769843,5.8837276 3.6353597,6.3022337 3.0881015,6.4386289 2.6546488,6.1883748 2.221196,5.9381208 2.0656886,5.3959837 2.3073132,4.9774776 2.5489379,4.5589715 3.096196,4.4225763 3.5296488,4.6728304 z m -0.989649,2.9234201 c 0.5005081,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.4057419,0.875 -0.90625,0.875 -0.5005081,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.4057419,-0.875 0.90625,-0.875 z M 3.144649,10.622831 c 0.4334527,-0.250254 0.9807109,-0.113859 1.2223355,0.304647 0.2416246,0.418506 0.086117,0.960643 -0.3473355,1.210897 C 3.5861963,12.388629 3.0389381,12.252234 2.7973135,11.833728 2.5556889,11.415222 2.7111963,10.873085 3.144649,10.622831 z m 2.036931,2.31877 c 0.2502541,-0.433452 0.7923912,-0.58896 1.2108973,-0.347335 0.4185061,0.241624 0.5549012,0.788883 0.3046472,1.222335 -0.2502541,0.433453 -0.7923912,0.58896 -1.2108972,0.347336 C 5.0677212,13.922312 4.931326,13.375054 5.18158,12.941601 z m 2.9234201,0.989649 c 0,-0.500508 0.3917508,-0.90625 0.875,-0.90625 0.4832492,0 0.875,0.405742 0.875,0.90625 0,0.500509 -0.3917508,0.90625 -0.875,0.90625 -0.4832492,0 -0.875,-0.405741 -0.875,-0.90625 z M 11.13158,13.326601 c -0.250254,-0.433453 -0.113859,-0.980711 0.304647,-1.222335 0.418507,-0.241625 0.960644,-0.08612 1.210898,0.347335 0.250254,0.433453 0.113859,0.980711 -0.304648,1.222336 -0.418506,0.241624 -0.960643,0.08612 -1.210897,-0.347336 z m 2.318771,-2.036931 c -0.433453,-0.250254 -0.58896,-0.792391 -0.347335,-1.210897 0.241624,-0.4185064 0.788882,-0.5549016 1.222335,-0.3046476 0.433453,0.2502536 0.58896,0.7923916 0.347336,1.2108976 -0.241625,0.418506 -0.788883,0.554901 -1.222336,0.304647 z M 14.44,8.36625 c -0.500508,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.405742,-0.875 0.90625,-0.875 0.500508,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.405742,0.875 -0.90625,0.875 z M 13.835351,5.3396697 C 13.401898,5.5899238 12.85464,5.4535286 12.613016,5.0350225 12.371391,4.6165164 12.526898,4.0743793 12.960351,3.8241252 c 0.433453,-0.250254 0.980711,-0.1138588 1.222336,0.3046473 0.241624,0.4185061 0.08612,0.9606432 -0.347336,1.2108972 z M 11.79842,3.0208989 C 11.548166,3.4543516 11.006029,3.609859 10.587523,3.3682344 10.169017,3.1266098 10.032621,2.5793516 10.282875,2.1458989 10.533129,1.7124461 11.075267,1.5569388 11.493773,1.7985634 11.912279,2.040188 12.048674,2.5874462 11.79842,3.0208989 z"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="m 7.875,2.8017767 0,5.25"
+       id="path4436"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="M 7.7781746,7.4629419 10.783378,7.6397186"
+       id="path4438"
+       inkscape:connector-curvature="0" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer3"
+     inkscape:label="Shine"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#radialGradient4440);fill-opacity:1;stroke:none"
+       id="path4353"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.3686199"
+       sodipodi:ry="7.4368792"
+       d="m 15.41196,8.1334372 a 7.3686199,7.4368792 0 1 1 -14.73724019,0 7.3686199,7.4368792 0 1 1 14.73724019,0 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)" />
+  </g>
+</svg>
diff --git a/src/qt/res/src/clock3.svg b/src/qt/res/src/clock3.svg
new file mode 100644 (file)
index 0000000..09ccc25
--- /dev/null
@@ -0,0 +1,261 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:xlink="http://www.w3.org/1999/xlink"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="16px"
+   height="16px"
+   id="svg2987"
+   version="1.1"
+   inkscape:version="0.48.0 r9654"
+   sodipodi:docname="clock1.svg">
+  <defs
+     id="defs2989">
+    <linearGradient
+       id="linearGradient4465">
+      <stop
+         id="stop4467"
+         offset="0"
+         style="stop-color:#c1c1c1;stop-opacity:1;" />
+      <stop
+         id="stop4469"
+         offset="1"
+         style="stop-color:#8c8c8c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4424">
+      <stop
+         style="stop-color:#000000;stop-opacity:1;"
+         offset="0"
+         id="stop4426" />
+      <stop
+         style="stop-color:#b3b3b3;stop-opacity:1;"
+         offset="1"
+         id="stop4428" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4357">
+      <stop
+         id="stop4359"
+         offset="0"
+         style="stop-color:#ffffff;stop-opacity:1;" />
+      <stop
+         style="stop-color:#ffa184;stop-opacity:0.49803922;"
+         offset="0.36363637"
+         id="stop4473" />
+      <stop
+         id="stop4361"
+         offset="1"
+         style="stop-color:#ff440a;stop-opacity:0;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4347">
+      <stop
+         id="stop4349"
+         offset="0"
+         style="stop-color:#909090;stop-opacity:1;" />
+      <stop
+         id="stop4351"
+         offset="1"
+         style="stop-color:#3c3c3c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient3767">
+      <stop
+         style="stop-color:#ffda82;stop-opacity:1;"
+         offset="0"
+         id="stop3769" />
+      <stop
+         style="stop-color:#ffbb19;stop-opacity:1;"
+         offset="1"
+         id="stop3771" />
+    </linearGradient>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4347"
+       id="linearGradient3779"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574"
+       gradientUnits="userSpaceOnUse" />
+    <filter
+       inkscape:collect="always"
+       id="filter4339">
+      <feGaussianBlur
+         inkscape:collect="always"
+         stdDeviation="0.3240906"
+         id="feGaussianBlur4341" />
+    </filter>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3767"
+       id="linearGradient4345"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4424"
+       id="linearGradient4430"
+       x1="10.740074"
+       y1="16.148634"
+       x2="6.3055735"
+       y2="-1.2798394"
+       gradientUnits="userSpaceOnUse" />
+    <radialGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4357"
+       id="radialGradient4440"
+       gradientUnits="userSpaceOnUse"
+       gradientTransform="matrix(1.5712985,0.01074232,-0.01353758,1.9801676,-4.5655476,-0.68355868)"
+       cx="8.1975746"
+       cy="-0.080271922"
+       fx="8.1975746"
+       fy="-0.080271922"
+       r="7.7781744" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4465"
+       id="linearGradient4471"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="23.894737"
+     inkscape:cx="16"
+     inkscape:cy="-1"
+     inkscape:current-layer="layer5"
+     showgrid="true"
+     inkscape:grid-bbox="true"
+     inkscape:document-units="px"
+     inkscape:window-width="1920"
+     inkscape:window-height="1127"
+     inkscape:window-x="0"
+     inkscape:window-y="25"
+     inkscape:window-maximized="1"
+     showguides="true"
+     inkscape:guide-bbox="true" />
+  <metadata
+     id="metadata2992">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title></dc:title>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     inkscape:groupmode="layer"
+     id="layer4"
+     inkscape:label="Shadow"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient3779);fill-opacity:1;stroke:none;display:inline;filter:url(#filter4339)"
+       id="path2997"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       transform="translate(0,-0.08838835)" />
+  </g>
+  <g
+     id="layer1"
+     inkscape:label="Clock"
+     inkscape:groupmode="layer"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       sodipodi:ry="7.7781744"
+       sodipodi:rx="7.7781744"
+       sodipodi:cy="8.1334372"
+       sodipodi:cx="8.0433397"
+       id="path4343"
+       style="fill:url(#linearGradient4345);fill-opacity:1;stroke:none"
+       sodipodi:type="arc" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer5"
+     inkscape:label="Block"
+     style="display:inline">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient4471);fill-opacity:1;stroke:none;display:inline"
+       id="path4462"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="M 8.2135533,15.909749 A 7.7781744,7.7781744 0 1 1 8.0707322,0.35531099 L 8.0433397,8.1334372 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       sodipodi:start="1.5489111"
+       sodipodi:end="4.7159107" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer2"
+     inkscape:label="Ticks"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       id="use4309"
+       transform="matrix(0.77323696,-0.44642857,0.44642857,0.77323696,-1.9715899,5.5529328)"
+       style="fill:url(#linearGradient4430);fill-opacity:1;stroke:none"
+       d="M 8.875,2.03125 C 8.875,2.5317581 8.4832492,2.9375 8,2.9375 7.5167508,2.9375 7.125,2.5317581 7.125,2.03125 7.125,1.5307419 7.5167508,1.125 8,1.125 c 0.4832492,0 0.875,0.4057419 0.875,0.90625 z M 5.8484195,2.6358993 C 6.0986735,3.069352 5.9622783,3.6166102 5.5437722,3.8582348 5.1252661,4.0998594 4.583129,3.944352 4.332875,3.5108993 4.082621,3.0774465 4.2190162,2.5301884 4.6375222,2.2885638 5.0560283,2.0469392 5.5981654,2.2024466 5.8484195,2.6358993 z M 3.5296488,4.6728304 C 3.9631015,4.9230844 4.1186089,5.4652215 3.8769843,5.8837276 3.6353597,6.3022337 3.0881015,6.4386289 2.6546488,6.1883748 2.221196,5.9381208 2.0656886,5.3959837 2.3073132,4.9774776 2.5489379,4.5589715 3.096196,4.4225763 3.5296488,4.6728304 z m -0.989649,2.9234201 c 0.5005081,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.4057419,0.875 -0.90625,0.875 -0.5005081,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.4057419,-0.875 0.90625,-0.875 z M 3.144649,10.622831 c 0.4334527,-0.250254 0.9807109,-0.113859 1.2223355,0.304647 0.2416246,0.418506 0.086117,0.960643 -0.3473355,1.210897 C 3.5861963,12.388629 3.0389381,12.252234 2.7973135,11.833728 2.5556889,11.415222 2.7111963,10.873085 3.144649,10.622831 z m 2.036931,2.31877 c 0.2502541,-0.433452 0.7923912,-0.58896 1.2108973,-0.347335 0.4185061,0.241624 0.5549012,0.788883 0.3046472,1.222335 -0.2502541,0.433453 -0.7923912,0.58896 -1.2108972,0.347336 C 5.0677212,13.922312 4.931326,13.375054 5.18158,12.941601 z m 2.9234201,0.989649 c 0,-0.500508 0.3917508,-0.90625 0.875,-0.90625 0.4832492,0 0.875,0.405742 0.875,0.90625 0,0.500509 -0.3917508,0.90625 -0.875,0.90625 -0.4832492,0 -0.875,-0.405741 -0.875,-0.90625 z M 11.13158,13.326601 c -0.250254,-0.433453 -0.113859,-0.980711 0.304647,-1.222335 0.418507,-0.241625 0.960644,-0.08612 1.210898,0.347335 0.250254,0.433453 0.113859,0.980711 -0.304648,1.222336 -0.418506,0.241624 -0.960643,0.08612 -1.210897,-0.347336 z m 2.318771,-2.036931 c -0.433453,-0.250254 -0.58896,-0.792391 -0.347335,-1.210897 0.241624,-0.4185064 0.788882,-0.5549016 1.222335,-0.3046476 0.433453,0.2502536 0.58896,0.7923916 0.347336,1.2108976 -0.241625,0.418506 -0.788883,0.554901 -1.222336,0.304647 z M 14.44,8.36625 c -0.500508,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.405742,-0.875 0.90625,-0.875 0.500508,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.405742,0.875 -0.90625,0.875 z M 13.835351,5.3396697 C 13.401898,5.5899238 12.85464,5.4535286 12.613016,5.0350225 12.371391,4.6165164 12.526898,4.0743793 12.960351,3.8241252 c 0.433453,-0.250254 0.980711,-0.1138588 1.222336,0.3046473 0.241624,0.4185061 0.08612,0.9606432 -0.347336,1.2108972 z M 11.79842,3.0208989 C 11.548166,3.4543516 11.006029,3.609859 10.587523,3.3682344 10.169017,3.1266098 10.032621,2.5793516 10.282875,2.1458989 10.533129,1.7124461 11.075267,1.5569388 11.493773,1.7985634 11.912279,2.040188 12.048674,2.5874462 11.79842,3.0208989 z"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="m 7.875,2.8017767 0,5.25"
+       id="path4436"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="M 7.7781746,7.4629419 10.783378,7.6397186"
+       id="path4438"
+       inkscape:connector-curvature="0" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer3"
+     inkscape:label="Shine"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#radialGradient4440);fill-opacity:1;stroke:none"
+       id="path4353"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.3686199"
+       sodipodi:ry="7.4368792"
+       d="m 15.41196,8.1334372 a 7.3686199,7.4368792 0 1 1 -14.73724019,0 7.3686199,7.4368792 0 1 1 14.73724019,0 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)" />
+  </g>
+</svg>
diff --git a/src/qt/res/src/clock4.svg b/src/qt/res/src/clock4.svg
new file mode 100644 (file)
index 0000000..7d9dc37
--- /dev/null
@@ -0,0 +1,261 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:xlink="http://www.w3.org/1999/xlink"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="16px"
+   height="16px"
+   id="svg2987"
+   version="1.1"
+   inkscape:version="0.48.0 r9654"
+   sodipodi:docname="clock2.svg">
+  <defs
+     id="defs2989">
+    <linearGradient
+       id="linearGradient4465">
+      <stop
+         id="stop4467"
+         offset="0"
+         style="stop-color:#c1c1c1;stop-opacity:1;" />
+      <stop
+         id="stop4469"
+         offset="1"
+         style="stop-color:#8c8c8c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4424">
+      <stop
+         style="stop-color:#000000;stop-opacity:1;"
+         offset="0"
+         id="stop4426" />
+      <stop
+         style="stop-color:#b3b3b3;stop-opacity:1;"
+         offset="1"
+         id="stop4428" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4357">
+      <stop
+         id="stop4359"
+         offset="0"
+         style="stop-color:#ffffff;stop-opacity:1;" />
+      <stop
+         style="stop-color:#ffcc84;stop-opacity:0.49803922;"
+         offset="0.36363637"
+         id="stop4473" />
+      <stop
+         id="stop4361"
+         offset="1"
+         style="stop-color:#ff9a0a;stop-opacity:0;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4347">
+      <stop
+         id="stop4349"
+         offset="0"
+         style="stop-color:#909090;stop-opacity:1;" />
+      <stop
+         id="stop4351"
+         offset="1"
+         style="stop-color:#3c3c3c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient3767">
+      <stop
+         style="stop-color:#f8ff82;stop-opacity:1;"
+         offset="0"
+         id="stop3769" />
+      <stop
+         style="stop-color:#f1ff19;stop-opacity:1;"
+         offset="1"
+         id="stop3771" />
+    </linearGradient>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4347"
+       id="linearGradient3779"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574"
+       gradientUnits="userSpaceOnUse" />
+    <filter
+       inkscape:collect="always"
+       id="filter4339">
+      <feGaussianBlur
+         inkscape:collect="always"
+         stdDeviation="0.3240906"
+         id="feGaussianBlur4341" />
+    </filter>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3767"
+       id="linearGradient4345"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4424"
+       id="linearGradient4430"
+       x1="10.740074"
+       y1="16.148634"
+       x2="6.3055735"
+       y2="-1.2798394"
+       gradientUnits="userSpaceOnUse" />
+    <radialGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4357"
+       id="radialGradient4440"
+       gradientUnits="userSpaceOnUse"
+       gradientTransform="matrix(1.5712985,0.01074232,-0.01353758,1.9801676,-4.5655476,-0.68355868)"
+       cx="8.1975746"
+       cy="-0.080271922"
+       fx="8.1975746"
+       fy="-0.080271922"
+       r="7.7781744" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4465"
+       id="linearGradient4471"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="16"
+     inkscape:cx="8.6111742"
+     inkscape:cy="6.6684704"
+     inkscape:current-layer="layer5"
+     showgrid="true"
+     inkscape:grid-bbox="true"
+     inkscape:document-units="px"
+     inkscape:window-width="1920"
+     inkscape:window-height="1127"
+     inkscape:window-x="0"
+     inkscape:window-y="25"
+     inkscape:window-maximized="1"
+     showguides="true"
+     inkscape:guide-bbox="true" />
+  <metadata
+     id="metadata2992">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title></dc:title>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     inkscape:groupmode="layer"
+     id="layer4"
+     inkscape:label="Shadow"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient3779);fill-opacity:1;stroke:none;display:inline;filter:url(#filter4339)"
+       id="path2997"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       transform="translate(0,-0.08838835)" />
+  </g>
+  <g
+     id="layer1"
+     inkscape:label="Clock"
+     inkscape:groupmode="layer"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       sodipodi:ry="7.7781744"
+       sodipodi:rx="7.7781744"
+       sodipodi:cy="8.1334372"
+       sodipodi:cx="8.0433397"
+       id="path4343"
+       style="fill:url(#linearGradient4345);fill-opacity:1;stroke:none"
+       sodipodi:type="arc" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer5"
+     inkscape:label="Block"
+     style="display:inline">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient4471);fill-opacity:1;stroke:none;display:inline"
+       id="path4462"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="M 1.7005474,12.635546 A 7.7781744,7.7781744 0 0 1 8.0707322,0.35531099 L 8.0433397,8.1334372 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       sodipodi:start="2.5243203"
+       sodipodi:end="4.7159107" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer2"
+     inkscape:label="Ticks"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       id="use4309"
+       transform="matrix(0.77323696,-0.44642857,0.44642857,0.77323696,-1.9715899,5.5529328)"
+       style="fill:url(#linearGradient4430);fill-opacity:1;stroke:none"
+       d="M 8.875,2.03125 C 8.875,2.5317581 8.4832492,2.9375 8,2.9375 7.5167508,2.9375 7.125,2.5317581 7.125,2.03125 7.125,1.5307419 7.5167508,1.125 8,1.125 c 0.4832492,0 0.875,0.4057419 0.875,0.90625 z M 5.8484195,2.6358993 C 6.0986735,3.069352 5.9622783,3.6166102 5.5437722,3.8582348 5.1252661,4.0998594 4.583129,3.944352 4.332875,3.5108993 4.082621,3.0774465 4.2190162,2.5301884 4.6375222,2.2885638 5.0560283,2.0469392 5.5981654,2.2024466 5.8484195,2.6358993 z M 3.5296488,4.6728304 C 3.9631015,4.9230844 4.1186089,5.4652215 3.8769843,5.8837276 3.6353597,6.3022337 3.0881015,6.4386289 2.6546488,6.1883748 2.221196,5.9381208 2.0656886,5.3959837 2.3073132,4.9774776 2.5489379,4.5589715 3.096196,4.4225763 3.5296488,4.6728304 z m -0.989649,2.9234201 c 0.5005081,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.4057419,0.875 -0.90625,0.875 -0.5005081,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.4057419,-0.875 0.90625,-0.875 z M 3.144649,10.622831 c 0.4334527,-0.250254 0.9807109,-0.113859 1.2223355,0.304647 0.2416246,0.418506 0.086117,0.960643 -0.3473355,1.210897 C 3.5861963,12.388629 3.0389381,12.252234 2.7973135,11.833728 2.5556889,11.415222 2.7111963,10.873085 3.144649,10.622831 z m 2.036931,2.31877 c 0.2502541,-0.433452 0.7923912,-0.58896 1.2108973,-0.347335 0.4185061,0.241624 0.5549012,0.788883 0.3046472,1.222335 -0.2502541,0.433453 -0.7923912,0.58896 -1.2108972,0.347336 C 5.0677212,13.922312 4.931326,13.375054 5.18158,12.941601 z m 2.9234201,0.989649 c 0,-0.500508 0.3917508,-0.90625 0.875,-0.90625 0.4832492,0 0.875,0.405742 0.875,0.90625 0,0.500509 -0.3917508,0.90625 -0.875,0.90625 -0.4832492,0 -0.875,-0.405741 -0.875,-0.90625 z M 11.13158,13.326601 c -0.250254,-0.433453 -0.113859,-0.980711 0.304647,-1.222335 0.418507,-0.241625 0.960644,-0.08612 1.210898,0.347335 0.250254,0.433453 0.113859,0.980711 -0.304648,1.222336 -0.418506,0.241624 -0.960643,0.08612 -1.210897,-0.347336 z m 2.318771,-2.036931 c -0.433453,-0.250254 -0.58896,-0.792391 -0.347335,-1.210897 0.241624,-0.4185064 0.788882,-0.5549016 1.222335,-0.3046476 0.433453,0.2502536 0.58896,0.7923916 0.347336,1.2108976 -0.241625,0.418506 -0.788883,0.554901 -1.222336,0.304647 z M 14.44,8.36625 c -0.500508,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.405742,-0.875 0.90625,-0.875 0.500508,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.405742,0.875 -0.90625,0.875 z M 13.835351,5.3396697 C 13.401898,5.5899238 12.85464,5.4535286 12.613016,5.0350225 12.371391,4.6165164 12.526898,4.0743793 12.960351,3.8241252 c 0.433453,-0.250254 0.980711,-0.1138588 1.222336,0.3046473 0.241624,0.4185061 0.08612,0.9606432 -0.347336,1.2108972 z M 11.79842,3.0208989 C 11.548166,3.4543516 11.006029,3.609859 10.587523,3.3682344 10.169017,3.1266098 10.032621,2.5793516 10.282875,2.1458989 10.533129,1.7124461 11.075267,1.5569388 11.493773,1.7985634 11.912279,2.040188 12.048674,2.5874462 11.79842,3.0208989 z"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="m 7.875,2.8017767 0,5.25"
+       id="path4436"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="M 7.7781746,7.4629419 10.783378,7.6397186"
+       id="path4438"
+       inkscape:connector-curvature="0" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer3"
+     inkscape:label="Shine"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#radialGradient4440);fill-opacity:1;stroke:none"
+       id="path4353"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.3686199"
+       sodipodi:ry="7.4368792"
+       d="m 15.41196,8.1334372 a 7.3686199,7.4368792 0 1 1 -14.73724019,0 7.3686199,7.4368792 0 1 1 14.73724019,0 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)" />
+  </g>
+</svg>
diff --git a/src/qt/res/src/clock5.svg b/src/qt/res/src/clock5.svg
new file mode 100644 (file)
index 0000000..9fd58d9
--- /dev/null
@@ -0,0 +1,262 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:xlink="http://www.w3.org/1999/xlink"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="16px"
+   height="16px"
+   id="svg2987"
+   version="1.1"
+   inkscape:version="0.48.0 r9654"
+   sodipodi:docname="clock3.svg">
+  <defs
+     id="defs2989">
+    <linearGradient
+       id="linearGradient4465">
+      <stop
+         id="stop4467"
+         offset="0"
+         style="stop-color:#c1c1c1;stop-opacity:1;" />
+      <stop
+         id="stop4469"
+         offset="1"
+         style="stop-color:#8c8c8c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4424">
+      <stop
+         style="stop-color:#000000;stop-opacity:1;"
+         offset="0"
+         id="stop4426" />
+      <stop
+         style="stop-color:#b3b3b3;stop-opacity:1;"
+         offset="1"
+         id="stop4428" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4357">
+      <stop
+         id="stop4359"
+         offset="0"
+         style="stop-color:#ffffff;stop-opacity:1;" />
+      <stop
+         style="stop-color:#fff884;stop-opacity:0.49803922;"
+         offset="0.36363637"
+         id="stop4473" />
+      <stop
+         id="stop4361"
+         offset="1"
+         style="stop-color:#fff10a;stop-opacity:0;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4347">
+      <stop
+         id="stop4349"
+         offset="0"
+         style="stop-color:#909090;stop-opacity:1;" />
+      <stop
+         id="stop4351"
+         offset="1"
+         style="stop-color:#3c3c3c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient3767">
+      <stop
+         style="stop-color:#ccff82;stop-opacity:1;"
+         offset="0"
+         id="stop3769" />
+      <stop
+         style="stop-color:#a0ff19;stop-opacity:1;"
+         offset="1"
+         id="stop3771" />
+    </linearGradient>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4347"
+       id="linearGradient3779"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574"
+       gradientUnits="userSpaceOnUse" />
+    <filter
+       inkscape:collect="always"
+       id="filter4339">
+      <feGaussianBlur
+         inkscape:collect="always"
+         stdDeviation="0.3240906"
+         id="feGaussianBlur4341" />
+    </filter>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3767"
+       id="linearGradient4345"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4424"
+       id="linearGradient4430"
+       x1="10.740074"
+       y1="16.148634"
+       x2="6.3055735"
+       y2="-1.2798394"
+       gradientUnits="userSpaceOnUse" />
+    <radialGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4357"
+       id="radialGradient4440"
+       gradientUnits="userSpaceOnUse"
+       gradientTransform="matrix(1.5712985,0.01074232,-0.01353758,1.9801676,-4.5655476,-0.68355868)"
+       cx="8.1975746"
+       cy="-0.080271922"
+       fx="8.1975746"
+       fy="-0.080271922"
+       r="7.7781744" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4465"
+       id="linearGradient4471"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="16"
+     inkscape:cx="8.6111742"
+     inkscape:cy="6.6684704"
+     inkscape:current-layer="layer3"
+     showgrid="true"
+     inkscape:grid-bbox="true"
+     inkscape:document-units="px"
+     inkscape:window-width="1920"
+     inkscape:window-height="1127"
+     inkscape:window-x="0"
+     inkscape:window-y="25"
+     inkscape:window-maximized="1"
+     showguides="true"
+     inkscape:guide-bbox="true" />
+  <metadata
+     id="metadata2992">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title></dc:title>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     inkscape:groupmode="layer"
+     id="layer4"
+     inkscape:label="Shadow"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient3779);fill-opacity:1;stroke:none;display:inline;filter:url(#filter4339)"
+       id="path2997"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       transform="translate(0,-0.08838835)" />
+  </g>
+  <g
+     id="layer1"
+     inkscape:label="Clock"
+     inkscape:groupmode="layer"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       sodipodi:ry="7.7781744"
+       sodipodi:rx="7.7781744"
+       sodipodi:cy="8.1334372"
+       sodipodi:cx="8.0433397"
+       id="path4343"
+       style="fill:url(#linearGradient4345);fill-opacity:1;stroke:none"
+       sodipodi:type="arc" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer5"
+     inkscape:label="Block"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient4471);fill-opacity:1;stroke:none;display:inline"
+       id="path4462"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="M 1.0968082,4.6340519 A 7.7781744,7.7781744 0 0 1 8.0707322,0.35531099 L 8.0433397,8.1334372 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       sodipodi:start="3.6082438"
+       sodipodi:end="4.7159107" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer2"
+     inkscape:label="Ticks"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       id="use4309"
+       transform="matrix(0.77323696,-0.44642857,0.44642857,0.77323696,-1.9715899,5.5529328)"
+       style="fill:url(#linearGradient4430);fill-opacity:1;stroke:none"
+       d="M 8.875,2.03125 C 8.875,2.5317581 8.4832492,2.9375 8,2.9375 7.5167508,2.9375 7.125,2.5317581 7.125,2.03125 7.125,1.5307419 7.5167508,1.125 8,1.125 c 0.4832492,0 0.875,0.4057419 0.875,0.90625 z M 5.8484195,2.6358993 C 6.0986735,3.069352 5.9622783,3.6166102 5.5437722,3.8582348 5.1252661,4.0998594 4.583129,3.944352 4.332875,3.5108993 4.082621,3.0774465 4.2190162,2.5301884 4.6375222,2.2885638 5.0560283,2.0469392 5.5981654,2.2024466 5.8484195,2.6358993 z M 3.5296488,4.6728304 C 3.9631015,4.9230844 4.1186089,5.4652215 3.8769843,5.8837276 3.6353597,6.3022337 3.0881015,6.4386289 2.6546488,6.1883748 2.221196,5.9381208 2.0656886,5.3959837 2.3073132,4.9774776 2.5489379,4.5589715 3.096196,4.4225763 3.5296488,4.6728304 z m -0.989649,2.9234201 c 0.5005081,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.4057419,0.875 -0.90625,0.875 -0.5005081,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.4057419,-0.875 0.90625,-0.875 z M 3.144649,10.622831 c 0.4334527,-0.250254 0.9807109,-0.113859 1.2223355,0.304647 0.2416246,0.418506 0.086117,0.960643 -0.3473355,1.210897 C 3.5861963,12.388629 3.0389381,12.252234 2.7973135,11.833728 2.5556889,11.415222 2.7111963,10.873085 3.144649,10.622831 z m 2.036931,2.31877 c 0.2502541,-0.433452 0.7923912,-0.58896 1.2108973,-0.347335 0.4185061,0.241624 0.5549012,0.788883 0.3046472,1.222335 -0.2502541,0.433453 -0.7923912,0.58896 -1.2108972,0.347336 C 5.0677212,13.922312 4.931326,13.375054 5.18158,12.941601 z m 2.9234201,0.989649 c 0,-0.500508 0.3917508,-0.90625 0.875,-0.90625 0.4832492,0 0.875,0.405742 0.875,0.90625 0,0.500509 -0.3917508,0.90625 -0.875,0.90625 -0.4832492,0 -0.875,-0.405741 -0.875,-0.90625 z M 11.13158,13.326601 c -0.250254,-0.433453 -0.113859,-0.980711 0.304647,-1.222335 0.418507,-0.241625 0.960644,-0.08612 1.210898,0.347335 0.250254,0.433453 0.113859,0.980711 -0.304648,1.222336 -0.418506,0.241624 -0.960643,0.08612 -1.210897,-0.347336 z m 2.318771,-2.036931 c -0.433453,-0.250254 -0.58896,-0.792391 -0.347335,-1.210897 0.241624,-0.4185064 0.788882,-0.5549016 1.222335,-0.3046476 0.433453,0.2502536 0.58896,0.7923916 0.347336,1.2108976 -0.241625,0.418506 -0.788883,0.554901 -1.222336,0.304647 z M 14.44,8.36625 c -0.500508,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.405742,-0.875 0.90625,-0.875 0.500508,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.405742,0.875 -0.90625,0.875 z M 13.835351,5.3396697 C 13.401898,5.5899238 12.85464,5.4535286 12.613016,5.0350225 12.371391,4.6165164 12.526898,4.0743793 12.960351,3.8241252 c 0.433453,-0.250254 0.980711,-0.1138588 1.222336,0.3046473 0.241624,0.4185061 0.08612,0.9606432 -0.347336,1.2108972 z M 11.79842,3.0208989 C 11.548166,3.4543516 11.006029,3.609859 10.587523,3.3682344 10.169017,3.1266098 10.032621,2.5793516 10.282875,2.1458989 10.533129,1.7124461 11.075267,1.5569388 11.493773,1.7985634 11.912279,2.040188 12.048674,2.5874462 11.79842,3.0208989 z"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="m 7.875,2.8017767 0,5.25"
+       id="path4436"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="M 7.7781746,7.4629419 10.783378,7.6397186"
+       id="path4438"
+       inkscape:connector-curvature="0" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer3"
+     inkscape:label="Shine"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#radialGradient4440);fill-opacity:1;stroke:none"
+       id="path4353"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.3686199"
+       sodipodi:ry="7.4368792"
+       d="m 15.41196,8.1334372 a 7.3686199,7.4368792 0 1 1 -14.73724019,0 7.3686199,7.4368792 0 1 1 14.73724019,0 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)" />
+  </g>
+</svg>
diff --git a/src/qt/res/src/clock_green.svg b/src/qt/res/src/clock_green.svg
new file mode 100644 (file)
index 0000000..e31f0e7
--- /dev/null
@@ -0,0 +1,262 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:xlink="http://www.w3.org/1999/xlink"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="16px"
+   height="16px"
+   id="svg2987"
+   version="1.1"
+   inkscape:version="0.48.0 r9654"
+   sodipodi:docname="clock_green.svg">
+  <defs
+     id="defs2989">
+    <linearGradient
+       id="linearGradient4465">
+      <stop
+         id="stop4467"
+         offset="0"
+         style="stop-color:#c1c1c1;stop-opacity:1;" />
+      <stop
+         id="stop4469"
+         offset="1"
+         style="stop-color:#8c8c8c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4424">
+      <stop
+         style="stop-color:#000000;stop-opacity:1;"
+         offset="0"
+         id="stop4426" />
+      <stop
+         style="stop-color:#b3b3b3;stop-opacity:1;"
+         offset="1"
+         id="stop4428" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4357">
+      <stop
+         id="stop4359"
+         offset="0"
+         style="stop-color:#ffffff;stop-opacity:1;" />
+      <stop
+         style="stop-color:#baff84;stop-opacity:0.49803922;"
+         offset="0.36363637"
+         id="stop4473" />
+      <stop
+         id="stop4361"
+         offset="1"
+         style="stop-color:#76ff0a;stop-opacity:0;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient4347">
+      <stop
+         id="stop4349"
+         offset="0"
+         style="stop-color:#c1c1c1;stop-opacity:1;" />
+      <stop
+         id="stop4351"
+         offset="1"
+         style="stop-color:#8c8c8c;stop-opacity:1;" />
+    </linearGradient>
+    <linearGradient
+       id="linearGradient3767">
+      <stop
+         style="stop-color:#82ff82;stop-opacity:1;"
+         offset="0"
+         id="stop3769" />
+      <stop
+         style="stop-color:#19ff19;stop-opacity:1;"
+         offset="1"
+         id="stop3771" />
+    </linearGradient>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4347"
+       id="linearGradient3779"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574"
+       gradientUnits="userSpaceOnUse" />
+    <filter
+       inkscape:collect="always"
+       id="filter4339">
+      <feGaussianBlur
+         inkscape:collect="always"
+         stdDeviation="0.3240906"
+         id="feGaussianBlur4341" />
+    </filter>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3767"
+       id="linearGradient4345"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4424"
+       id="linearGradient4430"
+       x1="10.740074"
+       y1="16.148634"
+       x2="6.3055735"
+       y2="-1.2798394"
+       gradientUnits="userSpaceOnUse" />
+    <radialGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4357"
+       id="radialGradient4440"
+       gradientUnits="userSpaceOnUse"
+       gradientTransform="matrix(1.5712985,0.01074232,-0.01353758,1.9801676,-4.5655476,-0.68355868)"
+       cx="8.1975746"
+       cy="-0.080271922"
+       fx="8.1975746"
+       fy="-0.080271922"
+       r="7.7781744" />
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient4465"
+       id="linearGradient4471"
+       gradientUnits="userSpaceOnUse"
+       x1="2.224874"
+       y1="2.8301363"
+       x2="14.038582"
+       y2="13.171574" />
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="8"
+     inkscape:cx="9.1870806"
+     inkscape:cy="14.089546"
+     inkscape:current-layer="layer3"
+     showgrid="true"
+     inkscape:grid-bbox="true"
+     inkscape:document-units="px"
+     inkscape:window-width="1920"
+     inkscape:window-height="1127"
+     inkscape:window-x="0"
+     inkscape:window-y="25"
+     inkscape:window-maximized="1"
+     showguides="true"
+     inkscape:guide-bbox="true" />
+  <metadata
+     id="metadata2992">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title></dc:title>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     inkscape:groupmode="layer"
+     id="layer4"
+     inkscape:label="Shadow"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient3779);fill-opacity:1;stroke:none;display:inline;filter:url(#filter4339)"
+       id="path2997"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       transform="translate(0,-0.08838835)" />
+  </g>
+  <g
+     id="layer1"
+     inkscape:label="Clock"
+     inkscape:groupmode="layer"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       d="m 15.821514,8.1334372 a 7.7781744,7.7781744 0 1 1 -15.55634867,0 7.7781744,7.7781744 0 1 1 15.55634867,0 z"
+       sodipodi:ry="7.7781744"
+       sodipodi:rx="7.7781744"
+       sodipodi:cy="8.1334372"
+       sodipodi:cx="8.0433397"
+       id="path4343"
+       style="fill:url(#linearGradient4345);fill-opacity:1;stroke:none"
+       sodipodi:type="arc" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer5"
+     inkscape:label="Block"
+     sodipodi:insensitive="true"
+     style="display:inline">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#linearGradient4471);fill-opacity:1;stroke:none;display:inline"
+       id="path4462"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.7781744"
+       sodipodi:ry="7.7781744"
+       d="M 14.4287,3.6919089 A 7.7781744,7.7781744 0 1 1 8.0707322,0.35531099 L 8.0433397,8.1334372 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)"
+       sodipodi:start="5.675432"
+       sodipodi:end="10.999096" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer2"
+     inkscape:label="Ticks"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       id="use4309"
+       transform="matrix(0.77323696,-0.44642857,0.44642857,0.77323696,-1.9715899,5.5529328)"
+       style="fill:url(#linearGradient4430);fill-opacity:1;stroke:none"
+       d="M 8.875,2.03125 C 8.875,2.5317581 8.4832492,2.9375 8,2.9375 7.5167508,2.9375 7.125,2.5317581 7.125,2.03125 7.125,1.5307419 7.5167508,1.125 8,1.125 c 0.4832492,0 0.875,0.4057419 0.875,0.90625 z M 5.8484195,2.6358993 C 6.0986735,3.069352 5.9622783,3.6166102 5.5437722,3.8582348 5.1252661,4.0998594 4.583129,3.944352 4.332875,3.5108993 4.082621,3.0774465 4.2190162,2.5301884 4.6375222,2.2885638 5.0560283,2.0469392 5.5981654,2.2024466 5.8484195,2.6358993 z M 3.5296488,4.6728304 C 3.9631015,4.9230844 4.1186089,5.4652215 3.8769843,5.8837276 3.6353597,6.3022337 3.0881015,6.4386289 2.6546488,6.1883748 2.221196,5.9381208 2.0656886,5.3959837 2.3073132,4.9774776 2.5489379,4.5589715 3.096196,4.4225763 3.5296488,4.6728304 z m -0.989649,2.9234201 c 0.5005081,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.4057419,0.875 -0.90625,0.875 -0.5005081,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.4057419,-0.875 0.90625,-0.875 z M 3.144649,10.622831 c 0.4334527,-0.250254 0.9807109,-0.113859 1.2223355,0.304647 0.2416246,0.418506 0.086117,0.960643 -0.3473355,1.210897 C 3.5861963,12.388629 3.0389381,12.252234 2.7973135,11.833728 2.5556889,11.415222 2.7111963,10.873085 3.144649,10.622831 z m 2.036931,2.31877 c 0.2502541,-0.433452 0.7923912,-0.58896 1.2108973,-0.347335 0.4185061,0.241624 0.5549012,0.788883 0.3046472,1.222335 -0.2502541,0.433453 -0.7923912,0.58896 -1.2108972,0.347336 C 5.0677212,13.922312 4.931326,13.375054 5.18158,12.941601 z m 2.9234201,0.989649 c 0,-0.500508 0.3917508,-0.90625 0.875,-0.90625 0.4832492,0 0.875,0.405742 0.875,0.90625 0,0.500509 -0.3917508,0.90625 -0.875,0.90625 -0.4832492,0 -0.875,-0.405741 -0.875,-0.90625 z M 11.13158,13.326601 c -0.250254,-0.433453 -0.113859,-0.980711 0.304647,-1.222335 0.418507,-0.241625 0.960644,-0.08612 1.210898,0.347335 0.250254,0.433453 0.113859,0.980711 -0.304648,1.222336 -0.418506,0.241624 -0.960643,0.08612 -1.210897,-0.347336 z m 2.318771,-2.036931 c -0.433453,-0.250254 -0.58896,-0.792391 -0.347335,-1.210897 0.241624,-0.4185064 0.788882,-0.5549016 1.222335,-0.3046476 0.433453,0.2502536 0.58896,0.7923916 0.347336,1.2108976 -0.241625,0.418506 -0.788883,0.554901 -1.222336,0.304647 z M 14.44,8.36625 c -0.500508,0 -0.90625,-0.3917508 -0.90625,-0.875 0,-0.4832492 0.405742,-0.875 0.90625,-0.875 0.500508,0 0.90625,0.3917508 0.90625,0.875 0,0.4832492 -0.405742,0.875 -0.90625,0.875 z M 13.835351,5.3396697 C 13.401898,5.5899238 12.85464,5.4535286 12.613016,5.0350225 12.371391,4.6165164 12.526898,4.0743793 12.960351,3.8241252 c 0.433453,-0.250254 0.980711,-0.1138588 1.222336,0.3046473 0.241624,0.4185061 0.08612,0.9606432 -0.347336,1.2108972 z M 11.79842,3.0208989 C 11.548166,3.4543516 11.006029,3.609859 10.587523,3.3682344 10.169017,3.1266098 10.032621,2.5793516 10.282875,2.1458989 10.533129,1.7124461 11.075267,1.5569388 11.493773,1.7985634 11.912279,2.040188 12.048674,2.5874462 11.79842,3.0208989 z"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="m 7.875,2.8017767 0,5.25"
+       id="path4436"
+       inkscape:connector-curvature="0" />
+    <path
+       style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
+       d="M 7.7781746,7.4629419 10.783378,7.6397186"
+       id="path4438"
+       inkscape:connector-curvature="0" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer3"
+     inkscape:label="Shine"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <path
+       sodipodi:type="arc"
+       style="fill:url(#radialGradient4440);fill-opacity:1;stroke:none"
+       id="path4353"
+       sodipodi:cx="8.0433397"
+       sodipodi:cy="8.1334372"
+       sodipodi:rx="7.3686199"
+       sodipodi:ry="7.4368792"
+       d="m 15.41196,8.1334372 a 7.3686199,7.4368792 0 1 1 -14.73724019,0 7.3686199,7.4368792 0 1 1 14.73724019,0 z"
+       transform="matrix(0.91562931,0,0,0.91562931,0.64737218,0.56658541)" />
+  </g>
+</svg>
diff --git a/src/qt/res/src/inout.svg b/src/qt/res/src/inout.svg
new file mode 100644 (file)
index 0000000..bfab8ef
--- /dev/null
@@ -0,0 +1,122 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   id="svg3039"
+   version="1.1"
+   inkscape:version="0.48.0 r9654"
+   width="120"
+   height="120"
+   sodipodi:docname="inout3.svg"
+   inkscape:export-filename="/home/orion/projects2/bitcoin/tx_mined.png"
+   inkscape:export-xdpi="12"
+   inkscape:export-ydpi="12"
+   style="display:inline">
+  <metadata
+     id="metadata3045">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title></dc:title>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <defs
+     id="defs3043" />
+  <sodipodi:namedview
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1"
+     objecttolerance="10"
+     gridtolerance="10"
+     guidetolerance="10"
+     inkscape:pageopacity="0"
+     inkscape:pageshadow="2"
+     inkscape:window-width="1920"
+     inkscape:window-height="1127"
+     id="namedview3041"
+     showgrid="false"
+     inkscape:zoom="1"
+     inkscape:cx="87.12655"
+     inkscape:cy="67.287943"
+     inkscape:window-x="0"
+     inkscape:window-y="25"
+     inkscape:window-maximized="1"
+     inkscape:current-layer="layer7" />
+  <g
+     inkscape:groupmode="layer"
+     id="layer2"
+     inkscape:label="base"
+     style="display:none">
+    <path
+       style="font-size:medium;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-indent:0;text-align:start;text-decoration:none;line-height:normal;letter-spacing:normal;word-spacing:normal;text-transform:none;direction:ltr;block-progression:tb;writing-mode:lr-tb;text-anchor:start;baseline-shift:baseline;color:#000000;fill:#afafaf;fill-opacity:1;stroke:none;stroke-width:7;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate;font-family:Sans;-inkscape-font-specification:Sans"
+       d="m 45.375,17 c -13.984022,0.241082 -24.968241,3.28976 -37.4375,9.59375 -8.9920665,21.871558 -6.680947,46.393002 -1.96875,69 26.190925,13.15317 55.594909,12.97748 81.75,-0.21875 3.852144,-9.729509 1.599587,-12.800015 2.375,-23.15625 C 83.917272,72.423868 77.129905,67.688094 74.1875,75.25 72.702487,79.722025 76.119709,82.645519 69.15625,83.34375 53.023957,88.536726 37.721719,89.140031 21.875,82.28125 19.715285,68.367979 18.599566,53.65725 22.5,40 c 16.868164,-6.642068 33.121079,-6.120062 50.03125,-0.15625 1.285344,5.854815 1.574746,5.763255 2.375,11.6875 C 80.46378,51.970623 89.644961,53.334736 91.3125,46 91.85305,36.007959 89.372312,31.625095 87.1875,25.6875 73.709743,21.03478 59.804255,16.698888 45.375,17 z"
+       id="path3053"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="cccccccccccccc" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer3"
+     inkscape:label="arrow_out"
+     style="display:none">
+    <path
+       style="fill:#6e6e6e;fill-opacity:1;stroke:none;display:inline"
+       d="m 63.983409,65.48134 0.267857,-9.514444 36.161424,-0.194173 -7.414458,-8.757971 3.798312,-7.572721 c 0,0 23.437946,20.796656 22.500436,21.185 -0.93751,0.388345 -23.170094,22.73838 -23.170094,22.73838 l -3.128654,-8.931927 7.548388,-8.5638 z"
+       id="path3844"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="cccccscccc" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer4"
+     inkscape:label="arrow_in"
+     style="display:none">
+    <path
+       inkscape:connector-curvature="0"
+       id="path4080"
+       d="m 99.28763,65.48134 -0.26786,-9.514444 -36.161422,-0.194173 7.768009,-6.283097 -4.151865,-9.279828 c 0,0 -23.43795,20.028889 -22.500436,20.417233 0.937514,0.388345 23.170094,20.970613 23.170094,20.970613 l 3.482207,-9.639034 -7.901936,-6.088926 z"
+       style="fill:#6e6e6e;fill-opacity:1;stroke:none;display:inline"
+       sodipodi:nodetypes="cccccscccc" />
+  </g>
+  <g
+     inkscape:groupmode="layer"
+     id="layer7"
+     inkscape:label="mined"
+     style="display:inline">
+    <path
+       style="fill:#a9a9a9;fill-opacity:1;stroke:none;display:inline"
+       d="M 9.4375,99.758169 78.14665,33.110294 73.680556,28.300653 67.153187,8.375 l 18.55147,6.527369 4.80964,3.779003 4.809641,-4.80964 11.680552,12.367647 -6.18382,4.80964 13.74183,14.085377 -12.71119,14.42892 -14.77247,-16.14665 -65.273693,70.770424 z"
+       id="path4103"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="cccccccccccccc" />
+    <path
+       sodipodi:nodetypes="cccccccccccccc"
+       inkscape:connector-curvature="0"
+       id="path4619"
+       d="M 114.5625,99.758169 45.85335,33.110294 50.319444,28.300653 56.846813,8.375 l -18.55147,6.527369 -4.80964,3.779003 -4.809641,-4.80964 -11.680556,12.367647 6.183825,4.80964 L 9.4375,45.134396 22.148693,59.563316 36.92116,43.416666 102.19485,114.18709 z"
+       style="fill:#a9a9a9;fill-opacity:1;stroke:none;display:inline" />
+    <path
+       style="fill:#6e6e6e;fill-opacity:1;stroke:none"
+       d="M 10.960155,44.693128 38.53732,16.408856 54.093669,10.752002 48.436815,28.076118 22.273864,56.713943 z"
+       id="path5256"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="cccccc" />
+    <path
+       style="fill:#6e6e6e;fill-opacity:1;stroke:none"
+       d="M 69.296465,10.398449 85.559921,17.115963 111.72287,45.046681 102.17693,56.713943 74.953319,27.722565 z"
+       id="path5258"
+       inkscape:connector-curvature="0"
+       sodipodi:nodetypes="cccccc" />
+  </g>
+</svg>
diff --git a/src/qt/res/src/questionmark.svg b/src/qt/res/src/questionmark.svg
new file mode 100644 (file)
index 0000000..c03c159
--- /dev/null
@@ -0,0 +1,159 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:xlink="http://www.w3.org/1999/xlink"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="16px"
+   height="16px"
+   id="svg2993"
+   version="1.1"
+   inkscape:version="0.48.0 r9654"
+   sodipodi:docname="questionmark.svg"
+   inkscape:export-filename="/store/orion/projects/bitcoin/questionmark.png"
+   inkscape:export-xdpi="90"
+   inkscape:export-ydpi="90">
+  <defs
+     id="defs2995">
+    <linearGradient
+       id="linearGradient3808">
+      <stop
+         style="stop-color:#c8c8c8;stop-opacity:1;"
+         offset="0"
+         id="stop3810" />
+      <stop
+         style="stop-color:#959595;stop-opacity:1"
+         offset="1"
+         id="stop3812" />
+    </linearGradient>
+    <filter
+       inkscape:collect="always"
+       id="filter3804"
+       x="-0.2510722"
+       width="1.5021444"
+       y="-0.13164773"
+       height="1.2632955">
+      <feGaussianBlur
+         inkscape:collect="always"
+         stdDeviation="0.73280473"
+         id="feGaussianBlur3806" />
+    </filter>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3808"
+       id="linearGradient3844"
+       x1="8.4916801"
+       y1="1.4395804"
+       x2="8.6022711"
+       y2="14.211697"
+       gradientUnits="userSpaceOnUse" />
+    <filter
+       inkscape:collect="always"
+       id="filter3889"
+       x="-0.13954329"
+       width="1.2790866"
+       y="-0.073168421"
+       height="1.1463368">
+      <feGaussianBlur
+         inkscape:collect="always"
+         stdDeviation="0.40728516"
+         id="feGaussianBlur3891" />
+    </filter>
+    <filter
+       inkscape:collect="always"
+       id="filter3897"
+       x="-0.17178624"
+       width="1.3435725"
+       y="-0.090074761"
+       height="1.1801495">
+      <feGaussianBlur
+         inkscape:collect="always"
+         stdDeviation="0.50139271"
+         id="feGaussianBlur3899" />
+    </filter>
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="1"
+     inkscape:cx="10.789648"
+     inkscape:cy="7.6382159"
+     inkscape:current-layer="layer2"
+     showgrid="true"
+     inkscape:grid-bbox="true"
+     inkscape:document-units="px"
+     inkscape:window-width="1920"
+     inkscape:window-height="1127"
+     inkscape:window-x="0"
+     inkscape:window-y="25"
+     inkscape:window-maximized="1" />
+  <metadata
+     id="metadata2998">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title></dc:title>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     inkscape:groupmode="layer"
+     id="layer2"
+     inkscape:label="Below"
+     style="display:inline">
+    <text
+       sodipodi:linespacing="125%"
+       id="text3006"
+       y="14.748394"
+       x="4.1060953"
+       style="font-size:18px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans;filter:url(#filter3897)"
+       xml:space="preserve"><tspan
+         y="14.748394"
+         x="4.1060953"
+         id="tspan3008"
+         sodipodi:role="line">?</tspan></text>
+    <text
+       xml:space="preserve"
+       style="font-size:18px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans;filter:url(#filter3889)"
+       x="4.1060953"
+       y="14.748394"
+       id="text3824"
+       sodipodi:linespacing="125%"><tspan
+         sodipodi:role="line"
+         id="tspan3826"
+         x="4.1060953"
+         y="14.748394">?</tspan></text>
+  </g>
+  <g
+     id="layer1"
+     inkscape:label="QuestionMark"
+     inkscape:groupmode="layer"
+     style="display:inline"
+     sodipodi:insensitive="true">
+    <text
+       xml:space="preserve"
+       style="font-size:18px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:url(#linearGradient3844);fill-opacity:1;stroke:none;font-family:Sans"
+       x="4.1060953"
+       y="14.748394"
+       id="text3001"
+       sodipodi:linespacing="125%"><tspan
+         sodipodi:role="line"
+         id="tspan3003"
+         x="4.1060953"
+         y="14.748394"
+         style="fill:url(#linearGradient3844);fill-opacity:1">?</tspan></text>
+  </g>
+</svg>
diff --git a/src/qt/sendcoinsdialog.cpp b/src/qt/sendcoinsdialog.cpp
new file mode 100644 (file)
index 0000000..852d789
--- /dev/null
@@ -0,0 +1,243 @@
+#include "sendcoinsdialog.h"
+#include "ui_sendcoinsdialog.h"
+#include "walletmodel.h"
+#include "bitcoinunits.h"
+#include "addressbookpage.h"
+#include "optionsmodel.h"
+#include "sendcoinsentry.h"
+#include "guiutil.h"
+#include "askpassphrasedialog.h"
+
+#include <QMessageBox>
+#include <QLocale>
+#include <QTextDocument>
+
+SendCoinsDialog::SendCoinsDialog(QWidget *parent) :
+    QDialog(parent),
+    ui(new Ui::SendCoinsDialog),
+    model(0)
+{
+    ui->setupUi(this);
+
+    addEntry();
+
+    connect(ui->addButton, SIGNAL(clicked()), this, SLOT(addEntry()));
+}
+
+void SendCoinsDialog::setModel(WalletModel *model)
+{
+    this->model = model;
+
+    for(int i = 0; i < ui->entries->count(); ++i)
+    {
+        SendCoinsEntry *entry = qobject_cast<SendCoinsEntry*>(ui->entries->itemAt(i)->widget());
+        if(entry)
+        {
+            entry->setModel(model);
+        }
+    }
+}
+
+SendCoinsDialog::~SendCoinsDialog()
+{
+    delete ui;
+}
+
+void SendCoinsDialog::on_sendButton_clicked()
+{
+    QList<SendCoinsRecipient> recipients;
+    bool valid = true;
+    for(int i = 0; i < ui->entries->count(); ++i)
+    {
+        SendCoinsEntry *entry = qobject_cast<SendCoinsEntry*>(ui->entries->itemAt(i)->widget());
+        if(entry)
+        {
+            if(entry->validate())
+            {
+                recipients.append(entry->getValue());
+            }
+            else
+            {
+                valid = false;
+            }
+        }
+    }
+
+    if(!valid || recipients.isEmpty())
+    {
+        return;
+    }
+
+    // Format confirmation message
+    QStringList formatted;
+    foreach(const SendCoinsRecipient &rcp, recipients)
+    {
+        formatted.append(tr("<b>%1</b> to %2 (%3)").arg(BitcoinUnits::formatWithUnit(BitcoinUnits::BTC, rcp.amount), Qt::escape(rcp.label), rcp.address));
+    }
+
+    QMessageBox::StandardButton retval = QMessageBox::question(this, tr("Confirm send coins"),
+                          tr("Are you sure you want to send %1?").arg(formatted.join(tr(" and "))),
+          QMessageBox::Yes|QMessageBox::Cancel,
+          QMessageBox::Cancel);
+
+    if(retval != QMessageBox::Yes)
+    {
+        return;
+    }
+
+    WalletModel::UnlockContext ctx(model->requestUnlock());
+    if(!ctx.isValid())
+    {
+        // Unlock wallet was cancelled
+        return;
+    }
+
+    WalletModel::SendCoinsReturn sendstatus = model->sendCoins(recipients);
+    switch(sendstatus.status)
+    {
+    case WalletModel::InvalidAddress:
+        QMessageBox::warning(this, tr("Send Coins"),
+            tr("The recepient address is not valid, please recheck."),
+            QMessageBox::Ok, QMessageBox::Ok);
+        break;
+    case WalletModel::InvalidAmount:
+        QMessageBox::warning(this, tr("Send Coins"),
+            tr("The amount to pay must be larger than 0."),
+            QMessageBox::Ok, QMessageBox::Ok);
+        break;
+    case WalletModel::AmountExceedsBalance:
+        QMessageBox::warning(this, tr("Send Coins"),
+            tr("Amount exceeds your balance"),
+            QMessageBox::Ok, QMessageBox::Ok);
+        break;
+    case WalletModel::AmountWithFeeExceedsBalance:
+        QMessageBox::warning(this, tr("Send Coins"),
+            tr("Total exceeds your balance when the %1 transaction fee is included").
+            arg(BitcoinUnits::formatWithUnit(BitcoinUnits::BTC, sendstatus.fee)),
+            QMessageBox::Ok, QMessageBox::Ok);
+        break;
+    case WalletModel::DuplicateAddress:
+        QMessageBox::warning(this, tr("Send Coins"),
+            tr("Duplicate address found, can only send to each address once in one send operation"),
+            QMessageBox::Ok, QMessageBox::Ok);
+        break;
+    case WalletModel::TransactionCreationFailed:
+        QMessageBox::warning(this, tr("Send Coins"),
+            tr("Error: Transaction creation failed  "),
+            QMessageBox::Ok, QMessageBox::Ok);
+        break;
+    case WalletModel::TransactionCommitFailed:
+        QMessageBox::warning(this, tr("Send Coins"),
+            tr("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."),
+            QMessageBox::Ok, QMessageBox::Ok);
+        break;
+    case WalletModel::OK:
+        accept();
+        break;
+    }
+}
+
+void SendCoinsDialog::clear()
+{
+    // Remove entries until only one left
+    while(ui->entries->count())
+    {
+        delete ui->entries->takeAt(0)->widget();
+    }
+    addEntry();
+
+    updateRemoveEnabled();
+
+    ui->sendButton->setDefault(true);
+}
+
+void SendCoinsDialog::reject()
+{
+    clear();
+}
+
+void SendCoinsDialog::accept()
+{
+    clear();
+}
+
+SendCoinsEntry *SendCoinsDialog::addEntry()
+{
+    SendCoinsEntry *entry = new SendCoinsEntry(this);
+    entry->setModel(model);
+    ui->entries->addWidget(entry);
+    connect(entry, SIGNAL(removeEntry(SendCoinsEntry*)), this, SLOT(removeEntry(SendCoinsEntry*)));
+
+    updateRemoveEnabled();
+
+    // Focus the field, so that entry can start immediately
+    entry->clear();
+    return entry;
+}
+
+void SendCoinsDialog::updateRemoveEnabled()
+{
+    // Remove buttons are enabled as soon as there is more than one send-entry
+    bool enabled = (ui->entries->count() > 1);
+    for(int i = 0; i < ui->entries->count(); ++i)
+    {
+        SendCoinsEntry *entry = qobject_cast<SendCoinsEntry*>(ui->entries->itemAt(i)->widget());
+        if(entry)
+        {
+            entry->setRemoveEnabled(enabled);
+        }
+    }
+    setupTabChain(0);
+}
+
+void SendCoinsDialog::removeEntry(SendCoinsEntry* entry)
+{
+    delete entry;
+    updateRemoveEnabled();
+}
+
+QWidget *SendCoinsDialog::setupTabChain(QWidget *prev)
+{
+    for(int i = 0; i < ui->entries->count(); ++i)
+    {
+        SendCoinsEntry *entry = qobject_cast<SendCoinsEntry*>(ui->entries->itemAt(i)->widget());
+        if(entry)
+        {
+            prev = entry->setupTabChain(prev);
+        }
+    }
+    QWidget::setTabOrder(prev, ui->addButton);
+    QWidget::setTabOrder(ui->addButton, ui->sendButton);
+    return ui->sendButton;
+}
+
+void SendCoinsDialog::pasteEntry(const SendCoinsRecipient &rv)
+{
+    SendCoinsEntry *entry = 0;
+    // Replace the first entry if it is still unused
+    if(ui->entries->count() == 1)
+    {
+        SendCoinsEntry *first = qobject_cast<SendCoinsEntry*>(ui->entries->itemAt(0)->widget());
+        if(first->isClear())
+        {
+            entry = first;
+        }
+    }
+    if(!entry)
+    {
+        entry = addEntry();
+    }
+
+    entry->setValue(rv);
+}
+
+
+void SendCoinsDialog::handleURL(const QUrl *url)
+{
+    SendCoinsRecipient rv;
+    if(!GUIUtil::parseBitcoinURL(url, &rv))
+    {
+        return;
+    }
+    pasteEntry(rv);
+}
diff --git a/src/qt/sendcoinsdialog.h b/src/qt/sendcoinsdialog.h
new file mode 100644 (file)
index 0000000..9c56e51
--- /dev/null
@@ -0,0 +1,51 @@
+#ifndef SENDCOINSDIALOG_H
+#define SENDCOINSDIALOG_H
+
+#include <QDialog>
+
+namespace Ui {
+    class SendCoinsDialog;
+}
+class WalletModel;
+class SendCoinsEntry;
+class SendCoinsRecipient;
+
+QT_BEGIN_NAMESPACE
+class QUrl;
+QT_END_NAMESPACE
+
+class SendCoinsDialog : public QDialog
+{
+    Q_OBJECT
+
+public:
+    explicit SendCoinsDialog(QWidget *parent = 0);
+    ~SendCoinsDialog();
+
+    void setModel(WalletModel *model);
+
+    // Qt messes up the tab chain by default in some cases (issue http://bugreports.qt.nokia.com/browse/QTBUG-10907)
+    // Hence we have to set it up manually
+    QWidget *setupTabChain(QWidget *prev);
+
+    void pasteEntry(const SendCoinsRecipient &rv);
+    void handleURL(const QUrl *url);
+
+public slots:
+    void clear();
+    void reject();
+    void accept();
+    SendCoinsEntry *addEntry();
+    void updateRemoveEnabled();
+
+private:
+    Ui::SendCoinsDialog *ui;
+    WalletModel *model;
+
+private slots:
+    void on_sendButton_clicked();
+
+    void removeEntry(SendCoinsEntry* entry);
+};
+
+#endif // SENDCOINSDIALOG_H
diff --git a/src/qt/sendcoinsentry.cpp b/src/qt/sendcoinsentry.cpp
new file mode 100644 (file)
index 0000000..fccef23
--- /dev/null
@@ -0,0 +1,145 @@
+#include "sendcoinsentry.h"
+#include "ui_sendcoinsentry.h"
+#include "guiutil.h"
+#include "bitcoinunits.h"
+#include "addressbookpage.h"
+#include "walletmodel.h"
+#include "optionsmodel.h"
+#include "addresstablemodel.h"
+
+#include <QApplication>
+#include <QClipboard>
+
+SendCoinsEntry::SendCoinsEntry(QWidget *parent) :
+    QFrame(parent),
+    ui(new Ui::SendCoinsEntry),
+    model(0)
+{
+    ui->setupUi(this);
+
+#if QT_VERSION >= 0x040700
+    ui->payTo->setPlaceholderText(tr("Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"));
+    ui->addAsLabel->setPlaceholderText(tr("Enter a label for this address to add it to your address book"));
+#endif
+    setFocusPolicy(Qt::TabFocus);
+    setFocusProxy(ui->payTo);
+
+    GUIUtil::setupAddressWidget(ui->payTo, this);
+}
+
+SendCoinsEntry::~SendCoinsEntry()
+{
+    delete ui;
+}
+
+void SendCoinsEntry::on_pasteButton_clicked()
+{
+    // Paste text from clipboard into recipient field
+    ui->payTo->setText(QApplication::clipboard()->text());
+}
+
+void SendCoinsEntry::on_addressBookButton_clicked()
+{
+    AddressBookPage dlg(AddressBookPage::ForSending, AddressBookPage::SendingTab, this);
+    dlg.setModel(model->getAddressTableModel());
+    if(dlg.exec())
+    {
+        ui->payTo->setText(dlg.getReturnValue());
+        ui->payAmount->setFocus();
+    }
+}
+
+void SendCoinsEntry::on_payTo_textChanged(const QString &address)
+{
+    ui->addAsLabel->setText(model->getAddressTableModel()->labelForAddress(address));
+}
+
+void SendCoinsEntry::setModel(WalletModel *model)
+{
+    this->model = model;
+}
+
+void SendCoinsEntry::setRemoveEnabled(bool enabled)
+{
+    ui->deleteButton->setEnabled(enabled);
+}
+
+void SendCoinsEntry::clear()
+{
+    ui->payTo->clear();
+    ui->addAsLabel->clear();
+    ui->payAmount->clear();
+    ui->payTo->setFocus();
+    if(model)
+    {
+        ui->payAmount->setDisplayUnit(model->getOptionsModel()->getDisplayUnit());
+    }
+}
+
+void SendCoinsEntry::on_deleteButton_clicked()
+{
+    emit removeEntry(this);
+}
+
+bool SendCoinsEntry::validate()
+{
+    // Check input validity
+    bool retval = true;
+
+    if(!ui->payAmount->validate())
+    {
+        retval = false;
+    }
+    else
+    {
+        if(ui->payAmount->value() <= 0)
+        {
+            // Cannot send 0 coins or less
+            ui->payAmount->setValid(false);
+            retval = false;
+        }
+    }
+
+    if(!ui->payTo->hasAcceptableInput() ||
+       (model && !model->validateAddress(ui->payTo->text())))
+    {
+        ui->payTo->setValid(false);
+        retval = false;
+    }
+
+    return retval;
+}
+
+SendCoinsRecipient SendCoinsEntry::getValue()
+{
+    SendCoinsRecipient rv;
+
+    rv.address = ui->payTo->text();
+    rv.label = ui->addAsLabel->text();
+    rv.amount = ui->payAmount->value();
+
+    return rv;
+}
+
+QWidget *SendCoinsEntry::setupTabChain(QWidget *prev)
+{
+    QWidget::setTabOrder(prev, ui->payTo);
+    QWidget::setTabOrder(ui->payTo, ui->addressBookButton);
+    QWidget::setTabOrder(ui->addressBookButton, ui->pasteButton);
+    QWidget::setTabOrder(ui->pasteButton, ui->deleteButton);
+    QWidget::setTabOrder(ui->deleteButton, ui->addAsLabel);
+    return ui->payAmount->setupTabChain(ui->addAsLabel);
+}
+
+void SendCoinsEntry::setValue(const SendCoinsRecipient &value)
+{
+    ui->payTo->setText(value.address);
+    ui->addAsLabel->setText(value.label);
+    ui->payAmount->setValue(value.amount);
+}
+
+bool SendCoinsEntry::isClear()
+{
+    return ui->payTo->text().isEmpty();
+}
+
diff --git a/src/qt/sendcoinsentry.h b/src/qt/sendcoinsentry.h
new file mode 100644 (file)
index 0000000..ccc223b
--- /dev/null
@@ -0,0 +1,51 @@
+#ifndef SENDCOINSENTRY_H
+#define SENDCOINSENTRY_H
+
+#include <QFrame>
+
+namespace Ui {
+    class SendCoinsEntry;
+}
+class WalletModel;
+class SendCoinsRecipient;
+
+class SendCoinsEntry : public QFrame
+{
+    Q_OBJECT
+
+public:
+    explicit SendCoinsEntry(QWidget *parent = 0);
+    ~SendCoinsEntry();
+
+    void setModel(WalletModel *model);
+    bool validate();
+    SendCoinsRecipient getValue();
+
+    // Return true if the entry is still empty and unedited
+    bool isClear();
+
+    void setValue(const SendCoinsRecipient &value);
+
+    // Qt messes up the tab chain by default in some cases (issue http://bugreports.qt.nokia.com/browse/QTBUG-10907)
+    // Hence we have to set it up manually
+    QWidget *setupTabChain(QWidget *prev);
+
+public slots:
+    void setRemoveEnabled(bool enabled);
+    void clear();
+
+signals:
+    void removeEntry(SendCoinsEntry *entry);
+
+private slots:
+    void on_deleteButton_clicked();
+    void on_payTo_textChanged(const QString &address);
+    void on_addressBookButton_clicked();
+    void on_pasteButton_clicked();
+
+private:
+    Ui::SendCoinsEntry *ui;
+    WalletModel *model;
+};
+
+#endif // SENDCOINSENTRY_H
diff --git a/src/qt/transactiondesc.cpp b/src/qt/transactiondesc.cpp
new file mode 100644 (file)
index 0000000..6ca3ac8
--- /dev/null
@@ -0,0 +1,292 @@
+#include <transactiondesc.h>
+
+#include "guiutil.h"
+#include "bitcoinunits.h"
+
+#include "headers.h"
+#include "qtui.h"
+
+#include <QString>
+#include <QTextDocument> // For Qt::escape
+
+using namespace std;
+
+QString TransactionDesc::HtmlEscape(const QString& str, bool fMultiLine)
+{
+    QString escaped = Qt::escape(str);
+    if(fMultiLine)
+    {
+        escaped = escaped.replace("\n", "<br>\n");
+    }
+    return escaped;
+}
+
+QString TransactionDesc::HtmlEscape(const std::string& str, bool fMultiLine)
+{
+    return HtmlEscape(QString::fromStdString(str), fMultiLine);
+}
+
+QString TransactionDesc::FormatTxStatus(const CWalletTx& wtx)
+{
+    if (!wtx.IsFinal())
+    {
+        if (wtx.nLockTime < LOCKTIME_THRESHOLD)
+            return tr("Open for %1 blocks").arg(nBestHeight - wtx.nLockTime);
+        else
+            return tr("Open until %1").arg(GUIUtil::dateTimeStr(wtx.nLockTime));
+    }
+    else
+    {
+        int nDepth = wtx.GetDepthInMainChain();
+        if (GetAdjustedTime() - wtx.nTimeReceived > 2 * 60 && wtx.GetRequestCount() == 0)
+            return tr("%1/offline?").arg(nDepth);
+        else if (nDepth < 6)
+            return tr("%1/unconfirmed").arg(nDepth);
+        else
+            return tr("%1 confirmations").arg(nDepth);
+    }
+}
+
+QString TransactionDesc::toHTML(CWallet *wallet, CWalletTx &wtx)
+{
+    QString strHTML;
+    CRITICAL_BLOCK(wallet->cs_wallet)
+    {
+        strHTML.reserve(4000);
+        strHTML += "<html><font face='verdana, arial, helvetica, sans-serif'>";
+
+        int64 nTime = wtx.GetTxTime();
+        int64 nCredit = wtx.GetCredit();
+        int64 nDebit = wtx.GetDebit();
+        int64 nNet = nCredit - nDebit;
+
+        strHTML += tr("<b>Status:</b> ") + FormatTxStatus(wtx);
+        int nRequests = wtx.GetRequestCount();
+        if (nRequests != -1)
+        {
+            if (nRequests == 0)
+                strHTML += tr(", has not been successfully broadcast yet");
+            else if (nRequests == 1)
+                strHTML += tr(", broadcast through %1 node").arg(nRequests);
+            else
+                strHTML += tr(", broadcast through %1 nodes").arg(nRequests);
+        }
+        strHTML += "<br>";
+
+        strHTML += tr("<b>Date:</b> ") + (nTime ? GUIUtil::dateTimeStr(nTime) : QString("")) + "<br>";
+
+        //
+        // From
+        //
+        if (wtx.IsCoinBase())
+        {
+            strHTML += tr("<b>Source:</b> Generated<br>");
+        }
+        else if (!wtx.mapValue["from"].empty())
+        {
+            // Online transaction
+            if (!wtx.mapValue["from"].empty())
+                strHTML += tr("<b>From:</b> ") + HtmlEscape(wtx.mapValue["from"]) + "<br>";
+        }
+        else
+        {
+            // Offline transaction
+            if (nNet > 0)
+            {
+                // Credit
+                BOOST_FOREACH(const CTxOut& txout, wtx.vout)
+                {
+                    if (wallet->IsMine(txout))
+                    {
+                        CBitcoinAddress address;
+                        if (ExtractAddress(txout.scriptPubKey, wallet, address))
+                        {
+                            if (wallet->mapAddressBook.count(address))
+                            {
+                                strHTML += tr("<b>From:</b> ") + tr("unknown") + "<br>";
+                                strHTML += tr("<b>To:</b> ");
+                                strHTML += HtmlEscape(address.ToString());
+                                if (!wallet->mapAddressBook[address].empty())
+                                    strHTML += tr(" (yours, label: ") + HtmlEscape(wallet->mapAddressBook[address]) + ")";
+                                else
+                                    strHTML += tr(" (yours)");
+                                strHTML += "<br>";
+                            }
+                        }
+                        break;
+                    }
+                }
+            }
+        }
+
+        //
+        // To
+        //
+        string strAddress;
+        if (!wtx.mapValue["to"].empty())
+        {
+            // Online transaction
+            strAddress = wtx.mapValue["to"];
+            strHTML += tr("<b>To:</b> ");
+            if (wallet->mapAddressBook.count(strAddress) && !wallet->mapAddressBook[strAddress].empty())
+                strHTML += HtmlEscape(wallet->mapAddressBook[strAddress]) + " ";
+            strHTML += HtmlEscape(strAddress) + "<br>";
+        }
+
+        //
+        // Amount
+        //
+        if (wtx.IsCoinBase() && nCredit == 0)
+        {
+            //
+            // Coinbase
+            //
+            int64 nUnmatured = 0;
+            BOOST_FOREACH(const CTxOut& txout, wtx.vout)
+                nUnmatured += wallet->GetCredit(txout);
+            strHTML += tr("<b>Credit:</b> ");
+            if (wtx.IsInMainChain())
+                strHTML += tr("(%1 matures in %2 more blocks)")
+                        .arg(BitcoinUnits::formatWithUnit(BitcoinUnits::BTC, nUnmatured))
+                        .arg(wtx.GetBlocksToMaturity());
+            else
+                strHTML += tr("(not accepted)");
+            strHTML += "<br>";
+        }
+        else if (nNet > 0)
+        {
+            //
+            // Credit
+            //
+            strHTML += tr("<b>Credit:</b> ") + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC, nNet) + "<br>";
+        }
+        else
+        {
+            bool fAllFromMe = true;
+            BOOST_FOREACH(const CTxIn& txin, wtx.vin)
+                fAllFromMe = fAllFromMe && wallet->IsMine(txin);
+
+            bool fAllToMe = true;
+            BOOST_FOREACH(const CTxOut& txout, wtx.vout)
+                fAllToMe = fAllToMe && wallet->IsMine(txout);
+
+            if (fAllFromMe)
+            {
+                //
+                // Debit
+                //
+                BOOST_FOREACH(const CTxOut& txout, wtx.vout)
+                {
+                    if (wallet->IsMine(txout))
+                        continue;
+
+                    if (wtx.mapValue["to"].empty())
+                    {
+                        // Offline transaction
+                        CBitcoinAddress address;
+                        if (ExtractAddress(txout.scriptPubKey, 0, address))
+                        {
+                            strHTML += tr("<b>To:</b> ");
+                            if (wallet->mapAddressBook.count(address) && !wallet->mapAddressBook[address].empty())
+                                strHTML += HtmlEscape(wallet->mapAddressBook[address]) + " ";
+                            strHTML += HtmlEscape(address.ToString());
+                            strHTML += "<br>";
+                        }
+                    }
+
+                    strHTML += tr("<b>Debit:</b> ") + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC, -txout.nValue) + "<br>";
+                }
+
+                if (fAllToMe)
+                {
+                    // Payment to self
+                    int64 nChange = wtx.GetChange();
+                    int64 nValue = nCredit - nChange;
+                    strHTML += tr("<b>Debit:</b> ") + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC, -nValue) + "<br>";
+                    strHTML += tr("<b>Credit:</b> ") + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC, nValue) + "<br>";
+                }
+
+                int64 nTxFee = nDebit - wtx.GetValueOut();
+                if (nTxFee > 0)
+                    strHTML += tr("<b>Transaction fee:</b> ") + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC,-nTxFee) + "<br>";
+            }
+            else
+            {
+                //
+                // Mixed debit transaction
+                //
+                BOOST_FOREACH(const CTxIn& txin, wtx.vin)
+                    if (wallet->IsMine(txin))
+                        strHTML += tr("<b>Debit:</b> ") + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC,-wallet->GetDebit(txin)) + "<br>";
+                BOOST_FOREACH(const CTxOut& txout, wtx.vout)
+                    if (wallet->IsMine(txout))
+                        strHTML += tr("<b>Credit:</b> ") + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC,wallet->GetCredit(txout)) + "<br>";
+            }
+        }
+
+        strHTML += tr("<b>Net amount:</b> ") + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC,nNet, true) + "<br>";
+
+        //
+        // Message
+        //
+        if (!wtx.mapValue["message"].empty())
+            strHTML += QString("<br><b>") + tr("Message:") + "</b><br>" + HtmlEscape(wtx.mapValue["message"], true) + "<br>";
+        if (!wtx.mapValue["comment"].empty())
+            strHTML += QString("<br><b>") + tr("Comment:") + "</b><br>" + HtmlEscape(wtx.mapValue["comment"], true) + "<br>";
+
+        if (wtx.IsCoinBase())
+            strHTML += QString("<br>") + tr("Generated coins must wait 120 blocks before they can be spent.  When you generated this block, it was broadcast to the network to be added to the block chain.  If it fails to get into the chain, it will change to \"not accepted\" and not be spendable.  This may occasionally happen if another node generates a block within a few seconds of yours.") + "<br>";
+
+        //
+        // Debug view
+        //
+        if (fDebug)
+        {
+            strHTML += "<hr><br>Debug information<br><br>";
+            BOOST_FOREACH(const CTxIn& txin, wtx.vin)
+                if(wallet->IsMine(txin))
+                    strHTML += "<b>Debit:</b> " + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC,-wallet->GetDebit(txin)) + "<br>";
+            BOOST_FOREACH(const CTxOut& txout, wtx.vout)
+                if(wallet->IsMine(txout))
+                    strHTML += "<b>Credit:</b> " + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC,wallet->GetCredit(txout)) + "<br>";
+
+            strHTML += "<br><b>Transaction:</b><br>";
+            strHTML += HtmlEscape(wtx.ToString(), true);
+
+            CTxDB txdb("r"); // To fetch source txouts
+
+            strHTML += "<br><b>Inputs:</b>";
+            strHTML += "<ul>";
+            CRITICAL_BLOCK(wallet->cs_wallet)
+            {
+                BOOST_FOREACH(const CTxIn& txin, wtx.vin)
+                {
+                    COutPoint prevout = txin.prevout;
+
+                    CTransaction prev;
+                    if(txdb.ReadDiskTx(prevout.hash, prev))
+                    {
+                        if (prevout.n < prev.vout.size())
+                        {
+                            strHTML += "<li>";
+                            const CTxOut &vout = prev.vout[prevout.n];
+                            CBitcoinAddress address;
+                            if (ExtractAddress(vout.scriptPubKey, 0, address))
+                            {
+                                if (wallet->mapAddressBook.count(address) && !wallet->mapAddressBook[address].empty())
+                                    strHTML += HtmlEscape(wallet->mapAddressBook[address]) + " ";
+                                strHTML += QString::fromStdString(address.ToString());
+                            }
+                            strHTML = strHTML + " Amount=" + BitcoinUnits::formatWithUnit(BitcoinUnits::BTC,vout.nValue);
+                            strHTML = strHTML + " IsMine=" + (wallet->IsMine(vout) ? "true" : "false") + "</li>";
+                        }
+                    }
+                }
+            }
+            strHTML += "</ul>";
+        }
+
+        strHTML += "</font></html>";
+    }
+    return strHTML;
+}
diff --git a/src/qt/transactiondesc.h b/src/qt/transactiondesc.h
new file mode 100644 (file)
index 0000000..257b2cb
--- /dev/null
@@ -0,0 +1,24 @@
+#ifndef TRANSACTIONDESC_H
+#define TRANSACTIONDESC_H
+
+#include <QString>
+#include <QObject>
+#include <string>
+
+class CWallet;
+class CWalletTx;
+
+class TransactionDesc: public QObject
+{
+public:
+    // Provide human-readable extended HTML description of a transaction
+    static QString toHTML(CWallet *wallet, CWalletTx &wtx);
+private:
+    TransactionDesc() {}
+
+    static QString HtmlEscape(const QString& str, bool fMultiLine=false);
+    static QString HtmlEscape(const std::string &str, bool fMultiLine=false);
+    static QString FormatTxStatus(const CWalletTx& wtx);
+};
+
+#endif // TRANSACTIONDESC_H
diff --git a/src/qt/transactiondescdialog.cpp b/src/qt/transactiondescdialog.cpp
new file mode 100644 (file)
index 0000000..3bd4808
--- /dev/null
@@ -0,0 +1,20 @@
+#include "transactiondescdialog.h"
+#include "ui_transactiondescdialog.h"
+
+#include "transactiontablemodel.h"
+
+#include <QModelIndex>
+
+TransactionDescDialog::TransactionDescDialog(const QModelIndex &idx, QWidget *parent) :
+    QDialog(parent),
+    ui(new Ui::TransactionDescDialog)
+{
+    ui->setupUi(this);
+    QString desc = idx.data(TransactionTableModel::LongDescriptionRole).toString();
+    ui->detailText->setHtml(desc);
+}
+
+TransactionDescDialog::~TransactionDescDialog()
+{
+    delete ui;
+}
diff --git a/src/qt/transactiondescdialog.h b/src/qt/transactiondescdialog.h
new file mode 100644 (file)
index 0000000..4f8f754
--- /dev/null
@@ -0,0 +1,25 @@
+#ifndef TRANSACTIONDESCDIALOG_H
+#define TRANSACTIONDESCDIALOG_H
+
+#include <QDialog>
+
+namespace Ui {
+    class TransactionDescDialog;
+}
+QT_BEGIN_NAMESPACE
+class QModelIndex;
+QT_END_NAMESPACE
+
+class TransactionDescDialog : public QDialog
+{
+    Q_OBJECT
+
+public:
+    explicit TransactionDescDialog(const QModelIndex &idx, QWidget *parent = 0);
+    ~TransactionDescDialog();
+
+private:
+    Ui::TransactionDescDialog *ui;
+};
+
+#endif // TRANSACTIONDESCDIALOG_H
diff --git a/src/qt/transactionfilterproxy.cpp b/src/qt/transactionfilterproxy.cpp
new file mode 100644 (file)
index 0000000..a4c5b37
--- /dev/null
@@ -0,0 +1,86 @@
+#include "transactionfilterproxy.h"
+#include "transactiontablemodel.h"
+
+#include <QDateTime>
+
+#include <cstdlib>
+
+// Earliest date that can be represented (far in the past)
+const QDateTime TransactionFilterProxy::MIN_DATE = QDateTime::fromTime_t(0);
+// Last date that can be represented (far in the future)
+const QDateTime TransactionFilterProxy::MAX_DATE = QDateTime::fromTime_t(0xFFFFFFFF);
+
+TransactionFilterProxy::TransactionFilterProxy(QObject *parent) :
+    QSortFilterProxyModel(parent),
+    dateFrom(MIN_DATE),
+    dateTo(MAX_DATE),
+    addrPrefix(),
+    typeFilter(ALL_TYPES),
+    minAmount(0),
+    limitRows(-1)
+{
+}
+
+bool TransactionFilterProxy::filterAcceptsRow(int sourceRow, const QModelIndex &sourceParent) const
+{
+    QModelIndex index = sourceModel()->index(sourceRow, 0, sourceParent);
+
+    int type = index.data(TransactionTableModel::TypeRole).toInt();
+    QDateTime datetime = index.data(TransactionTableModel::DateRole).toDateTime();
+    QString address = index.data(TransactionTableModel::AddressRole).toString();
+    QString label = index.data(TransactionTableModel::LabelRole).toString();
+    qint64 amount = llabs(index.data(TransactionTableModel::AmountRole).toLongLong());
+
+    if(!(TYPE(type) & typeFilter))
+        return false;
+    if(datetime < dateFrom || datetime > dateTo)
+        return false;
+    if(!address.startsWith(addrPrefix) && !label.startsWith(addrPrefix))
+        return false;
+    if(amount < minAmount)
+        return false;
+
+    return true;
+}
+
+void TransactionFilterProxy::setDateRange(const QDateTime &from, const QDateTime &to)
+{
+    this->dateFrom = from;
+    this->dateTo = to;
+    invalidateFilter();
+}
+
+void TransactionFilterProxy::setAddressPrefix(const QString &addrPrefix)
+{
+    this->addrPrefix = addrPrefix;
+    invalidateFilter();
+}
+
+void TransactionFilterProxy::setTypeFilter(quint32 modes)
+{
+    this->typeFilter = modes;
+    invalidateFilter();
+}
+
+void TransactionFilterProxy::setMinAmount(qint64 minimum)
+{
+    this->minAmount = minimum;
+    invalidateFilter();
+}
+
+void TransactionFilterProxy::setLimit(int limit)
+{
+    this->limitRows = limit;
+}
+
+int TransactionFilterProxy::rowCount(const QModelIndex &parent) const
+{
+    if(limitRows != -1)
+    {
+        return std::min(QSortFilterProxyModel::rowCount(parent), limitRows);
+    }
+    else
+    {
+        return QSortFilterProxyModel::rowCount(parent);
+    }
+}
diff --git a/src/qt/transactionfilterproxy.h b/src/qt/transactionfilterproxy.h
new file mode 100644 (file)
index 0000000..4dd2a8e
--- /dev/null
@@ -0,0 +1,50 @@
+#ifndef TRANSACTIONFILTERPROXY_H
+#define TRANSACTIONFILTERPROXY_H
+
+#include <QSortFilterProxyModel>
+#include <QDateTime>
+
+// Filter transaction list according to pre-specified rules
+class TransactionFilterProxy : public QSortFilterProxyModel
+{
+    Q_OBJECT
+public:
+    explicit TransactionFilterProxy(QObject *parent = 0);
+
+    // Earliest date that can be represented (far in the past)
+    static const QDateTime MIN_DATE;
+    // Last date that can be represented (far in the future)
+    static const QDateTime MAX_DATE;
+    // Type filter bit field (all types)
+    static const quint32 ALL_TYPES = 0xFFFFFFFF;
+
+    static quint32 TYPE(int type) { return 1<<type; }
+
+    void setDateRange(const QDateTime &from, const QDateTime &to);
+    void setAddressPrefix(const QString &addrPrefix);
+    // Type filter takes a bitfield created with TYPE() or ALL_TYPES
+    void setTypeFilter(quint32 modes);
+    void setMinAmount(qint64 minimum);
+
+    // Set maximum number of rows returned, -1 if unlimited
+    void setLimit(int limit);
+
+    int        rowCount(const QModelIndex &parent = QModelIndex()) const;
+protected:
+    bool filterAcceptsRow(int source_row, const QModelIndex & source_parent) const;
+
+private:
+    QDateTime dateFrom;
+    QDateTime dateTo;
+    QString addrPrefix;
+    quint32 typeFilter;
+    qint64 minAmount;
+    int limitRows;
+
+signals:
+
+public slots:
+
+};
+
+#endif // TRANSACTIONFILTERPROXY_H
diff --git a/src/qt/transactionrecord.cpp b/src/qt/transactionrecord.cpp
new file mode 100644 (file)
index 0000000..77c5a01
--- /dev/null
@@ -0,0 +1,264 @@
+#include "transactionrecord.h"
+
+#include "headers.h"
+
+/* Return positive answer if transaction should be shown in list.
+ */
+bool TransactionRecord::showTransaction(const CWalletTx &wtx)
+{
+    if (wtx.IsCoinBase())
+    {
+        // Don't show generated coin until confirmed by at least one block after it
+        // so we don't get the user's hopes up until it looks like it's probably accepted.
+        //
+        // It is not an error when generated blocks are not accepted.  By design,
+        // some percentage of blocks, like 10% or more, will end up not accepted.
+        // This is the normal mechanism by which the network copes with latency.
+        //
+        // We display regular transactions right away before any confirmation
+        // because they can always get into some block eventually.  Generated coins
+        // are special because if their block is not accepted, they are not valid.
+        //
+        if (wtx.GetDepthInMainChain() < 2)
+        {
+            return false;
+        }
+    }
+    return true;
+}
+
+/*
+ * Decompose CWallet transaction to model transaction records.
+ */
+QList<TransactionRecord> TransactionRecord::decomposeTransaction(const CWallet *wallet, const CWalletTx &wtx)
+{
+    QList<TransactionRecord> parts;
+    int64 nTime = wtx.nTimeDisplayed = wtx.GetTxTime();
+    int64 nCredit = wtx.GetCredit(true);
+    int64 nDebit = wtx.GetDebit();
+    int64 nNet = nCredit - nDebit;
+    uint256 hash = wtx.GetHash();
+    std::map<std::string, std::string> mapValue = wtx.mapValue;
+
+    if (showTransaction(wtx))
+    {
+        if (nNet > 0 || wtx.IsCoinBase())
+        {
+            //
+            // Credit
+            //
+            TransactionRecord sub(hash, nTime);
+
+            sub.credit = nNet;
+
+            if (wtx.IsCoinBase())
+            {
+                // Generated
+                sub.type = TransactionRecord::Generated;
+
+                if (nCredit == 0)
+                {
+                    int64 nUnmatured = 0;
+                    BOOST_FOREACH(const CTxOut& txout, wtx.vout)
+                        nUnmatured += wallet->GetCredit(txout);
+                    sub.credit = nUnmatured;
+                }
+            }
+            else if (!mapValue["from"].empty() || !mapValue["message"].empty())
+            {
+                // Received by IP connection
+                sub.type = TransactionRecord::RecvFromIP;
+                if (!mapValue["from"].empty())
+                    sub.address = mapValue["from"];
+            }
+            else
+            {
+                // Received by Bitcoin Address
+                sub.type = TransactionRecord::RecvWithAddress;
+                BOOST_FOREACH(const CTxOut& txout, wtx.vout)
+                {
+                    if(wallet->IsMine(txout))
+                    {
+                        CBitcoinAddress address;
+                        if (ExtractAddress(txout.scriptPubKey, wallet, address))
+                        {
+                            sub.address = address.ToString();
+                        }
+                        break;
+                    }
+                }
+            }
+            parts.append(sub);
+        }
+        else
+        {
+            bool fAllFromMe = true;
+            BOOST_FOREACH(const CTxIn& txin, wtx.vin)
+                fAllFromMe = fAllFromMe && wallet->IsMine(txin);
+
+            bool fAllToMe = true;
+            BOOST_FOREACH(const CTxOut& txout, wtx.vout)
+                fAllToMe = fAllToMe && wallet->IsMine(txout);
+
+            if (fAllFromMe && fAllToMe)
+            {
+                // Payment to self
+                int64 nChange = wtx.GetChange();
+
+                parts.append(TransactionRecord(hash, nTime, TransactionRecord::SendToSelf, "",
+                                -(nDebit - nChange), nCredit - nChange));
+            }
+            else if (fAllFromMe)
+            {
+                //
+                // Debit
+                //
+                int64 nTxFee = nDebit - wtx.GetValueOut();
+
+                for (int nOut = 0; nOut < wtx.vout.size(); nOut++)
+                {
+                    const CTxOut& txout = wtx.vout[nOut];
+                    TransactionRecord sub(hash, nTime);
+                    sub.idx = parts.size();
+
+                    if(wallet->IsMine(txout))
+                    {
+                        // Ignore parts sent to self, as this is usually the change
+                        // from a transaction sent back to our own address.
+                        continue;
+                    }
+                    else if(!mapValue["to"].empty())
+                    {
+                        // Sent to IP
+                        sub.type = TransactionRecord::SendToIP;
+                        sub.address = mapValue["to"];
+                    }
+                    else
+                    {
+                        // Sent to Bitcoin Address
+                        sub.type = TransactionRecord::SendToAddress;
+                        CBitcoinAddress address;
+                        if (ExtractAddress(txout.scriptPubKey, 0, address))
+                        {
+                            sub.address = address.ToString();
+                        }
+                    }
+
+                    int64 nValue = txout.nValue;
+                    /* Add fee to first output */
+                    if (nTxFee > 0)
+                    {
+                        nValue += nTxFee;
+                        nTxFee = 0;
+                    }
+                    sub.debit = -nValue;
+
+                    parts.append(sub);
+                }
+            }
+            else
+            {
+                //
+                // Mixed debit transaction, can't break down payees
+                //
+                bool fAllMine = true;
+                BOOST_FOREACH(const CTxOut& txout, wtx.vout)
+                    fAllMine = fAllMine && wallet->IsMine(txout);
+                BOOST_FOREACH(const CTxIn& txin, wtx.vin)
+                    fAllMine = fAllMine && wallet->IsMine(txin);
+
+                parts.append(TransactionRecord(hash, nTime, TransactionRecord::Other, "", nNet, 0));
+            }
+        }
+    }
+
+    return parts;
+}
+
+void TransactionRecord::updateStatus(const CWalletTx &wtx)
+{
+    // Determine transaction status
+
+    // Find the block the tx is in
+    CBlockIndex* pindex = NULL;
+    std::map<uint256, CBlockIndex*>::iterator mi = mapBlockIndex.find(wtx.hashBlock);
+    if (mi != mapBlockIndex.end())
+        pindex = (*mi).second;
+
+    // Sort order, unrecorded transactions sort to the top
+    status.sortKey = strprintf("%010d-%01d-%010u-%03d",
+        (pindex ? pindex->nHeight : INT_MAX),
+        (wtx.IsCoinBase() ? 1 : 0),
+        wtx.nTimeReceived,
+        idx);
+    status.confirmed = wtx.IsConfirmed();
+    status.depth = wtx.GetDepthInMainChain();
+    status.cur_num_blocks = nBestHeight;
+
+    if (!wtx.IsFinal())
+    {
+        if (wtx.nLockTime < LOCKTIME_THRESHOLD)
+        {
+            status.status = TransactionStatus::OpenUntilBlock;
+            status.open_for = nBestHeight - wtx.nLockTime;
+        }
+        else
+        {
+            status.status = TransactionStatus::OpenUntilDate;
+            status.open_for = wtx.nLockTime;
+        }
+    }
+    else
+    {
+        if (GetAdjustedTime() - wtx.nTimeReceived > 2 * 60 && wtx.GetRequestCount() == 0)
+        {
+            status.status = TransactionStatus::Offline;
+        }
+        else if (status.depth < NumConfirmations)
+        {
+            status.status = TransactionStatus::Unconfirmed;
+        }
+        else
+        {
+            status.status = TransactionStatus::HaveConfirmations;
+        }
+    }
+
+    // For generated transactions, determine maturity
+    if(type == TransactionRecord::Generated)
+    {
+        int64 nCredit = wtx.GetCredit(true);
+        if (nCredit == 0)
+        {
+            status.maturity = TransactionStatus::Immature;
+
+            if (wtx.IsInMainChain())
+            {
+                status.matures_in = wtx.GetBlocksToMaturity();
+
+                // Check if the block was requested by anyone
+                if (GetAdjustedTime() - wtx.nTimeReceived > 2 * 60 && wtx.GetRequestCount() == 0)
+                    status.maturity = TransactionStatus::MaturesWarning;
+            }
+            else
+            {
+                status.maturity = TransactionStatus::NotAccepted;
+            }
+        }
+        else
+        {
+            status.maturity = TransactionStatus::Mature;
+        }
+    }
+}
+
+bool TransactionRecord::statusUpdateNeeded()
+{
+    return status.cur_num_blocks != nBestHeight;
+}
+
+std::string TransactionRecord::getTxID()
+{
+    return hash.ToString() + strprintf("-%03d", idx);
+}
+
diff --git a/src/qt/transactionrecord.h b/src/qt/transactionrecord.h
new file mode 100644 (file)
index 0000000..0050c87
--- /dev/null
@@ -0,0 +1,118 @@
+#ifndef TRANSACTIONRECORD_H
+#define TRANSACTIONRECORD_H
+
+#include "uint256.h"
+
+#include <QList>
+
+class CWallet;
+class CWalletTx;
+
+class TransactionStatus
+{
+public:
+    TransactionStatus():
+            confirmed(false), sortKey(""), maturity(Mature),
+            matures_in(0), status(Offline), depth(0), open_for(0), cur_num_blocks(-1)
+    { }
+
+    enum Maturity
+    {
+        Immature,
+        Mature,
+        MaturesWarning, /* Will likely not mature because no nodes have confirmed */
+        NotAccepted
+    };
+
+    enum Status {
+        OpenUntilDate,
+        OpenUntilBlock,
+        Offline,
+        Unconfirmed,
+        HaveConfirmations
+    };
+
+    bool confirmed;
+    std::string sortKey;
+
+    /* For "Generated" transactions */
+    Maturity maturity;
+    int matures_in;
+
+    /* Reported status */
+    Status status;
+    int64 depth;
+    int64 open_for; /* Timestamp if status==OpenUntilDate, otherwise number of blocks */
+
+    /* Current number of blocks (to know whether cached status is still valid. */
+    int cur_num_blocks;
+};
+
+class TransactionRecord
+{
+public:
+    enum Type
+    {
+        Other,
+        Generated,
+        SendToAddress,
+        SendToIP,
+        RecvWithAddress,
+        RecvFromIP,
+        SendToSelf
+    };
+
+    /* Number of confirmation needed for transaction */
+    static const int NumConfirmations = 6;
+
+    TransactionRecord():
+            hash(), time(0), type(Other), address(""), debit(0), credit(0), idx(0)
+    {
+    }
+
+    TransactionRecord(uint256 hash, int64 time):
+            hash(hash), time(time), type(Other), address(""), debit(0),
+            credit(0), idx(0)
+    {
+    }
+
+    TransactionRecord(uint256 hash, int64 time,
+                Type type, const std::string &address,
+                int64 debit, int64 credit):
+            hash(hash), time(time), type(type), address(address), debit(debit), credit(credit),
+            idx(0)
+    {
+    }
+
+    /* Decompose CWallet transaction to model transaction records.
+     */
+    static bool showTransaction(const CWalletTx &wtx);
+    static QList<TransactionRecord> decomposeTransaction(const CWallet *wallet, const CWalletTx &wtx);
+
+    /* Fixed */
+    uint256 hash;
+    int64 time;
+    Type type;
+    std::string address;
+    int64 debit;
+    int64 credit;
+
+    /* Subtransaction index, for sort key */
+    int idx;
+
+    /* Status: can change with block chain update */
+    TransactionStatus status;
+
+    /* Return the unique identifier for this transaction (part) */
+    std::string getTxID();
+
+    /* Update status from wallet tx.
+     */
+    void updateStatus(const CWalletTx &wtx);
+
+    /* Is a status update needed?
+     */
+    bool statusUpdateNeeded();
+};
+
+#endif // TRANSACTIONRECORD_H
diff --git a/src/qt/transactiontablemodel.cpp b/src/qt/transactiontablemodel.cpp
new file mode 100644 (file)
index 0000000..0e1733f
--- /dev/null
@@ -0,0 +1,622 @@
+#include "transactiontablemodel.h"
+#include "guiutil.h"
+#include "transactionrecord.h"
+#include "guiconstants.h"
+#include "transactiondesc.h"
+#include "walletmodel.h"
+#include "optionsmodel.h"
+#include "addresstablemodel.h"
+#include "bitcoinunits.h"
+
+#include "headers.h"
+
+#include <QLocale>
+#include <QList>
+#include <QColor>
+#include <QTimer>
+#include <QIcon>
+#include <QDateTime>
+#include <QtAlgorithms>
+
+// Amount column is right-aligned it contains numbers
+static int column_alignments[] = {
+        Qt::AlignLeft|Qt::AlignVCenter,
+        Qt::AlignLeft|Qt::AlignVCenter,
+        Qt::AlignLeft|Qt::AlignVCenter,
+        Qt::AlignLeft|Qt::AlignVCenter,
+        Qt::AlignRight|Qt::AlignVCenter
+    };
+
+// Comparison operator for sort/binary search of model tx list
+struct TxLessThan
+{
+    bool operator()(const TransactionRecord &a, const TransactionRecord &b) const
+    {
+        return a.hash < b.hash;
+    }
+    bool operator()(const TransactionRecord &a, const uint256 &b) const
+    {
+        return a.hash < b;
+    }
+    bool operator()(const uint256 &a, const TransactionRecord &b) const
+    {
+        return a < b.hash;
+    }
+};
+
+// Private implementation
+struct TransactionTablePriv
+{
+    TransactionTablePriv(CWallet *wallet, TransactionTableModel *parent):
+            wallet(wallet),
+            parent(parent)
+    {
+    }
+    CWallet *wallet;
+    TransactionTableModel *parent;
+
+    /* Local cache of wallet.
+     * As it is in the same order as the CWallet, by definition
+     * this is sorted by sha256.
+     */
+    QList<TransactionRecord> cachedWallet;
+
+    /* Query entire wallet anew from core.
+     */
+    void refreshWallet()
+    {
+#ifdef WALLET_UPDATE_DEBUG
+        qDebug() << "refreshWallet";
+#endif
+        cachedWallet.clear();
+        CRITICAL_BLOCK(wallet->cs_wallet)
+        {
+            for(std::map<uint256, CWalletTx>::iterator it = wallet->mapWallet.begin(); it != wallet->mapWallet.end(); ++it)
+            {
+                cachedWallet.append(TransactionRecord::decomposeTransaction(wallet, it->second));
+            }
+        }
+    }
+
+    /* Update our model of the wallet incrementally, to synchronize our model of the wallet
+       with that of the core.
+
+       Call with list of hashes of transactions that were added, removed or changed.
+     */
+    void updateWallet(const QList<uint256> &updated)
+    {
+        // Walk through updated transactions, update model as needed.
+#ifdef WALLET_UPDATE_DEBUG
+        qDebug() << "updateWallet";
+#endif
+        // Sort update list, and iterate through it in reverse, so that model updates
+        //  can be emitted from end to beginning (so that earlier updates will not influence
+        // the indices of latter ones).
+        QList<uint256> updated_sorted = updated;
+        qSort(updated_sorted);
+
+        CRITICAL_BLOCK(wallet->cs_wallet)
+        {
+            for(int update_idx = updated_sorted.size()-1; update_idx >= 0; --update_idx)
+            {
+                const uint256 &hash = updated_sorted.at(update_idx);
+                // Find transaction in wallet
+                std::map<uint256, CWalletTx>::iterator mi = wallet->mapWallet.find(hash);
+                bool inWallet = mi != wallet->mapWallet.end();
+                // Find bounds of this transaction in model
+                QList<TransactionRecord>::iterator lower = qLowerBound(
+                    cachedWallet.begin(), cachedWallet.end(), hash, TxLessThan());
+                QList<TransactionRecord>::iterator upper = qUpperBound(
+                    cachedWallet.begin(), cachedWallet.end(), hash, TxLessThan());
+                int lowerIndex = (lower - cachedWallet.begin());
+                int upperIndex = (upper - cachedWallet.begin());
+
+                // Determine if transaction is in model already
+                bool inModel = false;
+                if(lower != upper)
+                {
+                    inModel = true;
+                }
+
+#ifdef WALLET_UPDATE_DEBUG
+                qDebug() << "  " << QString::fromStdString(hash.ToString()) << inWallet << " " << inModel
+                        << lowerIndex << "-" << upperIndex;
+#endif
+
+                if(inWallet && !inModel)
+                {
+                    // Added -- insert at the right position
+                    QList<TransactionRecord> toInsert =
+                            TransactionRecord::decomposeTransaction(wallet, mi->second);
+                    if(!toInsert.isEmpty()) /* only if something to insert */
+                    {
+                        parent->beginInsertRows(QModelIndex(), lowerIndex, lowerIndex+toInsert.size()-1);
+                        int insert_idx = lowerIndex;
+                        foreach(const TransactionRecord &rec, toInsert)
+                        {
+                            cachedWallet.insert(insert_idx, rec);
+                            insert_idx += 1;
+                        }
+                        parent->endInsertRows();
+                    }
+                }
+                else if(!inWallet && inModel)
+                {
+                    // Removed -- remove entire transaction from table
+                    parent->beginRemoveRows(QModelIndex(), lowerIndex, upperIndex-1);
+                    cachedWallet.erase(lower, upper);
+                    parent->endRemoveRows();
+                }
+                else if(inWallet && inModel)
+                {
+                    // Updated -- nothing to do, status update will take care of this
+                }
+            }
+        }
+    }
+
+    int size()
+    {
+        return cachedWallet.size();
+    }
+
+    TransactionRecord *index(int idx)
+    {
+        if(idx >= 0 && idx < cachedWallet.size())
+        {
+            TransactionRecord *rec = &cachedWallet[idx];
+
+            // If a status update is needed (blocks came in since last check),
+            //  update the status of this transaction from the wallet. Otherwise,
+            // simply re-use the cached status.
+            if(rec->statusUpdateNeeded())
+            {
+                CRITICAL_BLOCK(wallet->cs_wallet)
+                {
+                    std::map<uint256, CWalletTx>::iterator mi = wallet->mapWallet.find(rec->hash);
+
+                    if(mi != wallet->mapWallet.end())
+                    {
+                        rec->updateStatus(mi->second);
+                    }
+                }
+            }
+            return rec;
+        }
+        else
+        {
+            return 0;
+        }
+    }
+
+    QString describe(TransactionRecord *rec)
+    {
+        CRITICAL_BLOCK(wallet->cs_wallet)
+        {
+            std::map<uint256, CWalletTx>::iterator mi = wallet->mapWallet.find(rec->hash);
+            if(mi != wallet->mapWallet.end())
+            {
+                return TransactionDesc::toHTML(wallet, mi->second);
+            }
+        }
+        return QString("");
+    }
+
+};
+
+TransactionTableModel::TransactionTableModel(CWallet* wallet, WalletModel *parent):
+        QAbstractTableModel(parent),
+        wallet(wallet),
+        walletModel(parent),
+        priv(new TransactionTablePriv(wallet, this))
+{
+    columns << QString() << tr("Date") << tr("Type") << tr("Address") << tr("Amount");
+
+    priv->refreshWallet();
+
+    QTimer *timer = new QTimer(this);
+    connect(timer, SIGNAL(timeout()), this, SLOT(update()));
+    timer->start(MODEL_UPDATE_DELAY);
+}
+
+TransactionTableModel::~TransactionTableModel()
+{
+    delete priv;
+}
+
+void TransactionTableModel::update()
+{
+    QList<uint256> updated;
+
+    // Check if there are changes to wallet map
+    TRY_CRITICAL_BLOCK(wallet->cs_wallet)
+    {
+        if(!wallet->vWalletUpdated.empty())
+        {
+            BOOST_FOREACH(uint256 hash, wallet->vWalletUpdated)
+            {
+                updated.append(hash);
+            }
+            wallet->vWalletUpdated.clear();
+        }
+    }
+
+    if(!updated.empty())
+    {
+        priv->updateWallet(updated);
+
+        // Status (number of confirmations) and (possibly) description
+        //  columns changed for all rows.
+        emit dataChanged(index(0, Status), index(priv->size()-1, Status));
+        emit dataChanged(index(0, ToAddress), index(priv->size()-1, ToAddress));
+    }
+}
+
+int TransactionTableModel::rowCount(const QModelIndex &parent) const
+{
+    Q_UNUSED(parent);
+    return priv->size();
+}
+
+int TransactionTableModel::columnCount(const QModelIndex &parent) const
+{
+    Q_UNUSED(parent);
+    return columns.length();
+}
+
+QString TransactionTableModel::formatTxStatus(const TransactionRecord *wtx) const
+{
+    QString status;
+
+    switch(wtx->status.status)
+    {
+    case TransactionStatus::OpenUntilBlock:
+        status = tr("Open for %n block(s)","",wtx->status.open_for);
+        break;
+    case TransactionStatus::OpenUntilDate:
+        status = tr("Open until %1").arg(GUIUtil::dateTimeStr(wtx->status.open_for));
+        break;
+    case TransactionStatus::Offline:
+        status = tr("Offline (%1 confirmations)").arg(wtx->status.depth);
+        break;
+    case TransactionStatus::Unconfirmed:
+        status = tr("Unconfirmed (%1 of %2 confirmations)").arg(wtx->status.depth).arg(TransactionRecord::NumConfirmations);
+        break;
+    case TransactionStatus::HaveConfirmations:
+        status = tr("Confirmed (%1 confirmations)").arg(wtx->status.depth);
+        break;
+    }
+    if(wtx->type == TransactionRecord::Generated)
+    {
+        status += "\n";
+        switch(wtx->status.maturity)
+        {
+        case TransactionStatus::Immature:
+            status += tr("Mined balance will be available in %n more blocks", "",
+                           wtx->status.matures_in);
+            break;
+        case TransactionStatus::Mature:
+            break;
+        case TransactionStatus::MaturesWarning:
+            status += tr("This block was not received by any other nodes and will probably not be accepted!");
+            break;
+        case TransactionStatus::NotAccepted:
+            status += tr("Generated but not accepted");
+            break;
+        }
+    }
+
+    return status;
+}
+
+QString TransactionTableModel::formatTxDate(const TransactionRecord *wtx) const
+{
+    if(wtx->time)
+    {
+        return GUIUtil::dateTimeStr(wtx->time);
+    }
+    else
+    {
+        return QString();
+    }
+}
+
+/* Look up address in address book, if found return label (address)
+   otherwise just return (address)
+ */
+QString TransactionTableModel::lookupAddress(const std::string &address, bool tooltip) const
+{
+    QString label = walletModel->getAddressTableModel()->labelForAddress(QString::fromStdString(address));
+    QString description;
+    if(!label.isEmpty())
+    {
+        description += label + QString(" ");
+    }
+    if(label.isEmpty() || walletModel->getOptionsModel()->getDisplayAddresses() || tooltip)
+    {
+        description += QString("(") + QString::fromStdString(address) + QString(")");
+    }
+    return description;
+}
+
+QString TransactionTableModel::formatTxType(const TransactionRecord *wtx) const
+{
+    switch(wtx->type)
+    {
+    case TransactionRecord::RecvWithAddress:
+        return tr("Received with");
+    case TransactionRecord::RecvFromIP:
+        return tr("Received from IP");
+    case TransactionRecord::SendToAddress:
+        return tr("Sent to");
+    case TransactionRecord::SendToIP:
+        return tr("Sent to IP");
+    case TransactionRecord::SendToSelf:
+        return tr("Payment to yourself");
+    case TransactionRecord::Generated:
+        return tr("Mined");
+    default:
+        return QString();
+    }
+}
+
+QVariant TransactionTableModel::txAddressDecoration(const TransactionRecord *wtx) const
+{
+    switch(wtx->type)
+    {
+    case TransactionRecord::Generated:
+        return QIcon(":/icons/tx_mined");
+    case TransactionRecord::RecvWithAddress:
+    case TransactionRecord::RecvFromIP:
+        return QIcon(":/icons/tx_input");
+    case TransactionRecord::SendToAddress:
+    case TransactionRecord::SendToIP:
+        return QIcon(":/icons/tx_output");
+    default:
+        return QIcon(":/icons/tx_inout");
+    }
+    return QVariant();
+}
+
+QString TransactionTableModel::formatTxToAddress(const TransactionRecord *wtx, bool tooltip) const
+{
+    switch(wtx->type)
+    {
+    case TransactionRecord::RecvFromIP:
+        return QString::fromStdString(wtx->address);
+    case TransactionRecord::RecvWithAddress:
+    case TransactionRecord::SendToAddress:
+        return lookupAddress(wtx->address, tooltip);
+    case TransactionRecord::SendToIP:
+        return QString::fromStdString(wtx->address);
+    case TransactionRecord::SendToSelf:
+    case TransactionRecord::Generated:
+    default:
+        return tr("(n/a)");
+    }
+}
+
+QVariant TransactionTableModel::addressColor(const TransactionRecord *wtx) const
+{
+    // Show addresses without label in a less visible color
+    switch(wtx->type)
+    {
+    case TransactionRecord::RecvWithAddress:
+    case TransactionRecord::SendToAddress:
+        {
+        QString label = walletModel->getAddressTableModel()->labelForAddress(QString::fromStdString(wtx->address));
+        if(label.isEmpty())
+            return COLOR_BAREADDRESS;
+        } break;
+    case TransactionRecord::SendToSelf:
+    case TransactionRecord::Generated:
+        return COLOR_BAREADDRESS;
+    default:
+        break;
+    }
+    return QVariant();
+}
+
+QString TransactionTableModel::formatTxAmount(const TransactionRecord *wtx, bool showUnconfirmed) const
+{
+    QString str = BitcoinUnits::format(walletModel->getOptionsModel()->getDisplayUnit(), wtx->credit + wtx->debit);
+    if(showUnconfirmed)
+    {
+        if(!wtx->status.confirmed || wtx->status.maturity != TransactionStatus::Mature)
+        {
+            str = QString("[") + str + QString("]");
+        }
+    }
+    return QString(str);
+}
+
+QVariant TransactionTableModel::txStatusDecoration(const TransactionRecord *wtx) const
+{
+    if(wtx->type == TransactionRecord::Generated)
+    {
+        switch(wtx->status.maturity)
+        {
+        case TransactionStatus::Immature: {
+            int total = wtx->status.depth + wtx->status.matures_in;
+            int part = (wtx->status.depth * 4 / total) + 1;
+            return QIcon(QString(":/icons/transaction_%1").arg(part));
+            }
+        case TransactionStatus::Mature:
+            return QIcon(":/icons/transaction_confirmed");
+        case TransactionStatus::MaturesWarning:
+        case TransactionStatus::NotAccepted:
+            return QIcon(":/icons/transaction_0");
+        }
+    }
+    else
+    {
+        switch(wtx->status.status)
+        {
+        case TransactionStatus::OpenUntilBlock:
+        case TransactionStatus::OpenUntilDate:
+            return QColor(64,64,255);
+            break;
+        case TransactionStatus::Offline:
+            return QColor(192,192,192);
+        case TransactionStatus::Unconfirmed:
+            switch(wtx->status.depth)
+            {
+            case 0: return QIcon(":/icons/transaction_0");
+            case 1: return QIcon(":/icons/transaction_1");
+            case 2: return QIcon(":/icons/transaction_2");
+            case 3: return QIcon(":/icons/transaction_3");
+            case 4: return QIcon(":/icons/transaction_4");
+            default: return QIcon(":/icons/transaction_5");
+            };
+        case TransactionStatus::HaveConfirmations:
+            return QIcon(":/icons/transaction_confirmed");
+        }
+    }
+    return QColor(0,0,0);
+}
+
+QString TransactionTableModel::formatTooltip(const TransactionRecord *rec) const
+{
+    QString tooltip = formatTxStatus(rec) + QString("\n") + formatTxType(rec);
+    if(rec->type==TransactionRecord::RecvFromIP || rec->type==TransactionRecord::SendToIP ||
+       rec->type==TransactionRecord::SendToAddress || rec->type==TransactionRecord::RecvWithAddress)
+    {
+        tooltip += QString(" ") + formatTxToAddress(rec, true);
+    }
+    return tooltip;
+}
+
+QVariant TransactionTableModel::data(const QModelIndex &index, int role) const
+{
+    if(!index.isValid())
+        return QVariant();
+    TransactionRecord *rec = static_cast<TransactionRecord*>(index.internalPointer());
+
+    switch(role)
+    {
+    case Qt::DecorationRole:
+        switch(index.column())
+        {
+        case Status:
+            return txStatusDecoration(rec);
+        case ToAddress:
+            return txAddressDecoration(rec);
+        }
+        break;
+    case Qt::DisplayRole:
+        switch(index.column())
+        {
+        case Date:
+            return formatTxDate(rec);
+        case Type:
+            return formatTxType(rec);
+        case ToAddress:
+            return formatTxToAddress(rec, false);
+        case Amount:
+            return formatTxAmount(rec);
+        }
+        break;
+    case Qt::EditRole:
+        // Edit role is used for sorting, so return the unformatted values
+        switch(index.column())
+        {
+        case Status:
+            return QString::fromStdString(rec->status.sortKey);
+        case Date:
+            return rec->time;
+        case Type:
+            return formatTxType(rec);
+        case ToAddress:
+            return formatTxToAddress(rec, true);
+        case Amount:
+            return rec->credit + rec->debit;
+        }
+        break;
+    case Qt::ToolTipRole:
+        return formatTooltip(rec);
+    case Qt::TextAlignmentRole:
+        return column_alignments[index.column()];
+    case Qt::ForegroundRole:
+        // Non-confirmed transactions are grey
+        if(!rec->status.confirmed)
+        {
+            return COLOR_UNCONFIRMED;
+        }
+        if(index.column() == Amount && (rec->credit+rec->debit) < 0)
+        {
+            return COLOR_NEGATIVE;
+        }
+        if(index.column() == ToAddress)
+        {
+            return addressColor(rec);
+        }
+        break;
+    case TypeRole:
+        return rec->type;
+    case DateRole:
+        return QDateTime::fromTime_t(static_cast<uint>(rec->time));
+    case LongDescriptionRole:
+        return priv->describe(rec);
+    case AddressRole:
+        return QString::fromStdString(rec->address);
+    case LabelRole:
+        return walletModel->getAddressTableModel()->labelForAddress(QString::fromStdString(rec->address));
+    case AmountRole:
+        return rec->credit + rec->debit;
+    case TxIDRole:
+        return QString::fromStdString(rec->getTxID());
+    case ConfirmedRole:
+        // Return True if transaction counts for balance
+        return rec->status.confirmed && !(rec->type == TransactionRecord::Generated &&
+                                          rec->status.maturity != TransactionStatus::Mature);
+    case FormattedAmountRole:
+        return formatTxAmount(rec, false);
+    }
+    return QVariant();
+}
+
+QVariant TransactionTableModel::headerData(int section, Qt::Orientation orientation, int role) const
+{
+    if(orientation == Qt::Horizontal)
+    {
+        if(role == Qt::DisplayRole)
+        {
+            return columns[section];
+        }
+        else if (role == Qt::TextAlignmentRole)
+        {
+            return column_alignments[section];
+        } else if (role == Qt::ToolTipRole)
+        {
+            switch(section)
+            {
+            case Status:
+                return tr("Transaction status. Hover over this field to show number of confirmations.");
+            case Date:
+                return tr("Date and time that the transaction was received.");
+            case Type:
+                return tr("Type of transaction.");
+            case ToAddress:
+                return tr("Destination address of transaction.");
+            case Amount:
+                return tr("Amount removed from or added to balance.");
+            }
+        }
+    }
+    return QVariant();
+}
+
+QModelIndex TransactionTableModel::index(int row, int column, const QModelIndex &parent) const
+{
+    Q_UNUSED(parent);
+    TransactionRecord *data = priv->index(row);
+    if(data)
+    {
+        return createIndex(row, column, priv->index(row));
+    }
+    else
+    {
+        return QModelIndex();
+    }
+}
+
diff --git a/src/qt/transactiontablemodel.h b/src/qt/transactiontablemodel.h
new file mode 100644 (file)
index 0000000..da55495
--- /dev/null
@@ -0,0 +1,79 @@
+#ifndef TRANSACTIONTABLEMODEL_H
+#define TRANSACTIONTABLEMODEL_H
+
+#include <QAbstractTableModel>
+#include <QStringList>
+
+class CWallet;
+class TransactionTablePriv;
+class TransactionRecord;
+class WalletModel;
+
+class TransactionTableModel : public QAbstractTableModel
+{
+    Q_OBJECT
+public:
+    explicit TransactionTableModel(CWallet* wallet, WalletModel *parent = 0);
+    ~TransactionTableModel();
+
+    enum {
+        Status = 0,
+        Date = 1,
+        Type = 2,
+        ToAddress = 3,
+        Amount = 4
+    } ColumnIndex;
+
+    // Roles to get specific information from a transaction row
+    // These are independent of column
+    enum {
+        // Type of transaction
+        TypeRole = Qt::UserRole,
+        // Date and time this transaction was created
+        DateRole,
+        // Long description (HTML format)
+        LongDescriptionRole,
+        // Address of transaction
+        AddressRole,
+        // Label of address related to transaction
+        LabelRole,
+        // Net amount of transaction
+        AmountRole,
+        // Unique identifier
+        TxIDRole,
+        // Is transaction confirmed?
+        ConfirmedRole,
+        // Formatted amount, without brackets when unconfirmed
+        FormattedAmountRole
+    } RoleIndex;
+
+    int rowCount(const QModelIndex &parent) const;
+    int columnCount(const QModelIndex &parent) const;
+    QVariant data(const QModelIndex &index, int role) const;
+    QVariant headerData(int section, Qt::Orientation orientation, int role) const;
+    QModelIndex index(int row, int column, const QModelIndex & parent = QModelIndex()) const;
+private:
+    CWallet* wallet;
+    WalletModel *walletModel;
+    QStringList columns;
+    TransactionTablePriv *priv;
+
+    QString lookupAddress(const std::string &address, bool tooltip) const;
+    QVariant addressColor(const TransactionRecord *wtx) const;
+    QString formatTxStatus(const TransactionRecord *wtx) const;
+    QString formatTxDate(const TransactionRecord *wtx) const;
+    QString formatTxType(const TransactionRecord *wtx) const;
+    QString formatTxToAddress(const TransactionRecord *wtx, bool tooltip) const;
+    QString formatTxAmount(const TransactionRecord *wtx, bool showUnconfirmed=true) const;
+    QString formatTooltip(const TransactionRecord *rec) const;
+    QVariant txStatusDecoration(const TransactionRecord *wtx) const;
+    QVariant txAddressDecoration(const TransactionRecord *wtx) const;
+
+private slots:
+    void update();
+
+    friend class TransactionTablePriv;
+};
+
+#endif
+
diff --git a/src/qt/transactionview.cpp b/src/qt/transactionview.cpp
new file mode 100644 (file)
index 0000000..b2777b7
--- /dev/null
@@ -0,0 +1,385 @@
+#include "transactionview.h"
+
+#include "transactionfilterproxy.h"
+#include "transactionrecord.h"
+#include "walletmodel.h"
+#include "addresstablemodel.h"
+#include "transactiontablemodel.h"
+#include "bitcoinunits.h"
+#include "csvmodelwriter.h"
+#include "transactiondescdialog.h"
+#include "editaddressdialog.h"
+#include "optionsmodel.h"
+
+#include <QScrollBar>
+#include <QComboBox>
+#include <QDoubleValidator>
+#include <QHBoxLayout>
+#include <QVBoxLayout>
+#include <QLineEdit>
+#include <QTableView>
+#include <QHeaderView>
+#include <QPushButton>
+#include <QFileDialog>
+#include <QMessageBox>
+#include <QPoint>
+#include <QMenu>
+#include <QApplication>
+#include <QClipboard>
+#include <QLabel>
+#include <QDateTimeEdit>
+
+TransactionView::TransactionView(QWidget *parent) :
+    QWidget(parent), model(0), transactionProxyModel(0),
+    transactionView(0)
+{
+    // Build filter row
+    setContentsMargins(0,0,0,0);
+
+    QHBoxLayout *hlayout = new QHBoxLayout();
+    hlayout->setContentsMargins(0,0,0,0);
+    hlayout->setSpacing(0);
+
+    hlayout->addSpacing(23);
+
+    dateWidget = new QComboBox(this);
+    dateWidget->setMaximumWidth(120);
+    dateWidget->setMinimumWidth(120);
+    dateWidget->addItem(tr("All"), All);
+    dateWidget->addItem(tr("Today"), Today);
+    dateWidget->addItem(tr("This week"), ThisWeek);
+    dateWidget->addItem(tr("This month"), ThisMonth);
+    dateWidget->addItem(tr("Last month"), LastMonth);
+    dateWidget->addItem(tr("This year"), ThisYear);
+    dateWidget->addItem(tr("Range..."), Range);
+    hlayout->addWidget(dateWidget);
+
+    typeWidget = new QComboBox(this);
+    typeWidget->setMaximumWidth(120);
+    typeWidget->setMinimumWidth(120);
+
+    typeWidget->addItem(tr("All"), TransactionFilterProxy::ALL_TYPES);
+    typeWidget->addItem(tr("Received with"), TransactionFilterProxy::TYPE(TransactionRecord::RecvWithAddress) |
+                                        TransactionFilterProxy::TYPE(TransactionRecord::RecvFromIP));
+    typeWidget->addItem(tr("Sent to"), TransactionFilterProxy::TYPE(TransactionRecord::SendToAddress) |
+                                  TransactionFilterProxy::TYPE(TransactionRecord::SendToIP));
+    typeWidget->addItem(tr("To yourself"), TransactionFilterProxy::TYPE(TransactionRecord::SendToSelf));
+    typeWidget->addItem(tr("Mined"), TransactionFilterProxy::TYPE(TransactionRecord::Generated));
+    typeWidget->addItem(tr("Other"), TransactionFilterProxy::TYPE(TransactionRecord::Other));
+
+    hlayout->addWidget(typeWidget);
+
+    addressWidget = new QLineEdit(this);
+#if QT_VERSION >= 0x040700
+    addressWidget->setPlaceholderText(tr("Enter address or label to search"));
+#endif
+    hlayout->addWidget(addressWidget);
+
+    amountWidget = new QLineEdit(this);
+#if QT_VERSION >= 0x040700
+    amountWidget->setPlaceholderText(tr("Min amount"));
+#endif
+    amountWidget->setMaximumWidth(100);
+    amountWidget->setMinimumWidth(100);
+    amountWidget->setValidator(new QDoubleValidator(0, 1e20, 8, this));
+    hlayout->addWidget(amountWidget);
+
+    QVBoxLayout *vlayout = new QVBoxLayout(this);
+    vlayout->setContentsMargins(0,0,0,0);
+    vlayout->setSpacing(0);
+    //vlayout->addLayout(hlayout2);
+
+    QTableView *view = new QTableView(this);
+    vlayout->addLayout(hlayout);
+    vlayout->addWidget(createDateRangeWidget());
+    vlayout->addWidget(view);
+    vlayout->setSpacing(0);
+    int width = view->verticalScrollBar()->sizeHint().width();
+    // Cover scroll bar width with spacing
+    hlayout->addSpacing(width);
+    // Always show scroll bar
+    view->setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOn);
+    view->setTabKeyNavigation(false);
+    view->setContextMenuPolicy(Qt::CustomContextMenu);
+
+    transactionView = view;
+
+    // Actions
+    QAction *copyAddressAction = new QAction(tr("Copy address"), this);
+    QAction *copyLabelAction = new QAction(tr("Copy label"), this);
+    QAction *editLabelAction = new QAction(tr("Edit label"), this);
+    QAction *showDetailsAction = new QAction(tr("Show details..."), this);
+
+    contextMenu = new QMenu();
+    contextMenu->addAction(copyAddressAction);
+    contextMenu->addAction(copyLabelAction);
+    contextMenu->addAction(editLabelAction);
+    contextMenu->addAction(showDetailsAction);
+
+    // Connect actions
+    connect(dateWidget, SIGNAL(activated(int)), this, SLOT(chooseDate(int)));
+    connect(typeWidget, SIGNAL(activated(int)), this, SLOT(chooseType(int)));
+    connect(addressWidget, SIGNAL(textChanged(QString)), this, SLOT(changedPrefix(QString)));
+    connect(amountWidget, SIGNAL(textChanged(QString)), this, SLOT(changedAmount(QString)));
+
+    connect(view, SIGNAL(doubleClicked(QModelIndex)), this, SIGNAL(doubleClicked(QModelIndex)));
+
+    connect(view,
+            SIGNAL(customContextMenuRequested(QPoint)),
+            this,
+            SLOT(contextualMenu(QPoint)));
+
+    connect(copyAddressAction, SIGNAL(triggered()), this, SLOT(copyAddress()));
+    connect(copyLabelAction, SIGNAL(triggered()), this, SLOT(copyLabel()));
+    connect(editLabelAction, SIGNAL(triggered()), this, SLOT(editLabel()));
+    connect(showDetailsAction, SIGNAL(triggered()), this, SLOT(showDetails()));
+}
+
+void TransactionView::setModel(WalletModel *model)
+{
+    this->model = model;
+
+    transactionProxyModel = new TransactionFilterProxy(this);
+    transactionProxyModel->setSourceModel(model->getTransactionTableModel());
+    transactionProxyModel->setDynamicSortFilter(true);
+
+    transactionProxyModel->setSortRole(Qt::EditRole);
+
+    transactionView->setModel(transactionProxyModel);
+    transactionView->setAlternatingRowColors(true);
+    transactionView->setSelectionBehavior(QAbstractItemView::SelectRows);
+    transactionView->setSelectionMode(QAbstractItemView::ExtendedSelection);
+    transactionView->setSortingEnabled(true);
+    transactionView->sortByColumn(TransactionTableModel::Status, Qt::DescendingOrder);
+    transactionView->verticalHeader()->hide();
+
+    transactionView->horizontalHeader()->resizeSection(
+            TransactionTableModel::Status, 23);
+    transactionView->horizontalHeader()->resizeSection(
+            TransactionTableModel::Date, 120);
+    transactionView->horizontalHeader()->resizeSection(
+            TransactionTableModel::Type, 120);
+    transactionView->horizontalHeader()->setResizeMode(
+            TransactionTableModel::ToAddress, QHeaderView::Stretch);
+    transactionView->horizontalHeader()->resizeSection(
+            TransactionTableModel::Amount, 100);
+
+}
+
+void TransactionView::chooseDate(int idx)
+{
+    QDate current = QDate::currentDate();
+    dateRangeWidget->setVisible(false);
+    switch(dateWidget->itemData(idx).toInt())
+    {
+    case All:
+        transactionProxyModel->setDateRange(
+                TransactionFilterProxy::MIN_DATE,
+                TransactionFilterProxy::MAX_DATE);
+        break;
+    case Today:
+        transactionProxyModel->setDateRange(
+                QDateTime(current),
+                TransactionFilterProxy::MAX_DATE);
+        break;
+    case ThisWeek: {
+        // Find last monday
+        QDate startOfWeek = current.addDays(-(current.dayOfWeek()-1));
+        transactionProxyModel->setDateRange(
+                QDateTime(startOfWeek),
+                TransactionFilterProxy::MAX_DATE);
+
+        } break;
+    case ThisMonth:
+        transactionProxyModel->setDateRange(
+                QDateTime(QDate(current.year(), current.month(), 1)),
+                TransactionFilterProxy::MAX_DATE);
+        break;
+    case LastMonth:
+        transactionProxyModel->setDateRange(
+                QDateTime(QDate(current.year(), current.month()-1, 1)),
+                QDateTime(QDate(current.year(), current.month(), 1)));
+        break;
+    case ThisYear:
+        transactionProxyModel->setDateRange(
+                QDateTime(QDate(current.year(), 1, 1)),
+                TransactionFilterProxy::MAX_DATE);
+        break;
+    case Range:
+        dateRangeWidget->setVisible(true);
+        dateRangeChanged();
+        break;
+    }
+}
+
+void TransactionView::chooseType(int idx)
+{
+    transactionProxyModel->setTypeFilter(
+        typeWidget->itemData(idx).toInt());
+}
+
+void TransactionView::changedPrefix(const QString &prefix)
+{
+    transactionProxyModel->setAddressPrefix(prefix);
+}
+
+void TransactionView::changedAmount(const QString &amount)
+{
+    qint64 amount_parsed = 0;
+    if(BitcoinUnits::parse(model->getOptionsModel()->getDisplayUnit(), amount, &amount_parsed))
+    {
+        transactionProxyModel->setMinAmount(amount_parsed);
+    }
+    else
+    {
+        transactionProxyModel->setMinAmount(0);
+    }
+}
+
+void TransactionView::exportClicked()
+{
+    // CSV is currently the only supported format
+    QString filename = QFileDialog::getSaveFileName(
+            this,
+            tr("Export Transaction Data"),
+            QDir::currentPath(),
+            tr("Comma separated file (*.csv)"));
+
+    if (filename.isNull()) return;
+
+    CSVModelWriter writer(filename);
+
+    // name, column, role
+    writer.setModel(transactionProxyModel);
+    writer.addColumn(tr("Confirmed"), 0, TransactionTableModel::ConfirmedRole);
+    writer.addColumn(tr("Date"), 0, TransactionTableModel::DateRole);
+    writer.addColumn(tr("Type"), TransactionTableModel::Type, Qt::EditRole);
+    writer.addColumn(tr("Label"), 0, TransactionTableModel::LabelRole);
+    writer.addColumn(tr("Address"), 0, TransactionTableModel::AddressRole);
+    writer.addColumn(tr("Amount"), 0, TransactionTableModel::FormattedAmountRole);
+    writer.addColumn(tr("ID"), 0, TransactionTableModel::TxIDRole);
+
+    if(!writer.write())
+    {
+        QMessageBox::critical(this, tr("Error exporting"), tr("Could not write to file %1.").arg(filename),
+                              QMessageBox::Abort, QMessageBox::Abort);
+    }
+}
+
+void TransactionView::contextualMenu(const QPoint &point)
+{
+    QModelIndex index = transactionView->indexAt(point);
+    if(index.isValid())
+    {
+        contextMenu->exec(QCursor::pos());
+    }
+}
+
+void TransactionView::copyAddress()
+{
+    QModelIndexList selection = transactionView->selectionModel()->selectedRows();
+    if(!selection.isEmpty())
+    {
+        QApplication::clipboard()->setText(selection.at(0).data(TransactionTableModel::AddressRole).toString());
+    }
+}
+
+void TransactionView::copyLabel()
+{
+    QModelIndexList selection = transactionView->selectionModel()->selectedRows();
+    if(!selection.isEmpty())
+    {
+        QApplication::clipboard()->setText(selection.at(0).data(TransactionTableModel::LabelRole).toString());
+    }
+}
+
+void TransactionView::editLabel()
+{
+    QModelIndexList selection = transactionView->selectionModel()->selectedRows();
+    if(!selection.isEmpty())
+    {
+        AddressTableModel *addressBook = model->getAddressTableModel();
+        QString address = selection.at(0).data(TransactionTableModel::AddressRole).toString();
+        if(address.isEmpty())
+        {
+            // If this transaction has no associated address, exit
+            return;
+        }
+        int idx = addressBook->lookupAddress(address);
+        if(idx != -1)
+        {
+            // Edit sending / receiving address
+            QModelIndex modelIdx = addressBook->index(idx, 0, QModelIndex());
+            // Determine type of address, launch appropriate editor dialog type
+            QString type = modelIdx.data(AddressTableModel::TypeRole).toString();
+
+            EditAddressDialog dlg(type==AddressTableModel::Receive
+                                         ? EditAddressDialog::EditReceivingAddress
+                                         : EditAddressDialog::EditSendingAddress,
+                                  this);
+            dlg.setModel(addressBook);
+            dlg.loadRow(idx);
+            dlg.exec();
+        }
+        else
+        {
+            // Add sending address
+            EditAddressDialog dlg(EditAddressDialog::NewSendingAddress,
+                                  this);
+            dlg.exec();
+        }
+    }
+}
+
+void TransactionView::showDetails()
+{
+    QModelIndexList selection = transactionView->selectionModel()->selectedRows();
+    if(!selection.isEmpty())
+    {
+        TransactionDescDialog dlg(selection.at(0));
+        dlg.exec();
+    }
+}
+
+QWidget *TransactionView::createDateRangeWidget()
+{
+    dateRangeWidget = new QFrame();
+    dateRangeWidget->setFrameStyle(QFrame::Panel | QFrame::Raised);
+    dateRangeWidget->setContentsMargins(1,1,1,1);
+    QHBoxLayout *layout = new QHBoxLayout(dateRangeWidget);
+    layout->setContentsMargins(0,0,0,0);
+    layout->addSpacing(23);
+    layout->addWidget(new QLabel(tr("Range:")));
+
+    dateFrom = new QDateTimeEdit(this);
+    dateFrom->setDisplayFormat("dd/MM/yy");
+    dateFrom->setCalendarPopup(true);
+    dateFrom->setMinimumWidth(100);
+    dateFrom->setDate(QDate::currentDate().addDays(-7));
+    layout->addWidget(dateFrom);
+    layout->addWidget(new QLabel(tr("to")));
+
+    dateTo = new QDateTimeEdit(this);
+    dateTo->setDisplayFormat("dd/MM/yy");
+    dateTo->setCalendarPopup(true);
+    dateTo->setMinimumWidth(100);
+    dateTo->setDate(QDate::currentDate());
+    layout->addWidget(dateTo);
+    layout->addStretch();
+
+    // Hide by default
+    dateRangeWidget->setVisible(false);
+
+    // Notify on change
+    connect(dateFrom, SIGNAL(dateChanged(QDate)), this, SLOT(dateRangeChanged()));
+    connect(dateTo, SIGNAL(dateChanged(QDate)), this, SLOT(dateRangeChanged()));
+
+    return dateRangeWidget;
+}
+
+void TransactionView::dateRangeChanged()
+{
+    transactionProxyModel->setDateRange(
+            QDateTime(dateFrom->date()),
+            QDateTime(dateTo->date()).addDays(1));
+}
diff --git a/src/qt/transactionview.h b/src/qt/transactionview.h
new file mode 100644 (file)
index 0000000..f4f815b
--- /dev/null
@@ -0,0 +1,77 @@
+#ifndef TRANSACTIONVIEW_H
+#define TRANSACTIONVIEW_H
+
+#include <QWidget>
+
+class WalletModel;
+class TransactionFilterProxy;
+
+QT_BEGIN_NAMESPACE
+class QTableView;
+class QComboBox;
+class QLineEdit;
+class QModelIndex;
+class QMenu;
+class QFrame;
+class QDateTimeEdit;
+QT_END_NAMESPACE
+
+class TransactionView : public QWidget
+{
+    Q_OBJECT
+public:
+    explicit TransactionView(QWidget *parent = 0);
+
+    void setModel(WalletModel *model);
+
+    // Date ranges for filter
+    enum DateEnum
+    {
+        All,
+        Today,
+        ThisWeek,
+        ThisMonth,
+        LastMonth,
+        ThisYear,
+        Range
+    };
+
+private:
+    WalletModel *model;
+    TransactionFilterProxy *transactionProxyModel;
+    QTableView *transactionView;
+
+    QComboBox *dateWidget;
+    QComboBox *typeWidget;
+    QLineEdit *addressWidget;
+    QLineEdit *amountWidget;
+
+    QMenu *contextMenu;
+
+    QFrame *dateRangeWidget;
+    QDateTimeEdit *dateFrom;
+    QDateTimeEdit *dateTo;
+
+    QWidget *createDateRangeWidget();
+
+private slots:
+    void contextualMenu(const QPoint &);
+    void dateRangeChanged();
+
+signals:
+    void doubleClicked(const QModelIndex&);
+
+public slots:
+    void chooseDate(int idx);
+    void chooseType(int idx);
+    void changedPrefix(const QString &prefix);
+    void changedAmount(const QString &amount);
+    void exportClicked();
+    void showDetails();
+    void copyAddress();
+    void editLabel();
+    void copyLabel();
+
+};
+
+#endif // TRANSACTIONVIEW_H
diff --git a/src/qt/walletmodel.cpp b/src/qt/walletmodel.cpp
new file mode 100644 (file)
index 0000000..2f98966
--- /dev/null
@@ -0,0 +1,277 @@
+#include "walletmodel.h"
+#include "guiconstants.h"
+#include "optionsmodel.h"
+#include "addresstablemodel.h"
+#include "transactiontablemodel.h"
+
+#include "headers.h"
+
+#include <QTimer>
+#include <QSet>
+
+WalletModel::WalletModel(CWallet *wallet, OptionsModel *optionsModel, QObject *parent) :
+    QObject(parent), wallet(wallet), optionsModel(optionsModel), addressTableModel(0),
+    transactionTableModel(0),
+    cachedBalance(0), cachedUnconfirmedBalance(0), cachedNumTransactions(0),
+    cachedEncryptionStatus(Unencrypted)
+{
+    // Until signal notifications is built into the bitcoin core,
+    //  simply update everything after polling using a timer.
+    QTimer *timer = new QTimer(this);
+    connect(timer, SIGNAL(timeout()), this, SLOT(update()));
+    timer->start(MODEL_UPDATE_DELAY);
+
+    addressTableModel = new AddressTableModel(wallet, this);
+    transactionTableModel = new TransactionTableModel(wallet, this);
+}
+
+qint64 WalletModel::getBalance() const
+{
+    return wallet->GetBalance();
+}
+
+qint64 WalletModel::getUnconfirmedBalance() const
+{
+    return wallet->GetUnconfirmedBalance();
+}
+
+int WalletModel::getNumTransactions() const
+{
+    int numTransactions = 0;
+    CRITICAL_BLOCK(wallet->cs_wallet)
+    {
+        numTransactions = wallet->mapWallet.size();
+    }
+    return numTransactions;
+}
+
+void WalletModel::update()
+{
+    qint64 newBalance = getBalance();
+    qint64 newUnconfirmedBalance = getUnconfirmedBalance();
+    int newNumTransactions = getNumTransactions();
+    EncryptionStatus newEncryptionStatus = getEncryptionStatus();
+
+    if(cachedBalance != newBalance || cachedUnconfirmedBalance != newUnconfirmedBalance)
+        emit balanceChanged(newBalance, newUnconfirmedBalance);
+
+    if(cachedNumTransactions != newNumTransactions)
+        emit numTransactionsChanged(newNumTransactions);
+
+    if(cachedEncryptionStatus != newEncryptionStatus)
+        emit encryptionStatusChanged(newEncryptionStatus);
+
+    cachedBalance = newBalance;
+    cachedUnconfirmedBalance = newUnconfirmedBalance;
+    cachedNumTransactions = newNumTransactions;
+
+    addressTableModel->update();
+}
+
+bool WalletModel::validateAddress(const QString &address)
+{
+    CBitcoinAddress addressParsed(address.toStdString());
+    return addressParsed.IsValid();
+}
+
+WalletModel::SendCoinsReturn WalletModel::sendCoins(const QList<SendCoinsRecipient> &recipients)
+{
+    qint64 total = 0;
+    QSet<QString> setAddress;
+    QString hex;
+
+    if(recipients.empty())
+    {
+        return OK;
+    }
+
+    // Pre-check input data for validity
+    foreach(const SendCoinsRecipient &rcp, recipients)
+    {
+        if(!validateAddress(rcp.address))
+        {
+            return InvalidAddress;
+        }
+        setAddress.insert(rcp.address);
+
+        if(rcp.amount <= 0)
+        {
+            return InvalidAmount;
+        }
+        total += rcp.amount;
+    }
+
+    if(recipients.size() > setAddress.size())
+    {
+        return DuplicateAddress;
+    }
+
+    if(total > getBalance())
+    {
+        return AmountExceedsBalance;
+    }
+
+    if((total + nTransactionFee) > getBalance())
+    {
+        return SendCoinsReturn(AmountWithFeeExceedsBalance, nTransactionFee);
+    }
+
+    CRITICAL_BLOCK(cs_main)
+    CRITICAL_BLOCK(wallet->cs_wallet)
+    {
+        // Sendmany
+        std::vector<std::pair<CScript, int64> > vecSend;
+        foreach(const SendCoinsRecipient &rcp, recipients)
+        {
+            CScript scriptPubKey;
+            scriptPubKey.SetBitcoinAddress(rcp.address.toStdString());
+            vecSend.push_back(make_pair(scriptPubKey, rcp.amount));
+        }
+
+        CWalletTx wtx;
+        CReserveKey keyChange(wallet);
+        int64 nFeeRequired = 0;
+        bool fCreated = wallet->CreateTransaction(vecSend, wtx, keyChange, nFeeRequired);
+
+        if(!fCreated)
+        {
+            if((total + nFeeRequired) > wallet->GetBalance())
+            {
+                return SendCoinsReturn(AmountWithFeeExceedsBalance, nFeeRequired);
+            }
+            return TransactionCreationFailed;
+        }
+        if(!ThreadSafeAskFee(nFeeRequired, tr("Sending...").toStdString(), NULL))
+        {
+            return Aborted;
+        }
+        if(!wallet->CommitTransaction(wtx, keyChange))
+        {
+            return TransactionCommitFailed;
+        }
+        hex = QString::fromStdString(wtx.GetHash().GetHex());
+    }
+
+    // Add addresses that we've sent to to the address book
+    foreach(const SendCoinsRecipient &rcp, recipients)
+    {
+        std::string strAddress = rcp.address.toStdString();
+        CRITICAL_BLOCK(wallet->cs_wallet)
+        {
+            if (!wallet->mapAddressBook.count(strAddress))
+                wallet->SetAddressBookName(strAddress, rcp.label.toStdString());
+        }
+    }
+
+    // Update our model of the address table
+    addressTableModel->updateList();
+
+    return SendCoinsReturn(OK, 0, hex);
+}
+
+OptionsModel *WalletModel::getOptionsModel()
+{
+    return optionsModel;
+}
+
+AddressTableModel *WalletModel::getAddressTableModel()
+{
+    return addressTableModel;
+}
+
+TransactionTableModel *WalletModel::getTransactionTableModel()
+{
+    return transactionTableModel;
+}
+
+WalletModel::EncryptionStatus WalletModel::getEncryptionStatus() const
+{
+    if(!wallet->IsCrypted())
+    {
+        return Unencrypted;
+    }
+    else if(wallet->IsLocked())
+    {
+        return Locked;
+    }
+    else
+    {
+        return Unlocked;
+    }
+}
+
+bool WalletModel::setWalletEncrypted(bool encrypted, const std::string &passphrase)
+{
+    if(encrypted)
+    {
+        // Encrypt
+        return wallet->EncryptWallet(passphrase);
+    }
+    else
+    {
+        // Decrypt -- TODO; not supported yet
+        return false;
+    }
+}
+
+bool WalletModel::setWalletLocked(bool locked, const std::string &passPhrase)
+{
+    if(locked)
+    {
+        // Lock
+        return wallet->Lock();
+    }
+    else
+    {
+        // Unlock
+        return wallet->Unlock(passPhrase);
+    }
+}
+
+bool WalletModel::changePassphrase(const std::string &oldPass, const std::string &newPass)
+{
+    bool retval;
+    CRITICAL_BLOCK(wallet->cs_wallet)
+    {
+        wallet->Lock(); // Make sure wallet is locked before attempting pass change
+        retval = wallet->ChangeWalletPassphrase(oldPass, newPass);
+    }
+    return retval;
+}
+
+// WalletModel::UnlockContext implementation
+WalletModel::UnlockContext WalletModel::requestUnlock()
+{
+    bool was_locked = getEncryptionStatus() == Locked;
+    if(was_locked)
+    {
+        // Request UI to unlock wallet
+        emit requireUnlock();
+    }
+    // If wallet is still locked, unlock was failed or cancelled, mark context as invalid
+    bool valid = getEncryptionStatus() != Locked;
+
+    return UnlockContext(this, valid, was_locked);
+}
+
+WalletModel::UnlockContext::UnlockContext(WalletModel *wallet, bool valid, bool relock):
+        wallet(wallet),
+        valid(valid),
+        relock(relock)
+{
+}
+
+WalletModel::UnlockContext::~UnlockContext()
+{
+    if(valid && relock)
+    {
+        wallet->setWalletLocked(true);
+    }
+}
+
+void WalletModel::UnlockContext::CopyFrom(const UnlockContext& rhs)
+{
+    // Transfer context; old object no longer relocks wallet
+    *this = rhs;
+    rhs.relock = false;
+}
diff --git a/src/qt/walletmodel.h b/src/qt/walletmodel.h
new file mode 100644 (file)
index 0000000..b7b6973
--- /dev/null
@@ -0,0 +1,143 @@
+#ifndef WALLETMODEL_H
+#define WALLETMODEL_H
+
+#include <QObject>
+#include <string>
+
+class OptionsModel;
+class AddressTableModel;
+class TransactionTableModel;
+class CWallet;
+
+struct SendCoinsRecipient
+{
+    QString address;
+    QString label;
+    qint64 amount;
+};
+
+// Interface to Bitcoin wallet from Qt view code
+class WalletModel : public QObject
+{
+    Q_OBJECT
+public:
+    explicit WalletModel(CWallet *wallet, OptionsModel *optionsModel, QObject *parent = 0);
+
+    enum StatusCode // Returned by sendCoins
+    {
+        OK,
+        InvalidAmount,
+        InvalidAddress,
+        AmountExceedsBalance,
+        AmountWithFeeExceedsBalance,
+        DuplicateAddress,
+        TransactionCreationFailed, // Error returned when wallet is still locked
+        TransactionCommitFailed,
+        Aborted,
+        MiscError
+    };
+
+    enum EncryptionStatus
+    {
+        Unencrypted,  // !wallet->IsCrypted()
+        Locked,       // wallet->IsCrypted() && wallet->IsLocked()
+        Unlocked      // wallet->IsCrypted() && !wallet->IsLocked()
+    };
+
+    OptionsModel *getOptionsModel();
+    AddressTableModel *getAddressTableModel();
+    TransactionTableModel *getTransactionTableModel();
+
+    qint64 getBalance() const;
+    qint64 getUnconfirmedBalance() const;
+    int getNumTransactions() const;
+    EncryptionStatus getEncryptionStatus() const;
+
+    // Check address for validity
+    bool validateAddress(const QString &address);
+
+    // Return status record for SendCoins, contains error id + information
+    struct SendCoinsReturn
+    {
+        SendCoinsReturn(StatusCode status,
+                         qint64 fee=0,
+                         QString hex=QString()):
+            status(status), fee(fee), hex(hex) {}
+        StatusCode status;
+        qint64 fee; // is used in case status is "AmountWithFeeExceedsBalance"
+        QString hex; // is filled with the transaction hash if status is "OK"
+    };
+
+    // Send coins to a list of recipients
+    SendCoinsReturn sendCoins(const QList<SendCoinsRecipient> &recipients);
+
+    // Wallet encryption
+    bool setWalletEncrypted(bool encrypted, const std::string &passphrase);
+    // Passphrase only needed when unlocking
+    bool setWalletLocked(bool locked, const std::string &passPhrase=std::string());
+    bool changePassphrase(const std::string &oldPass, const std::string &newPass);
+
+    // RAI object for unlocking wallet, returned by requestUnlock()
+    class UnlockContext
+    {
+    public:
+        UnlockContext(WalletModel *wallet, bool valid, bool relock);
+        ~UnlockContext();
+
+        bool isValid() const { return valid; }
+
+        // Copy operator and constructor transfer the context
+        UnlockContext(const UnlockContext& obj) { CopyFrom(obj); }
+        UnlockContext& operator=(const UnlockContext& rhs) { CopyFrom(rhs); return *this; }
+    private:
+        WalletModel *wallet;
+        bool valid;
+        mutable bool relock; // mutable, as it can be set to false by copying
+
+        void CopyFrom(const UnlockContext& rhs);
+    };
+
+    UnlockContext requestUnlock();
+
+private:
+    CWallet *wallet;
+
+    // Wallet has an options model for wallet-specific options
+    // (transaction fee, for example)
+    OptionsModel *optionsModel;
+
+    AddressTableModel *addressTableModel;
+    TransactionTableModel *transactionTableModel;
+
+    // Cache some values to be able to detect changes
+    qint64 cachedBalance;
+    qint64 cachedUnconfirmedBalance;
+    qint64 cachedNumTransactions;
+    EncryptionStatus cachedEncryptionStatus;
+
+signals:
+    // Signal that balance in wallet changed
+    void balanceChanged(qint64 balance, qint64 unconfirmedBalance);
+
+    // Number of transactions in wallet changed
+    void numTransactionsChanged(int count);
+
+    // Encryption status of wallet changed
+    void encryptionStatusChanged(int status);
+
+    // Signal emitted when wallet needs to be unlocked
+    // It is valid behaviour for listeners to keep the wallet locked after this signal;
+    // this means that the unlocking failed or was cancelled.
+    void requireUnlock();
+
+    // Asynchronous error notification
+    void error(const QString &title, const QString &message);
+
+public slots:
+
+private slots:
+    void update();
+};
+
+
+#endif // WALLETMODEL_H
diff --git a/src/qtui.h b/src/qtui.h
new file mode 100644 (file)
index 0000000..17fc44e
--- /dev/null
@@ -0,0 +1,49 @@
+// Copyright (c) 2010 Satoshi Nakamoto
+// Distributed under the MIT/X11 software license, see the accompanying
+// file license.txt or http://www.opensource.org/licenses/mit-license.php.
+#ifndef BITCOIN_EXTERNUI_H
+#define BITCOIN_EXTERNUI_H
+
+#include <string>
+#include <boost/function/function0.hpp>
+#include "wallet.h"
+
+typedef void wxWindow;
+#define wxYES                   0x00000002
+#define wxOK                    0x00000004
+#define wxNO                    0x00000008
+#define wxYES_NO                (wxYES|wxNO)
+#define wxCANCEL                0x00000010
+#define wxAPPLY                 0x00000020
+#define wxCLOSE                 0x00000040
+#define wxOK_DEFAULT            0x00000000
+#define wxYES_DEFAULT           0x00000000
+#define wxNO_DEFAULT            0x00000080
+#define wxCANCEL_DEFAULT        0x80000000
+#define wxICON_EXCLAMATION      0x00000100
+#define wxICON_HAND             0x00000200
+#define wxICON_WARNING          wxICON_EXCLAMATION
+#define wxICON_ERROR            wxICON_HAND
+#define wxICON_QUESTION         0x00000400
+#define wxICON_INFORMATION      0x00000800
+#define wxICON_STOP             wxICON_HAND
+#define wxICON_ASTERISK         wxICON_INFORMATION
+#define wxICON_MASK             (0x00000100|0x00000200|0x00000400|0x00000800)
+#define wxFORWARD               0x00001000
+#define wxBACKWARD              0x00002000
+#define wxRESET                 0x00004000
+#define wxHELP                  0x00008000
+#define wxMORE                  0x00010000
+#define wxSETUP                 0x00020000
+
+extern int MyMessageBox(const std::string& message, const std::string& caption="Message", int style=wxOK, wxWindow* parent=NULL, int x=-1, int y=-1);
+#define wxMessageBox  MyMessageBox
+extern int ThreadSafeMessageBox(const std::string& message, const std::string& caption, int style=wxOK, wxWindow* parent=NULL, int x=-1, int y=-1);
+extern bool ThreadSafeAskFee(int64 nFeeRequired, const std::string& strCaption, wxWindow* parent);
+extern void CalledSetStatusBar(const std::string& strText, int nField);
+extern void UIThreadCall(boost::function0<void> fn);
+extern void MainFrameRepaint();
+extern void InitMessage(const std::string &message);
+extern std::string _(const char* psz);
+
+#endif
index 6e7bcb5..12d3f9e 100644 (file)
@@ -1132,6 +1132,7 @@ bool static ExtractAddressInner(const CScript& scriptPubKey, const CKeyStore* ke
         if (keystore == NULL || keystore->HaveKey(addressRet))
             return true;
     }
+
     return false;
 }
 
index 698bdfe..64f67fd 100644 (file)
@@ -31,6 +31,7 @@ typedef unsigned long long  uint64;
 #endif
 
 #ifdef __WXMSW__
+#include <windows.h>
 // This is used to attempt to keep keying material out of swap
 // Note that VirtualLock does not provide this as a guarantee on Windows,
 // but, in practice, memory that has been VirtualLock'd almost never gets written to
diff --git a/src/test/DoS_tests.cpp b/src/test/DoS_tests.cpp
new file mode 100644 (file)
index 0000000..e60bb74
--- /dev/null
@@ -0,0 +1,68 @@
+//
+// Unit tests for denial-of-service detection/prevention code
+//
+#include <boost/test/unit_test.hpp>
+#include <boost/foreach.hpp>
+
+#include "../main.h"
+#include "../net.h"
+#include "../util.h"
+
+using namespace std;
+
+BOOST_AUTO_TEST_SUITE(DoS_tests)
+
+BOOST_AUTO_TEST_CASE(DoS_banning)
+{
+    CNode::ClearBanned();
+    CAddress addr1(0xa0b0c001);
+    CNode dummyNode1(INVALID_SOCKET, addr1, true);
+    dummyNode1.Misbehaving(100); // Should get banned
+    BOOST_CHECK(CNode::IsBanned(addr1.ip));
+    BOOST_CHECK(!CNode::IsBanned(addr1.ip|0x0000ff00)); // Different ip, not banned
+
+    CAddress addr2(0xa0b0c002);
+    CNode dummyNode2(INVALID_SOCKET, addr2, true);
+    dummyNode2.Misbehaving(50);
+    BOOST_CHECK(!CNode::IsBanned(addr2.ip)); // 2 not banned yet...
+    BOOST_CHECK(CNode::IsBanned(addr1.ip));  // ... but 1 still should be
+    dummyNode2.Misbehaving(50);
+    BOOST_CHECK(CNode::IsBanned(addr2.ip));
+}    
+
+BOOST_AUTO_TEST_CASE(DoS_banscore)
+{
+    CNode::ClearBanned();
+    mapArgs["-banscore"] = "111"; // because 11 is my favorite number
+    CAddress addr1(0xa0b0c001);
+    CNode dummyNode1(INVALID_SOCKET, addr1, true);
+    dummyNode1.Misbehaving(100);
+    BOOST_CHECK(!CNode::IsBanned(addr1.ip));
+    dummyNode1.Misbehaving(10);
+    BOOST_CHECK(!CNode::IsBanned(addr1.ip));
+    dummyNode1.Misbehaving(1);
+    BOOST_CHECK(CNode::IsBanned(addr1.ip));
+    mapArgs["-banscore"] = "100";
+}
+
+BOOST_AUTO_TEST_CASE(DoS_bantime)
+{
+    CNode::ClearBanned();
+    int64 nStartTime = GetTime();
+    SetMockTime(nStartTime); // Overrides future calls to GetTime()
+
+    CAddress addr(0xa0b0c001);
+    CNode dummyNode(INVALID_SOCKET, addr, true);
+
+    dummyNode.Misbehaving(100);
+    BOOST_CHECK(CNode::IsBanned(addr.ip));
+
+    SetMockTime(nStartTime+60*60);
+    BOOST_CHECK(CNode::IsBanned(addr.ip));
+
+    SetMockTime(nStartTime+60*60*24+1);
+    BOOST_CHECK(!CNode::IsBanned(addr.ip));
+}    
+
+
+BOOST_AUTO_TEST_SUITE_END()
index 0230bb6..c6f6d94 100644 (file)
@@ -8,7 +8,7 @@
 #include "uint256_tests.cpp"
 #include "script_tests.cpp"
 #include "transaction_tests.cpp"
-
+#include "DoS_tests.cpp"
 
 CWallet* pwalletMain;
 
index 2a128a7..1784af7 100644 (file)
--- a/src/ui.h
+++ b/src/ui.h
@@ -24,7 +24,9 @@ void CalledSetStatusBar(const std::string& strText, int nField);
 void MainFrameRepaint();
 void CreateMainWindow();
 void SetStartOnSystemStartup(bool fAutoStart);
-
+inline void InitMessage(const std::string &message)
+{
+}
 
 
 
index 76a2700..80095fe 100644 (file)
@@ -264,8 +264,7 @@ int my_snprintf(char* buffer, size_t limit, const char* format, ...)
     return ret;
 }
 
-
-string strprintf(const char* format, ...)
+string strprintf(const std::string &format, ...)
 {
     char buffer[50000];
     char* p = buffer;
@@ -275,7 +274,7 @@ string strprintf(const char* format, ...)
     {
         va_list arg_ptr;
         va_start(arg_ptr, format);
-        ret = _vsnprintf(p, limit, format, arg_ptr);
+        ret = _vsnprintf(p, limit, format.c_str(), arg_ptr);
         va_end(arg_ptr);
         if (ret >= 0 && ret < limit)
             break;
@@ -292,14 +291,13 @@ string strprintf(const char* format, ...)
     return str;
 }
 
-
-bool error(const char* format, ...)
+bool error(const std::string &format, ...)
 {
     char buffer[50000];
     int limit = sizeof(buffer);
     va_list arg_ptr;
     va_start(arg_ptr, format);
-    int ret = _vsnprintf(buffer, limit, format, arg_ptr);
+    int ret = _vsnprintf(buffer, limit, format.c_str(), arg_ptr);
     va_end(arg_ptr);
     if (ret < 0 || ret >= limit)
     {
@@ -815,11 +813,20 @@ void ShrinkDebugFile()
 //  - Median of other nodes's clocks
 //  - The user (asking the user to fix the system clock if the first two disagree)
 //
+static int64 nMockTime = 0;  // For unit testing
+
 int64 GetTime()
 {
+    if (nMockTime) return nMockTime;
+
     return time(NULL);
 }
 
+void SetMockTime(int64 nMockTimeIn)
+{
+    nMockTime = nMockTimeIn;
+}
+
 static int64 nTimeOffset = 0;
 
 int64 GetAdjustedTime()
index 3d7ef10..dd5c411 100644 (file)
@@ -65,7 +65,7 @@ typedef unsigned long long  uint64;
 #endif
 
 // This is needed because the foreach macro can't get over the comma in pair<t1, t2>
-#define PAIRTYPE(t1, t2)    pair<t1, t2>
+#define PAIRTYPE(t1, t2)    std::pair<t1, t2>
 
 // Align by increasing pointer, must have extra space at end of buffer
 template <size_t nBytes, typename T>
@@ -132,8 +132,7 @@ inline int myclosesocket(SOCKET& hSocket)
     return ret;
 }
 #define closesocket(s)      myclosesocket(s)
-
-#ifndef GUI
+#if !defined(QT_GUI) && !defined(GUI)
 inline const char* _(const char* psz)
 {
     return psz;
@@ -148,7 +147,6 @@ inline const char* _(const char* psz)
 
 
 
-
 extern std::map<std::string, std::string> mapArgs;
 extern std::map<std::string, std::vector<std::string> > mapMultiArgs;
 extern bool fDebug;
@@ -169,8 +167,8 @@ void RandAddSeed();
 void RandAddSeedPerfmon();
 int OutputDebugStringF(const char* pszFormat, ...);
 int my_snprintf(char* buffer, size_t limit, const char* format, ...);
-std::string strprintf(const char* format, ...);
-bool error(const char* format, ...);
+std::string strprintf(const std::string &format, ...);
+bool error(const std::string &format, ...);
 void LogException(std::exception* pex, const char* pszThread);
 void PrintException(std::exception* pex, const char* pszThread);
 void PrintExceptionContinue(std::exception* pex, const char* pszThread);
@@ -199,6 +197,7 @@ void ShrinkDebugFile();
 int GetRandInt(int nMax);
 uint64 GetRand(uint64 nMax);
 int64 GetTime();
+void SetMockTime(int64 nMockTimeIn);
 int64 GetAdjustedTime();
 void AddTimeData(unsigned int ip, int64 nTime);
 std::string FormatFullVersion();
index 8bbb80c..d78e470 100644 (file)
@@ -260,7 +260,7 @@ bool CWallet::AddToWallet(const CWalletTx& wtxIn)
         if (fInsertedNew || fUpdated)
             if (!wtx.WriteToDisk())
                 return false;
-
+#ifndef QT_GUI
         // If default receiving address gets used, replace it with a new one
         CScript scriptDefaultKey;
         scriptDefaultKey.SetBitcoinAddress(vchDefaultKey);
@@ -276,7 +276,7 @@ bool CWallet::AddToWallet(const CWalletTx& wtxIn)
                 }
             }
         }
-
+#endif
         // Notify UI
         vWalletUpdated.push_back(hash);
 
@@ -728,6 +728,21 @@ int64 CWallet::GetBalance() const
     return nTotal;
 }
 
+int64 CWallet::GetUnconfirmedBalance() const
+{
+    int64 nTotal = 0;
+    CRITICAL_BLOCK(cs_wallet)
+    {
+        for (map<uint256, CWalletTx>::const_iterator it = mapWallet.begin(); it != mapWallet.end(); ++it)
+        {
+            const CWalletTx* pcoin = &(*it).second;
+            if (pcoin->IsFinal() && pcoin->IsConfirmed())
+                continue;
+            nTotal += pcoin->GetAvailableCredit();
+        }
+    }
+    return nTotal;
+}
 
 bool CWallet::SelectCoinsMinConf(int64 nTargetValue, int nConfMine, int nConfTheirs, set<pair<const CWalletTx*,unsigned int> >& setCoinsRet, int64& nValueRet) const
 {
index 1dd2e51..b6df1aa 100644 (file)
@@ -74,6 +74,7 @@ public:
     void ReacceptWalletTransactions();
     void ResendWalletTransactions();
     int64 GetBalance() const;
+    int64 GetUnconfirmedBalance() const;
     bool CreateTransaction(const std::vector<std::pair<CScript, int64> >& vecSend, CWalletTx& wtxNew, CReserveKey& reservekey, int64& nFeeRet);
     bool CreateTransaction(CScript scriptPubKey, int64 nValue, CWalletTx& wtxNew, CReserveKey& reservekey, int64& nFeeRet);
     bool CommitTransaction(CWalletTx& wtxNew, CReserveKey& reservekey);