Browse Source

Fix animations on send and shutdown

pull/81/head
Duke Leto 2 years ago
parent
commit
d407d7aff3
  1. 15
      src/rpc.cpp
  2. 15
      src/sendtab.cpp

15
src/rpc.cpp

@ -1359,18 +1359,11 @@ void RPC::shutdownHushd() {
connD.setupUi(&d);
//connD.topIcon->setBasePixmap(QIcon(":/icons/res/icon.ico").pixmap(256, 256));
QMovie *movie1 = new QMovie(":/img/res/silentdragon-animated.gif");;
QMovie *movie2 = new QMovie(":/img/res/silentdragon-animated-dark.gif");;
QMovie *movie1 = new QMovie(":/img/res/silentdragon-animated-dark.gif");;
auto theme = Settings::getInstance()->get_theme_name();
if (theme == "dark" || theme == "midnight") {
movie2->setScaledSize(QSize(512,512));
connD.topIcon->setMovie(movie2);
movie2->start();
} else {
movie1->setScaledSize(QSize(512,512));
connD.topIcon->setMovie(movie1);
movie1->start();
}
movie1->setScaledSize(QSize(512,512));
connD.topIcon->setMovie(movie1);
movie1->start();
connD.status->setText(QObject::tr("Please enhance your calm and wait for SilentDragon to exit"));
connD.statusDetail->setText(QObject::tr("Waiting for hushd to exit, y'all"));

15
src/sendtab.cpp

@ -702,18 +702,11 @@ void MainWindow::sendButton() {
auto connD = new Ui_ConnectionDialog();
connD->setupUi(d);
QMovie *movie1 = new QMovie(":/img/res/silentdragon-animated.gif");;
QMovie *movie2 = new QMovie(":/img/res/silentdragon-animated-dark.gif");;
QMovie *movie1 = new QMovie(":/img/res/silentdragon-animated-dark.gif");;
auto theme = Settings::getInstance()->get_theme_name();
if (theme == "dark" || theme == "midnight") {
movie2->setScaledSize(QSize(512,512));
connD->topIcon->setMovie(movie2);
movie2->start();
} else {
movie1->setScaledSize(QSize(512,512));
connD->topIcon->setMovie(movie1);
movie1->start();
}
movie1->setScaledSize(QSize(512,512));
connD->topIcon->setMovie(movie1);
movie1->start();
//connD->topIcon->setBasePixmap(logo.scaled(256, 256, Qt::KeepAspectRatio, Qt::SmoothTransformation));

Loading…
Cancel
Save