diff options
| author | Jonas Schnelli <[email protected]> | 2013-05-03 16:14:38 +0200 |
|---|---|---|
| committer | Jonas Schnelli <[email protected]> | 2013-05-03 16:14:38 +0200 |
| commit | 367491df9d4a4e323a9d20fc118446ddccf08e11 (patch) | |
| tree | f5bfde01999cf994eb84821baddf1a8464613eed /src/qt/bitcoin.cpp | |
| parent | Merge pull request #2608 from jonasschnelli/pathCacheFix (diff) | |
| download | discoin-367491df9d4a4e323a9d20fc118446ddccf08e11.tar.xz discoin-367491df9d4a4e323a9d20fc118446ddccf08e11.zip | |
osx: show testnet icon in dock as early as possible
A green testnet splashscreen with a normal, orange dock icon looks strange and can confuse users.
Signed-off-by: Jonas Schnelli <[email protected]>
Diffstat (limited to 'src/qt/bitcoin.cpp')
| -rw-r--r-- | src/qt/bitcoin.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/qt/bitcoin.cpp b/src/qt/bitcoin.cpp index 25448ea8c..1083f9bfe 100644 --- a/src/qt/bitcoin.cpp +++ b/src/qt/bitcoin.cpp @@ -23,6 +23,10 @@ #include <QTranslator> #include <QLibraryInfo> +#ifdef Q_OS_MAC +#include "macdockiconhandler.h" +#endif + #if defined(BITCOIN_NEED_QT_PLUGINS) && !defined(_BITCOIN_QT_PLUGINS_INCLUDED) #define _BITCOIN_QT_PLUGINS_INCLUDED #define __INSURE__ @@ -198,6 +202,13 @@ int main(int argc, char *argv[]) return 1; } +#ifdef Q_OS_MAC + // on mac, also change the icon now because it would look strange to have a testnet splash (green) and a std app icon (orange) + if(GetBoolArg("-testnet")) { + MacDockIconHandler::instance()->setIcon(QIcon(":icons/bitcoin_testnet")); + } +#endif + SplashScreen splash(QPixmap(), 0); if (GetBoolArg("-splash", true) && !GetBoolArg("-min")) { |