diff --git a/contrib/debian/copyright b/contrib/debian/copyright index b99604913c..220a35212c 100644 --- a/contrib/debian/copyright +++ b/contrib/debian/copyright @@ -71,7 +71,7 @@ Copyright: Bitboy (optimized for 16x16 by Wladimir van der Laan) License: PUB-DOM Comment: Site: https://bitcointalk.org/?topic=1756.0 -Files: scripts/img/reload.xcf, src/qt/res/movies/update_spinner.mng +Files: scripts/img/reload.xcf, src/qt/res/movies/*.png Copyright: Everaldo (Everaldo Coelho) License: GPL-3+ Comment: Icon Pack: Kids diff --git a/doc/assets-attribution.md b/doc/assets-attribution.md index b095491285..d42be8fb24 100644 --- a/doc/assets-attribution.md +++ b/doc/assets-attribution.md @@ -76,7 +76,7 @@ Everaldo (Everaldo Coelho) * Site: [http://findicons.com/icon/17102/reload?id=17102](http://findicons.com/icon/17102/reload?id=17102) ### Assets Used - scripts/img/reload.xcf (modified), src/qt/res/movies/update_spinner.mng + scripts/img/reload.xcf (modified), src/qt/res/movies/*.png [Vignoni David](http://www.oxygen-icons.org) ----------------------- @@ -101,4 +101,4 @@ Jonas Schnelli src/qt/res/src/bitcoin.ico, src/qt/res/src/bitcoin.png, src/qt/res/src/bitcoin_testnet.png, docs/bitcoin_logo_doxygen.png, src/qt/res/icons/toolbar.png, src/qt/res/icons/toolbar_testnet.png, - src/qt/res/images/splash.png, src/qt/res/images/splash_testnet.png \ No newline at end of file + src/qt/res/images/splash.png, src/qt/res/images/splash_testnet.png diff --git a/share/qt/img/reload.png b/share/qt/img/reload.png new file mode 100644 index 0000000000..9068db9a63 Binary files /dev/null and b/share/qt/img/reload.png differ diff --git a/share/qt/make_spinner.py b/share/qt/make_spinner.py index 136aff3cb7..bb19e91508 100755 --- a/share/qt/make_spinner.py +++ b/share/qt/make_spinner.py @@ -1,16 +1,15 @@ #!/usr/bin/env python # W.J. van der Laan, 2011 -# Make spinning .mng animation from a .png +# Make spinning 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' +SRC='img/reload.png' +TMPDIR='../../src/qt/res/movies/' +TMPNAME='spinner-%03i.png' NUMFRAMES=35 FRAMERATE=10.0 CONVERT='convert' @@ -36,8 +35,4 @@ for frame in xrange(NUMFRAMES): 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/src/qt/Makefile.am b/src/qt/Makefile.am index deed59bebd..274cebcf3a 100644 --- a/src/qt/Makefile.am +++ b/src/qt/Makefile.am @@ -303,7 +303,7 @@ RES_IMAGES = \ res/images/splash.png \ res/images/splash_testnet.png -RES_MOVIES = res/movies/update_spinner.mng +RES_MOVIES = $(wildcard res/movies/spinner-*.png) BITCOIN_RC = res/bitcoin-qt-res.rc diff --git a/src/qt/bitcoin.qrc b/src/qt/bitcoin.qrc index 3c3220c2b3..746b5a4092 100644 --- a/src/qt/bitcoin.qrc +++ b/src/qt/bitcoin.qrc @@ -47,7 +47,41 @@ res/images/splash_testnet.png - res/movies/update_spinner.mng + res/movies/spinner-000.png + res/movies/spinner-001.png + res/movies/spinner-002.png + res/movies/spinner-003.png + res/movies/spinner-004.png + res/movies/spinner-005.png + res/movies/spinner-006.png + res/movies/spinner-007.png + res/movies/spinner-008.png + res/movies/spinner-009.png + res/movies/spinner-010.png + res/movies/spinner-011.png + res/movies/spinner-012.png + res/movies/spinner-013.png + res/movies/spinner-014.png + res/movies/spinner-015.png + res/movies/spinner-016.png + res/movies/spinner-017.png + res/movies/spinner-018.png + res/movies/spinner-019.png + res/movies/spinner-020.png + res/movies/spinner-021.png + res/movies/spinner-022.png + res/movies/spinner-023.png + res/movies/spinner-024.png + res/movies/spinner-025.png + res/movies/spinner-026.png + res/movies/spinner-027.png + res/movies/spinner-028.png + res/movies/spinner-029.png + res/movies/spinner-030.png + res/movies/spinner-031.png + res/movies/spinner-032.png + res/movies/spinner-033.png + res/movies/spinner-034.png locale/bitcoin_ach.qm diff --git a/src/qt/bitcoingui.cpp b/src/qt/bitcoingui.cpp index 22c41a6201..c29595050b 100644 --- a/src/qt/bitcoingui.cpp +++ b/src/qt/bitcoingui.cpp @@ -39,7 +39,6 @@ #include #include #include -#include #include #include #include @@ -68,7 +67,8 @@ BitcoinGUI::BitcoinGUI(bool fIsTestnet, QWidget *parent) : trayIcon(0), notificator(0), rpcConsole(0), - prevBlocks(0) + prevBlocks(0), + spinnerFrame(0) { GUIUtil::restoreWindowGeometry("nWindow", QSize(850, 550), this); @@ -187,8 +187,6 @@ BitcoinGUI::BitcoinGUI(bool fIsTestnet, QWidget *parent) : statusBar()->addWidget(progressBar); statusBar()->addPermanentWidget(frameBlocks); - syncIconMovie = new QMovie(":/movies/update_spinner", "mng", this); - connect(openRPCConsoleAction, SIGNAL(triggered()), rpcConsole, SLOT(show())); // prevents an oben debug window from becoming stuck/unusable on client shutdown @@ -684,9 +682,13 @@ void BitcoinGUI::setNumBlocks(int count, int nTotalBlocks) progressBar->setVisible(true); tooltip = tr("Catching up...") + QString("
") + tooltip; - labelBlocksIcon->setMovie(syncIconMovie); if(count != prevBlocks) - syncIconMovie->jumpToNextFrame(); + { + labelBlocksIcon->setPixmap(QIcon(QString( + ":/movies/spinner-%1").arg(spinnerFrame, 3, 10, QChar('0'))) + .pixmap(STATUSBAR_ICONSIZE, STATUSBAR_ICONSIZE)); + spinnerFrame = (spinnerFrame + 1) % SPINNER_FRAMES; + } prevBlocks = count; #ifdef ENABLE_WALLET diff --git a/src/qt/bitcoingui.h b/src/qt/bitcoingui.h index 1038e2739c..d5bbdca484 100644 --- a/src/qt/bitcoingui.h +++ b/src/qt/bitcoingui.h @@ -98,9 +98,9 @@ private: Notificator *notificator; RPCConsole *rpcConsole; - QMovie *syncIconMovie; /** Keep track of previous number of blocks, to detect progress */ int prevBlocks; + int spinnerFrame; /** Create the main UI actions. */ void createActions(bool fIsTestnet); diff --git a/src/qt/guiconstants.h b/src/qt/guiconstants.h index 6c9fa6a755..d1a601706b 100644 --- a/src/qt/guiconstants.h +++ b/src/qt/guiconstants.h @@ -38,4 +38,7 @@ static const int MAX_PAYMENT_REQUEST_SIZE = 50000; // bytes /* QRCodeDialog -- size of exported QR Code image */ #define EXPORT_IMAGE_SIZE 256 +/* Number of frames in spinner animation */ +#define SPINNER_FRAMES 35 + #endif // GUICONSTANTS_H diff --git a/src/qt/res/movies/spinner-000.png b/src/qt/res/movies/spinner-000.png new file mode 100644 index 0000000000..1f4fb732ef Binary files /dev/null and b/src/qt/res/movies/spinner-000.png differ diff --git a/src/qt/res/movies/spinner-001.png b/src/qt/res/movies/spinner-001.png new file mode 100644 index 0000000000..e6ca67a1b0 Binary files /dev/null and b/src/qt/res/movies/spinner-001.png differ diff --git a/src/qt/res/movies/spinner-002.png b/src/qt/res/movies/spinner-002.png new file mode 100644 index 0000000000..2360467aff Binary files /dev/null and b/src/qt/res/movies/spinner-002.png differ diff --git a/src/qt/res/movies/spinner-003.png b/src/qt/res/movies/spinner-003.png new file mode 100644 index 0000000000..52bed62566 Binary files /dev/null and b/src/qt/res/movies/spinner-003.png differ diff --git a/src/qt/res/movies/spinner-004.png b/src/qt/res/movies/spinner-004.png new file mode 100644 index 0000000000..de5c88a56f Binary files /dev/null and b/src/qt/res/movies/spinner-004.png differ diff --git a/src/qt/res/movies/spinner-005.png b/src/qt/res/movies/spinner-005.png new file mode 100644 index 0000000000..27b30336a1 Binary files /dev/null and b/src/qt/res/movies/spinner-005.png differ diff --git a/src/qt/res/movies/spinner-006.png b/src/qt/res/movies/spinner-006.png new file mode 100644 index 0000000000..1fa6b0e242 Binary files /dev/null and b/src/qt/res/movies/spinner-006.png differ diff --git a/src/qt/res/movies/spinner-007.png b/src/qt/res/movies/spinner-007.png new file mode 100644 index 0000000000..f54fa8775e Binary files /dev/null and b/src/qt/res/movies/spinner-007.png differ diff --git a/src/qt/res/movies/spinner-008.png b/src/qt/res/movies/spinner-008.png new file mode 100644 index 0000000000..d25aa5300f Binary files /dev/null and b/src/qt/res/movies/spinner-008.png differ diff --git a/src/qt/res/movies/spinner-009.png b/src/qt/res/movies/spinner-009.png new file mode 100644 index 0000000000..1349b87586 Binary files /dev/null and b/src/qt/res/movies/spinner-009.png differ diff --git a/src/qt/res/movies/spinner-010.png b/src/qt/res/movies/spinner-010.png new file mode 100644 index 0000000000..6020e275f1 Binary files /dev/null and b/src/qt/res/movies/spinner-010.png differ diff --git a/src/qt/res/movies/spinner-011.png b/src/qt/res/movies/spinner-011.png new file mode 100644 index 0000000000..0d0e811ea7 Binary files /dev/null and b/src/qt/res/movies/spinner-011.png differ diff --git a/src/qt/res/movies/spinner-012.png b/src/qt/res/movies/spinner-012.png new file mode 100644 index 0000000000..937afb6be2 Binary files /dev/null and b/src/qt/res/movies/spinner-012.png differ diff --git a/src/qt/res/movies/spinner-013.png b/src/qt/res/movies/spinner-013.png new file mode 100644 index 0000000000..4ae5a671a3 Binary files /dev/null and b/src/qt/res/movies/spinner-013.png differ diff --git a/src/qt/res/movies/spinner-014.png b/src/qt/res/movies/spinner-014.png new file mode 100644 index 0000000000..c3a81add0e Binary files /dev/null and b/src/qt/res/movies/spinner-014.png differ diff --git a/src/qt/res/movies/spinner-015.png b/src/qt/res/movies/spinner-015.png new file mode 100644 index 0000000000..184a9fe424 Binary files /dev/null and b/src/qt/res/movies/spinner-015.png differ diff --git a/src/qt/res/movies/spinner-016.png b/src/qt/res/movies/spinner-016.png new file mode 100644 index 0000000000..2da9b9dc72 Binary files /dev/null and b/src/qt/res/movies/spinner-016.png differ diff --git a/src/qt/res/movies/spinner-017.png b/src/qt/res/movies/spinner-017.png new file mode 100644 index 0000000000..ada83fbe84 Binary files /dev/null and b/src/qt/res/movies/spinner-017.png differ diff --git a/src/qt/res/movies/spinner-018.png b/src/qt/res/movies/spinner-018.png new file mode 100644 index 0000000000..cc436ba8cb Binary files /dev/null and b/src/qt/res/movies/spinner-018.png differ diff --git a/src/qt/res/movies/spinner-019.png b/src/qt/res/movies/spinner-019.png new file mode 100644 index 0000000000..03da25bc2a Binary files /dev/null and b/src/qt/res/movies/spinner-019.png differ diff --git a/src/qt/res/movies/spinner-020.png b/src/qt/res/movies/spinner-020.png new file mode 100644 index 0000000000..e7f2ac78e8 Binary files /dev/null and b/src/qt/res/movies/spinner-020.png differ diff --git a/src/qt/res/movies/spinner-021.png b/src/qt/res/movies/spinner-021.png new file mode 100644 index 0000000000..dc9e580bf3 Binary files /dev/null and b/src/qt/res/movies/spinner-021.png differ diff --git a/src/qt/res/movies/spinner-022.png b/src/qt/res/movies/spinner-022.png new file mode 100644 index 0000000000..6e236c805e Binary files /dev/null and b/src/qt/res/movies/spinner-022.png differ diff --git a/src/qt/res/movies/spinner-023.png b/src/qt/res/movies/spinner-023.png new file mode 100644 index 0000000000..f1c3228485 Binary files /dev/null and b/src/qt/res/movies/spinner-023.png differ diff --git a/src/qt/res/movies/spinner-024.png b/src/qt/res/movies/spinner-024.png new file mode 100644 index 0000000000..d8cf21f178 Binary files /dev/null and b/src/qt/res/movies/spinner-024.png differ diff --git a/src/qt/res/movies/spinner-025.png b/src/qt/res/movies/spinner-025.png new file mode 100644 index 0000000000..2b5ede3293 Binary files /dev/null and b/src/qt/res/movies/spinner-025.png differ diff --git a/src/qt/res/movies/spinner-026.png b/src/qt/res/movies/spinner-026.png new file mode 100644 index 0000000000..5ee3d2fa8e Binary files /dev/null and b/src/qt/res/movies/spinner-026.png differ diff --git a/src/qt/res/movies/spinner-027.png b/src/qt/res/movies/spinner-027.png new file mode 100644 index 0000000000..c2ee8082bd Binary files /dev/null and b/src/qt/res/movies/spinner-027.png differ diff --git a/src/qt/res/movies/spinner-028.png b/src/qt/res/movies/spinner-028.png new file mode 100644 index 0000000000..f70d3531ad Binary files /dev/null and b/src/qt/res/movies/spinner-028.png differ diff --git a/src/qt/res/movies/spinner-029.png b/src/qt/res/movies/spinner-029.png new file mode 100644 index 0000000000..02b97207a9 Binary files /dev/null and b/src/qt/res/movies/spinner-029.png differ diff --git a/src/qt/res/movies/spinner-030.png b/src/qt/res/movies/spinner-030.png new file mode 100644 index 0000000000..0c74e82c6f Binary files /dev/null and b/src/qt/res/movies/spinner-030.png differ diff --git a/src/qt/res/movies/spinner-031.png b/src/qt/res/movies/spinner-031.png new file mode 100644 index 0000000000..c5e29bcec7 Binary files /dev/null and b/src/qt/res/movies/spinner-031.png differ diff --git a/src/qt/res/movies/spinner-032.png b/src/qt/res/movies/spinner-032.png new file mode 100644 index 0000000000..d72c9bf0dd Binary files /dev/null and b/src/qt/res/movies/spinner-032.png differ diff --git a/src/qt/res/movies/spinner-033.png b/src/qt/res/movies/spinner-033.png new file mode 100644 index 0000000000..a8b822bfaf Binary files /dev/null and b/src/qt/res/movies/spinner-033.png differ diff --git a/src/qt/res/movies/spinner-034.png b/src/qt/res/movies/spinner-034.png new file mode 100644 index 0000000000..684aa385e0 Binary files /dev/null and b/src/qt/res/movies/spinner-034.png differ diff --git a/src/qt/res/movies/update_spinner.mng b/src/qt/res/movies/update_spinner.mng deleted file mode 100644 index 7df3baac6f..0000000000 Binary files a/src/qt/res/movies/update_spinner.mng and /dev/null differ