diff --git a/README.md b/README.md index a87a02c..76d6506 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,6 @@ # SilentDragon

- - MyHushTeam's Twitter - - follow on Twitter follow on Mastodon @@ -16,7 +10,9 @@

SilentDragon desktop wallet for HUSH runs on Linux, Windows and macOS. -This is experimental software under active development! +This is experimental software under active development! Get real-time +support on [our Telegram support group](https://hush.is/tg_support) and +feel free to join the [main Telegram group](https://hush.is/tg) as well. ![Screenshots](images/sd-receive-tab.png?raw=true) @@ -33,13 +29,16 @@ The following are screenshots for each SilentDragon tab: SilentDragon contacts a few different external websites to get various bits of data. - * coingecko.com for price data API - * explorer.hush.is for explorer links + * coingecko.com for price data API (defaults to on, optional) + * explorer.hush.is for explorer links (optional) * dexstats.info for address utilities - * wormhole.hush.is for Wormhole services + * Address Asset Viewer menu action (optional) + * Convert Address menu action (optional) + * wormhole.hush.is for Wormhole services (optional) This means your IP address is known to these servers. Enable Tor setting in SilentDragon to prevent this, or better yet, use TAILS: https://tails.boum.org/ +NOTE: Tor v3 is not yet supported. # Installation @@ -56,6 +55,9 @@ Additionally, if this is the first time you're running SilentDragon or a hushd d Pass `--no-embedded` to disable the embedded hushd and force SilentDragon to connect to an external node. +If SD crashes when autostarting hushd, you may have run out of memory. This could happen with very large wallets. Try closing unnecessary applications and/or browser tabs and retry. +Another method is to start hushd first, then start SD, which will connect to the existing hushd. + ## Compiling from source SilentDragon is written in C++ 14, and can be compiled with g++/clang++/visual @@ -66,6 +68,19 @@ hushd, or compile hushd as well. ### Building on Linux +#### Linux Troubleshooting +If you run into an error with OpenGL, you may need to install extra deps. More details [here](https://gist.github.com/shamiul94/a632f7ab94cf389e08efd7174335df1c) + +**Error** +``` +/usr/bin/ld: cannot find -lGL +clang: error: linker command failed with exit code 1 (use -v to see invocation) +``` +**Solution** +``` +sudo apt-get -y install libglu1-mesa-dev freeglut3-dev mesa-common-dev +``` + #### Ubuntu 18.04 and 20.04 You can install the pre-reqs and build on Ubuntu 18.04 & 20.04 with: diff --git a/doc/relnotes/README.md b/doc/relnotes/README.md new file mode 100644 index 0000000..bb76980 --- /dev/null +++ b/doc/relnotes/README.md @@ -0,0 +1,33 @@ +# Official SilentDragon Release Notes + +SilentDragon release notes were done on Github until 1.0.0 +and now are officially part of our Gitea repo at https://git.hush.is/hush/silentdragon + +## Downloading Releases + +Hush releases are on our own Gitea at git.hush.is +and no longer on Github, since they banned Duke Leto and +also because they censor many people around the world and work with +evil organizations. + +# SilentDragon 1.3.0 "Berserk Bonnacon" + +``` + 60 files changed, 4328 insertions(+), 1568 deletions(-) +``` + + * :tada: New Polish translation ( @onryo ) + * This release of SD is only compatible with hushd 3.9.0 or later, which is a mandatory update + * Older Hush full nodes will not be compatible with the Hush network going forward + * New shinier startup animation by Dan S ( https://twitter.com/Dan\_MGDesign ) + * When right-clicking on a zaddr, there are now two new menu options + * Shield all mining funds to this zaddr (z_shieldcoinbase) + * Use this if you are a solo miner who mined full blocks to a taddr + * Only 50 blocks will be shielded at a time. If you have more, run this multiple times. + * Shield all non-mining taddr funds to this zaddr (z_mergetoaddress) + * Use this if you have an old wallet with funds in taddrs + * Only 50 utxos (transactions) will be shielded at a time. If you have more, run this multiple times. + * SD now looks for Hush full node data in `~/.hush/HUSH3` but still supports the legacy location + * The About screen now reports the version of QT5 being used + * In the case of an exception, the default currency will be set to BTC instead of USD + * SD includes its version number in autogenerated HUSH3.conf config files diff --git a/res/silentdragon_be.ts b/res/silentdragon_be.ts index 503a21d..fc8150e 100644 --- a/res/silentdragon_be.ts +++ b/res/silentdragon_be.ts @@ -1463,7 +1463,7 @@ Please set the host/port and user/password in the Edit->Settings menu.Гэта можа заняць некалькі гадзін, вазьміце трохі папкорна - + There was an error! : Памылка! : @@ -1517,12 +1517,12 @@ Please set the host/port and user/password in the Edit->Settings menu. вылічэнне транзакцый. - + Please enhance your calm and wait for SilentDragon to exit Калі ласка, пачакайце выхаду з SilentDragon - + Waiting for hushd to exit, y'all Чакаем выхаду hushd @@ -1627,7 +1627,7 @@ Please set the host/port and user/password in the Edit->Settings menu.Памылка Злучэння - + Transaction Error Памылка Транзакцыі diff --git a/res/silentdragon_bg.ts b/res/silentdragon_bg.ts index b83f7cc..a91d58d 100644 --- a/res/silentdragon_bg.ts +++ b/res/silentdragon_bg.ts @@ -1320,13 +1320,13 @@ Please set the host/port and user/password in the Edit->Settings menu. - + Transaction Error - + There was an error! : @@ -1404,12 +1404,12 @@ Would you like to visit the releases page? - + Please enhance your calm and wait for SilentDragon to exit - + Waiting for hushd to exit, y'all diff --git a/res/silentdragon_de.ts b/res/silentdragon_de.ts index 4d81dc7..f2b917e 100644 --- a/res/silentdragon_de.ts +++ b/res/silentdragon_de.ts @@ -1385,7 +1385,7 @@ If all else fails, please run hushd manually. Dies kann einige Stunden dauern, machen Sie sich einen Kaffee - + There was an error! : Es gab einen Fehler! : @@ -1425,12 +1425,12 @@ If all else fails, please run hushd manually. erzeuge Transaktion - + Please enhance your calm and wait for SilentDragon to exit Bitte warten Sie, bis Silentdragon beendet ist - + Waiting for hushd to exit, y'all Bitte warten Sie, bis Hushd beendet ist @@ -1551,7 +1551,7 @@ Please set the host/port and user/password in the Edit->Settings menu.Verbindungsfehler - + Transaction Error Transaktionsfehler diff --git a/res/silentdragon_es.ts b/res/silentdragon_es.ts index d8b51c3..862286c 100644 --- a/res/silentdragon_es.ts +++ b/res/silentdragon_es.ts @@ -1262,12 +1262,12 @@ doesn't look like a z-address transacción es computación - + Please enhance your calm and wait for SilentDragon to exit - + Waiting for hushd to exit, y'all @@ -1459,12 +1459,12 @@ Por favor, especificar el host/puerta y usario/contraseña en el menú Editar-&g - + There was an error! : ¡Hubo un error! : - + Transaction Error Error De Transacción diff --git a/res/silentdragon_fi.ts b/res/silentdragon_fi.ts index 4ca9efd..f311980 100644 --- a/res/silentdragon_fi.ts +++ b/res/silentdragon_fi.ts @@ -1341,7 +1341,7 @@ Integroitua hushdia ei käynnistetä, koska --ei-integroitu ohitettiinMT at - + There was an error! : Tapahtui virhe! : @@ -1415,12 +1415,12 @@ Haluaisitko vierailla lataus-sivulla? Sinulla on jo uusin versio v%1 - + Please enhance your calm and wait for SilentDragon to exit - + Waiting for hushd to exit, y'all @@ -1514,7 +1514,7 @@ Aseta isäntä/portti ja käyttäjänimi/salasana Muokkaa-> Asetukset-valikos Yhteysvirhe - + Transaction Error Tapahtumavirhe diff --git a/res/silentdragon_fil.ts b/res/silentdragon_fil.ts index 87ef7c0..6a7c313 100644 --- a/res/silentdragon_fil.ts +++ b/res/silentdragon_fil.ts @@ -1380,13 +1380,13 @@ Mangyaring i-set ang host/port at user/password sa Edit->Settings na menu.May Mali sa Koneksyon - + Transaction Error May Mali sa Transaksyon - + There was an error! : Mayroong Mali! : @@ -1468,12 +1468,12 @@ Would you like to visit the releases page? Nasa iyo na ang pinakabagong release v%1 - + Please enhance your calm and wait for SilentDragon to exit Mangyaring maging mas kalmado at hintayin ang SilentDragon na mag-exit - + Waiting for hushd to exit, y'all Hinihintay ang hush na mag-exit, y'all diff --git a/res/silentdragon_fr.ts b/res/silentdragon_fr.ts index 752161e..a1eb984 100644 --- a/res/silentdragon_fr.ts +++ b/res/silentdragon_fr.ts @@ -1366,7 +1366,7 @@ If all else fails, please run hushd manually. Cela peut prendre plusieurs heures. Prenez du pop-corn - + There was an error! : Il y avait une erreur! : @@ -1406,12 +1406,12 @@ If all else fails, please run hushd manually. transaction en cours. - + Please enhance your calm and wait for SilentDragon to exit Veuillez restez calme et attendre la fermeture de SilentDragon - + Waiting for hushd to exit, y'all Veuillez attendre que hushd soit arrêté. @@ -1532,7 +1532,7 @@ Veuillez configurer l'hôte/port et utilisateur/mot de passe dans le menu E Erreur de connection - + Transaction Error Erreur de transaction diff --git a/res/silentdragon_hr.ts b/res/silentdragon_hr.ts index 9cb1fe8..54a242b 100644 --- a/res/silentdragon_hr.ts +++ b/res/silentdragon_hr.ts @@ -1381,13 +1381,13 @@ Molimo postavite host/port i korisnčko ime/lozinku u Uredi->Postavke meniju. Greška sa vezom - + Transaction Error Greška u transakciji - + There was an error! : Dogodila se greška! : @@ -1471,12 +1471,12 @@ Would you like to visit the releases page? Već imate najnovije izdanje v%1 - + Please enhance your calm and wait for SilentDragon to exit Molimo pokušajte se strpiti i pričekajte da se SilentDragon zatvori - + Waiting for hushd to exit, y'all Pričekajte da hushd završi diff --git a/res/silentdragon_it.ts b/res/silentdragon_it.ts index 02e3f7c..e91ad65 100644 --- a/res/silentdragon_it.ts +++ b/res/silentdragon_it.ts @@ -1345,7 +1345,7 @@ If all else fails, please run hushd manually. Potrebbero essere necessarie alcune ore, prendi dei popcorn - + There was an error! : C'era un errore! : @@ -1390,12 +1390,12 @@ If all else fails, please run hushd manually. - + Please enhance your calm and wait for SilentDragon to exit - + Waiting for hushd to exit, y'all @@ -1510,7 +1510,7 @@ Impostare host/porta e utente/password nel menu Modifica-> Impostazioni.Errore di Connessione - + Transaction Error Errore di transazione diff --git a/res/silentdragon_nl.ts b/res/silentdragon_nl.ts index fce9fcd..4a90eaf 100644 --- a/res/silentdragon_nl.ts +++ b/res/silentdragon_nl.ts @@ -1345,7 +1345,7 @@ Als al het andere faalt, voer hushd dan handmatig uit. Dit kan enkele uren duren, pak wat popcorn - + There was an error! : Er was een error! : @@ -1390,12 +1390,12 @@ Als al het andere faalt, voer hushd dan handmatig uit. - + Please enhance your calm and wait for SilentDragon to exit - + Waiting for hushd to exit, y'all @@ -1509,7 +1509,7 @@ Stel de host / poort en gebruiker / wachtwoord in het menu Bewerken-> Instell Connectie Fout - + Transaction Error Transactie Fout diff --git a/res/silentdragon_pl.ts b/res/silentdragon_pl.ts index 8d67e72..f55a344 100644 --- a/res/silentdragon_pl.ts +++ b/res/silentdragon_pl.ts @@ -1258,7 +1258,7 @@ Ustaw host/port i użytkownik/hasło w Edytuj->Ustawienia menu. Może to zająć do kilku godzin, tymczasem chwyćcie za popcorn - + There was an error! : Wystąpił błąd! : @@ -1308,12 +1308,12 @@ Ustaw host/port i użytkownik/hasło w Edytuj->Ustawienia menu. przetwarzanie transakcji. - + Please enhance your calm and wait for SilentDragon to exit Proszę poczekać SilentDragon do wyjścia - + Waiting for hushd to exit, y'all Czekam na wyjście hushd @@ -1382,7 +1382,7 @@ Ustaw host/port i użytkownik/hasło w Edytuj->Ustawienia menu. Błąd Połączenia - + Transaction Error Błąd Transakcji diff --git a/res/silentdragon_pt.ts b/res/silentdragon_pt.ts index b40c338..5fbff0a 100644 --- a/res/silentdragon_pt.ts +++ b/res/silentdragon_pt.ts @@ -1332,7 +1332,7 @@ Se tudo mais falhar, execute o hushd manualmente. Isso pode levar várias horas, pegue um pouco de pipoca - + There was an error! : Havia um erro! : @@ -1377,12 +1377,12 @@ Se tudo mais falhar, execute o hushd manualmente. - + Please enhance your calm and wait for SilentDragon to exit - + Waiting for hushd to exit, y'all @@ -1496,7 +1496,7 @@ Por favor, coloque o host/porta e usuário/senha no menu Editar>Preferências Erro na Conexão - + Transaction Error Erro na transação diff --git a/res/silentdragon_ro.ts b/res/silentdragon_ro.ts index 7d81a4d..7c760e7 100644 --- a/res/silentdragon_ro.ts +++ b/res/silentdragon_ro.ts @@ -1376,13 +1376,13 @@ Rugam sa setati host/port si utilizator/parola in Editare-> Meniu setariEroare la Conexiune - + Transaction Error Eroarea de Tranzactie - + There was an error! : A avut loc eroarea @@ -1465,12 +1465,12 @@ Doriti sa vizitati pagina veriunii? Deja aveti cea mai recenta versiune - + Please enhance your calm and wait for SilentDragon to exit Rugam sa sporiti calmul si sa astepati pina ce SilentDragon sa iese - + Waiting for hushd to exit, y'all Asteptam hushd sa iese. diff --git a/res/silentdragon_ru.ts b/res/silentdragon_ru.ts index 25ff6eb..5b7099b 100644 --- a/res/silentdragon_ru.ts +++ b/res/silentdragon_ru.ts @@ -1463,7 +1463,7 @@ Please set the host/port and user/password in the Edit->Settings menu.Это может занять несколько часов, возьмите немного попкорна - + There was an error! : Была ошибка! : @@ -1517,12 +1517,12 @@ Please set the host/port and user/password in the Edit->Settings menu. вычисление транзакции. - + Please enhance your calm and wait for SilentDragon to exit Пожалуйста, дождитесь выхода SilentDragon - + Waiting for hushd to exit, y'all Ожидаем выхода hushd @@ -1627,7 +1627,7 @@ Please set the host/port and user/password in the Edit->Settings menu.Ошибка соединения - + Transaction Error ">Ошибка транзакции diff --git a/res/silentdragon_sr.ts b/res/silentdragon_sr.ts index 073ff45..d95d660 100644 --- a/res/silentdragon_sr.ts +++ b/res/silentdragon_sr.ts @@ -1381,13 +1381,13 @@ Molimo postavite host/port i korisnčko ime/lozinku u Uredi->Podešavanja men Greška sa vezom - + Transaction Error Greška u transakciji - + There was an error! : Dogodila se greška! : @@ -1471,12 +1471,12 @@ Would you like to visit the releases page? Već imate najnovije izdanje v%1 - + Please enhance your calm and wait for SilentDragon to exit Molimo pokušajte se strpiti i pričekajte da se SilentDragon zatvori - + Waiting for hushd to exit, y'all Pričekajte da hushd završi diff --git a/res/silentdragon_tr.ts b/res/silentdragon_tr.ts index 8f671b3..03d9522 100644 --- a/res/silentdragon_tr.ts +++ b/res/silentdragon_tr.ts @@ -1328,7 +1328,7 @@ Hepsi başarısız olursa, lütfen hushd'i manuel olarak çalıştırın.MB saniyede - + There was an error! : Bir hata oluştu! : @@ -1373,12 +1373,12 @@ Hepsi başarısız olursa, lütfen hushd'i manuel olarak çalıştırın. - + Please enhance your calm and wait for SilentDragon to exit - + Waiting for hushd to exit, y'all @@ -1501,7 +1501,7 @@ Lütfen Düzenle->Ayarlar menüsünde sunucu/bağlantı noktası ve kullanıc Bağlantı Hatası - + Transaction Error İşlem Hatası diff --git a/res/silentdragon_uk.ts b/res/silentdragon_uk.ts index 10a9f62..67e6cd2 100644 --- a/res/silentdragon_uk.ts +++ b/res/silentdragon_uk.ts @@ -1451,7 +1451,7 @@ Please set the host/port and user/password in the Edit->Settings menu. - + There was an error! : @@ -1505,12 +1505,12 @@ Please set the host/port and user/password in the Edit->Settings menu. - + Please enhance your calm and wait for SilentDragon to exit - + Waiting for hushd to exit, y'all @@ -1615,7 +1615,7 @@ Please set the host/port and user/password in the Edit->Settings menu.Помилка з'єднання - + Transaction Error Помилка транзакції diff --git a/res/silentdragon_zh.ts b/res/silentdragon_zh.ts index 2a27f7b..492f7d0 100644 --- a/res/silentdragon_zh.ts +++ b/res/silentdragon_zh.ts @@ -1522,7 +1522,7 @@ Please set the host/port and user/password in the Edit->Settings menu. - + There was an error! : @@ -1537,7 +1537,7 @@ Please set the host/port and user/password in the Edit->Settings menu.连接错误 - + Transaction Error 交易错误 @@ -1645,12 +1645,12 @@ Please set the host/port and user/password in the Edit->Settings menu. - + Please enhance your calm and wait for SilentDragon to exit - + Waiting for hushd to exit, y'all diff --git a/src/connection.cpp b/src/connection.cpp index c149377..854479f 100644 --- a/src/connection.cpp +++ b/src/connection.cpp @@ -7,6 +7,7 @@ #include "ui_createzcashconfdialog.h" #include "rpc.h" #include "precompiled.h" +#include "version.h" ConnectionLoader::ConnectionLoader(MainWindow* main, RPC* rpc) { this->main = main; @@ -41,7 +42,7 @@ void ConnectionLoader::loadConnection() { d->exec(); } -void ConnectionLoader::doAutoConnect(bool tryEzcashdStart) { +void ConnectionLoader::doAutoConnect(bool tryEhushdStart) { // Priority 1: Ensure all params are present. if (!verifyParams()) { qDebug() << "Cannot find sapling params!"; @@ -58,7 +59,7 @@ void ConnectionLoader::doAutoConnect(bool tryEzcashdStart) { refreshHushdState(connection, [=] () { // Refused connection. So try and start embedded hushd if (Settings::getInstance()->useEmbedded()) { - if (tryEzcashdStart) { + if (tryEhushdStart) { this->showInformation(QObject::tr("Starting embedded hushd")); if (this->startEmbeddedHushd()) { // Embedded hushd started up. Wait a second and then refresh the connection @@ -194,7 +195,7 @@ void ConnectionLoader::createHushConf() { QTextStream out(&file); - out << "# Autogenerated by Hush SilentDragon https://hush.is\n"; + out << "# Autogenerated by Hush SilentDragon " << APP_VERSION << " https://hush.is\n"; out << "server=1\n"; out << "rpcuser=hush\n"; out << "rpcpassword=" % randomPassword() << "\n"; @@ -249,7 +250,7 @@ void ConnectionLoader::doNextDownload(std::function cb) { int filesRemaining = downloadQueue->size(); QString filename = fnSaveFileName(url); - QString paramsDir = zcashParamsDir(); + QString paramsDir = zkParamsDir(); if (QFile(QDir(paramsDir).filePath(filename)).exists()) { main->logger->write(filename + " already exists, skipping"); @@ -352,6 +353,7 @@ bool ConnectionLoader::startEmbeddedHushd() { main->logger->write("Can't find hushd at " + hushdProgram); return false; } else { + qDebug() << "Found hushd at " << hushdProgram; main->logger->write("Found hushd at " + hushdProgram); } @@ -366,7 +368,8 @@ bool ConnectionLoader::startEmbeddedHushd() { }); QObject::connect(ehushd.get(), &QProcess::errorOccurred, [&] (QProcess::ProcessError error) { - qDebug() << "Couldn't start hushd at " << hushdProgram << ":" << error; + qDebug() << "Couldn't start hushd!"; + qDebug() << "hushd at " << hushdProgram << ":" << error; }); std::weak_ptr weak_obj(ehushd); @@ -379,7 +382,7 @@ bool ConnectionLoader::startEmbeddedHushd() { // This string should be the exact arg list seperated by single spaces // Could be modified to start different Hush Smart Chains - QString params = ""; // "-ac_name=TUSH"; + QString params = "-tls=only -clientname=GoldenSandtrout"; // "-ac_name=TUSH"; /* This is now enabled by default in hushd // Binaries come with this file @@ -587,7 +590,7 @@ QString ConnectionLoader::hushConfWritableLocation() { return QDir::cleanPath(confLocation); } -QString ConnectionLoader::zcashParamsDir() { +QString ConnectionLoader::zkParamsDir() { #ifdef Q_OS_LINUX //TODO: If /usr/share/hush exists, use that. It should not be assumed writeable auto paramsLocation = QDir(QDir(QStandardPaths::writableLocation(QStandardPaths::HomeLocation)).filePath(".zcash-params")); @@ -611,7 +614,7 @@ QString ConnectionLoader::zcashParamsDir() { } bool ConnectionLoader::verifyParams() { - QDir paramsDir(zcashParamsDir()); + QDir paramsDir(zkParamsDir()); // TODO: better error reporting if only 1 file exists or is missing qDebug() << "Verifying sapling param files exist"; @@ -728,9 +731,7 @@ std::shared_ptr ConnectionLoader::autoDetectHushConf() { return std::shared_ptr(hushconf); } -/** - * Load connection settings from the UI, which indicates an unknown, external zcashd - */ +// Load connection settings from the UI, which indicates an unknown, external hushd std::shared_ptr ConnectionLoader::loadFromSettings() { // Load from the QT Settings. QSettings s; diff --git a/src/connection.h b/src/connection.h index 55eb434..1f381cf 100644 --- a/src/connection.h +++ b/src/connection.h @@ -47,13 +47,13 @@ private: Connection* makeConnection(std::shared_ptr config); - void doAutoConnect(bool tryEzcashdStart = true); + void doAutoConnect(bool tryEhushdStart = true); void doManualConnect(); void createHushConf(); QString locateHushConfFile(); QString hushConfWritableLocation(); - QString zcashParamsDir(); + QString zkParamsDir(); bool verifyParams(); void downloadParams(std::function cb); @@ -84,7 +84,7 @@ private: }; /** - * Represents a connection to a zcashd. It may even start a new zcashd if needed. + * Represents a connection to a hushd. It may even start a new hushd if needed. * This is also a UI class, so it may show a dialog waiting for the connection. */ class Connection { diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp index dccee2c..2348241 100644 --- a/src/mainwindow.cpp +++ b/src/mainwindow.cpp @@ -61,7 +61,7 @@ MainWindow::MainWindow(QWidget *parent) : }); // Request hush - QObject::connect(ui->actionRequest_zcash, &QAction::triggered, [=]() { + QObject::connect(ui->actionRequest_hush, &QAction::triggered, [=]() { RequestDialog::showRequestZcash(this); }); @@ -279,7 +279,7 @@ void MainWindow::setupSettingsModal() { currency_name = Settings::getInstance()->get_currency_name(); } catch (const std::exception& e) { qDebug() << QString("Currency name exception! : "); - currency_name = "USD"; + currency_name = "BTC"; } this->slot_change_currency(currency_name); @@ -1655,7 +1655,7 @@ void MainWindow::setupReceiveTab() { } ui->rcvLabel->setText(label); - ui->rcvBal->setText(Settings::getZECUSDDisplayFormat(rpc->getAllBalances()->value(addr))); + ui->rcvBal->setText(Settings::getHUSHUSDDisplayFormat(rpc->getAllBalances()->value(addr))); ui->txtReceive->setPlainText(addr); ui->qrcodeDisplay->setQrcodeString(addr); if (rpc->getUsedAddresses()->value(addr, false)) { @@ -1758,7 +1758,7 @@ void MainWindow::slot_change_currency(const QString& currency_name) saved_currency_name = Settings::getInstance()->get_currency_name(); } catch (const std::exception& e) { qDebug() << QString("Ignoring currency change Exception! : "); - saved_currency_name = "USD"; + saved_currency_name = "BTC"; } } diff --git a/src/mainwindow.ui b/src/mainwindow.ui index 9c901f7..e03874a 100644 --- a/src/mainwindow.ui +++ b/src/mainwindow.ui @@ -1594,7 +1594,7 @@ &File - + @@ -1729,7 +1729,7 @@ Ctrl+M - + Request HUSH... diff --git a/src/requestdialog.cpp b/src/requestdialog.cpp index 62d5eca..581fbd8 100644 --- a/src/requestdialog.cpp +++ b/src/requestdialog.cpp @@ -125,7 +125,7 @@ void RequestDialog::showRequestZcash(MainWindow* main) { req.txtFrom->setFocus(); if (d.exec() == QDialog::Accepted) { - // Construct a zcash Payment URI with the data and pay it immediately. + // Construct a Hush Payment URI with the data and pay it immediately. QString memoURI = "hush:" + req.cmbMyAddress->currentText() + "?amt=" + Settings::getDecimalString(req.txtAmount->text().toDouble()) + "&memo=" + QUrl::toPercentEncoding(req.txtMemo->toPlainText()); diff --git a/src/rpc.cpp b/src/rpc.cpp index 61a938e..3619bdb 100644 --- a/src/rpc.cpp +++ b/src/rpc.cpp @@ -1229,14 +1229,20 @@ void RPC::refreshPrice() { if (conn == nullptr) return noConnection(); + QString price_feed = "https://api.coingecko.com/api/v3/simple/price?ids=hush&vs_currencies=btc%2Cusd%2Ceur%2Ceth%2Cgbp%2Ccny%2Cjpy%2Cidr%2Crub%2Ccad%2Csgd%2Cchf%2Cinr%2Caud%2Cinr%2Ckrw%2Cthb%2Cnzd%2Czar%2Cvef%2Cxau%2Cxag%2Cvnd%2Csar%2Ctwd%2Caed%2Cars%2Cbdt%2Cbhd%2Cbmd%2Cbrl%2Cclp%2Cczk%2Cdkk%2Chuf%2Cils%2Ckwd%2Clkr%2Cpkr%2Cnok%2Ctry%2Csek%2Cmxn%2Cuah%2Chkd&include_market_cap=true&include_24hr_vol=true&include_24hr_change=true"; + qDebug() << "Requesting price feed data via " << price_feed; + QUrl cmcURL(price_feed); QNetworkRequest req; req.setUrl(cmcURL); + + qDebug() << "Created price request object"; + QNetworkReply *reply = conn->restclient->get(req); - auto s = Settings::getInstance(); + qDebug() << "Created QNetworkReply"; - qDebug() << "Requesting price feed data via " << price_feed; + auto s = Settings::getInstance(); QObject::connect(reply, &QNetworkReply::finished, [=] { reply->deleteLater(); diff --git a/src/scripts/dounifiedbuild.ps1 b/src/scripts/dounifiedbuild.ps1 index a1704ef..e86f976 100644 --- a/src/scripts/dounifiedbuild.ps1 +++ b/src/scripts/dounifiedbuild.ps1 @@ -28,7 +28,7 @@ Write-Host "" Write-Host "[Building on Mac]" -bash src/scripts/mkmacdmg.sh --qt_path ~/Qt/5.11.1/clang_64/ --version $version --zcash_path ~/gi/hush3 --certificate "$certificate" +bash src/scripts/mkmacdmg.sh --qt_path ~/Qt/5.11.1/clang_64/ --version $version --hush_path ~/gi/hush3 --certificate "$certificate" if (! $?) { Write-Output "[Error]" exit 1; diff --git a/src/scripts/mkwininstaller.ps1 b/src/scripts/mkwininstaller.ps1 index 603d05c..d19e8e8 100644 --- a/src/scripts/mkwininstaller.ps1 +++ b/src/scripts/mkwininstaller.ps1 @@ -2,28 +2,28 @@ param ( [Parameter(Mandatory=$true)][string]$version ) -$target="zecwallet-v$version" +$target="silentdragon-v$version" Remove-Item -Path release/wininstaller -Recurse -ErrorAction Ignore | Out-Null New-Item release/wininstaller -itemtype directory | Out-Null -Copy-Item release/$target/zecwallet.exe release/wininstaller/ +Copy-Item release/$target/silentdragon.exe release/wininstaller/ Copy-Item release/$target/LICENSE release/wininstaller/ Copy-Item release/$target/README.md release/wininstaller/ -Copy-Item release/$target/zcashd.exe release/wininstaller/ -Copy-Item release/$target/zcash-cli.exe release/wininstaller/ +Copy-Item release/$target/hushd.exe release/wininstaller/ +Copy-Item release/$target/hush-cli.exe release/wininstaller/ -Get-Content src/scripts/zec-qt-wallet.wxs | ForEach-Object { $_ -replace "RELEASE_VERSION", "$version" } | Out-File -Encoding utf8 release/wininstaller/zec-qt-wallet.wxs +Get-Content src/scripts/silentdragon.wxs | ForEach-Object { $_ -replace "RELEASE_VERSION", "$version" } | Out-File -Encoding utf8 release/wininstaller/silentdragon.wxs -candle.exe release/wininstaller/zec-qt-wallet.wxs -o release/wininstaller/zec-qt-wallet.wixobj +candle.exe release/wininstaller/silentdragon.wxs -o release/wininstaller/silentdragon.wixobj if (!$?) { exit 1; } -light.exe -ext WixUIExtension -cultures:en-us release/wininstaller/zec-qt-wallet.wixobj -out release/wininstaller/zecwallet.msi +light.exe -ext WixUIExtension -cultures:en-us release/wininstaller/silentdragon.wixobj -out release/wininstaller/silentdragon.msi if (!$?) { exit 1; } New-Item artifacts -itemtype directory -Force | Out-Null -Copy-Item release/wininstaller/zecwallet.msi ./artifacts/Windows-installer-$target.msi \ No newline at end of file +Copy-Item release/wininstaller/silentdragon.msi ./artifacts/Windows-installer-$target.msi diff --git a/src/sendtab.cpp b/src/sendtab.cpp index 3b1e593..6c5e11f 100644 --- a/src/sendtab.cpp +++ b/src/sendtab.cpp @@ -663,9 +663,9 @@ bool MainWindow::confirmTx(Tx tx) { // And FromAddress in the confirm dialog confirm.sendFrom->setText(fnSplitAddressForWrap(tx.fromAddr)); QString tooltip = tr("Current balance : ") + - Settings::getZECUSDDisplayFormat(rpc->getAllBalances()->value(tx.fromAddr)); + Settings::getHUSHUSDDisplayFormat(rpc->getAllBalances()->value(tx.fromAddr)); tooltip += "\n" + tr("Balance after this Tx: ") + - Settings::getZECUSDDisplayFormat(rpc->getAllBalances()->value(tx.fromAddr) - totalSpending); + Settings::getHUSHUSDDisplayFormat(rpc->getAllBalances()->value(tx.fromAddr) - totalSpending); confirm.sendFrom->setToolTip(tooltip); // Show the dialog and submit it if the user confirms diff --git a/src/senttxstore.cpp b/src/senttxstore.cpp index 0ccb88e..91bf78a 100644 --- a/src/senttxstore.cpp +++ b/src/senttxstore.cpp @@ -57,7 +57,7 @@ void SentTxStore::addToSentTx(Tx tx, QString txid) { if (!Settings::getInstance()->getSaveZtxs()) return; - // Also, only store outgoing txs where the from address is a z-Addr. Else, regular zcashd + // Also, only store outgoing txs where the from address is a z-Addr. Else, regular hushd // stores it just fine if (!tx.fromAddr.startsWith("z")) return; diff --git a/src/settings.cpp b/src/settings.cpp index 79a4185..07eb0b1 100644 --- a/src/settings.cpp +++ b/src/settings.cpp @@ -302,7 +302,7 @@ QString Settings::getDisplayFormat(double bal) { return getDecimalString(bal) % " " % Settings::getTokenName(); } -QString Settings::getZECUSDDisplayFormat(double bal) { +QString Settings::getHUSHUSDDisplayFormat(double bal) { auto usdFormat = getUSDFormat(bal); if (!usdFormat.isEmpty()) return getDisplayFormat(bal) % " (" % getUSDFormat(bal) % ")"; diff --git a/src/settings.h b/src/settings.h index 0bd94b4..d71d26f 100644 --- a/src/settings.h +++ b/src/settings.h @@ -123,7 +123,7 @@ public: static QString getDecimalString(double amt); static QString getUSDFormat(double bal); static QString getDisplayFormat(double bal); - static QString getZECUSDDisplayFormat(double bal); + static QString getHUSHUSDDisplayFormat(double bal); static QString getTokenName(); static QString getDonationAddr();