Rename to Zec Wallet (#117)

* Update linux name

* Rename strings

* Rename debian/linux packages

* Rename windows build/installer

* Mac rename

* Update icon

* Update windows icon

* update background

* Prevent deleting utxos and balances while updating
This commit is contained in:
adityapk00
2019-03-14 11:56:05 -07:00
committed by GitHub
parent d8b44f3978
commit b1614caea0
36 changed files with 2464 additions and 929 deletions

View File

@@ -17,7 +17,7 @@
<item>
<widget class="QGroupBox" name="groupBox">
<property name="title">
<string notr="true">zec-qt-wallet</string>
<string notr="true">ZecWallet</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>

View File

@@ -75,8 +75,8 @@ void ConnectionLoader::doAutoConnect(bool tryEzcashdStart) {
QString explanation;
if (config->zcashDaemon) {
explanation = QString() % QObject::tr("You have zcashd set to start as a daemon, which can cause problems "
"with zec-qt-wallet\n\n."
"Please remove the following line from your zcash.conf and restart zec-qt-wallet\n"
"with ZecWallet\n\n."
"Please remove the following line from your zcash.conf and restart ZecWallet\n"
"daemon=1");
} else {
explanation = QString() % QObject::tr("Couldn't start the embedded zcashd.\n\n"

View File

@@ -14,7 +14,7 @@
</rect>
</property>
<property name="windowTitle">
<string>zec-qt-wallet</string>
<string>ZecWallet</string>
</property>
<property name="modal">
<bool>true</bool>

View File

@@ -214,7 +214,7 @@ public:
}
w = new MainWindow();
w->setWindowTitle("zec-qt-wallet v" + QString(APP_VERSION));
w->setWindowTitle("ZecWallet v" + QString(APP_VERSION));
if (parser.isSet(headlessOption)) {
Settings::getInstance()->setHeadless(true);

View File

@@ -521,7 +521,7 @@ void MainWindow::setupSettingsModal() {
rpc->getConnection()->config->proxy = "proxy=127.0.0.1:9050";
QMessageBox::information(this, tr("Enable Tor"),
tr("Connection over Tor has been enabled. To use this feature, you need to restart zec-qt-wallet."),
tr("Connection over Tor has been enabled. To use this feature, you need to restart ZecWallet."),
QMessageBox::Ok);
}
if (isUsingTor && !settings.chkTor->isChecked()) {
@@ -530,7 +530,7 @@ void MainWindow::setupSettingsModal() {
rpc->getConnection()->config->proxy.clear();
QMessageBox::information(this, tr("Disable Tor"),
tr("Connection over Tor has been disabled. To fully disconnect from Tor, you need to restart zec-qt-wallet."),
tr("Connection over Tor has been disabled. To fully disconnect from Tor, you need to restart ZecWallet."),
QMessageBox::Ok);
}
@@ -572,9 +572,9 @@ void MainWindow::donate() {
Settings::getInstance()->isSaplingAddress(ui->inputsCombo->currentText())));
ui->Address1->setCursorPosition(0);
ui->Amount1->setText("0.01");
ui->MemoTxt1->setText(tr("Thanks for supporting zec-qt-wallet!"));
ui->MemoTxt1->setText(tr("Thanks for supporting ZecWallet!"));
ui->statusBar->showMessage(tr("Donate 0.01 ") % Settings::getTokenName() % tr(" to support zec-qt-wallet"));
ui->statusBar->showMessage(tr("Donate 0.01 ") % Settings::getTokenName() % tr(" to support ZecWallet"));
// And switch to the send tab.
ui->tabWidget->setCurrentIndex(1);

View File

@@ -11,7 +11,7 @@
</rect>
</property>
<property name="windowTitle">
<string>zec-qt-wallet</string>
<string>ZecWallet</string>
</property>
<property name="windowIcon">
<iconset resource="../application.qrc">

View File

@@ -81,7 +81,7 @@
<item row="3" column="0">
<widget class="QCheckBox" name="chkInternetConn">
<property name="text">
<string>Allow connections over the internet via zec-qt-wallet wormhole</string>
<string>Allow connections over the internet via ZecWallet wormhole</string>
</property>
</widget>
</item>

View File

@@ -713,7 +713,7 @@ void RPC::updateUI(bool anyUnconfirmed) {
};
// Function to process reply of the listunspent and z_listunspent API calls, used below.
bool RPC::processUnspent(const json& reply) {
bool RPC::processUnspent(const json& reply, QMap<QString, double>* balancesMap, QList<UnspentOutput>* newUtxos) {
bool anyUnconfirmed = false;
for (auto& it : reply.get<json::array_t>()) {
QString qsAddr = QString::fromStdString(it["address"]);
@@ -722,12 +722,12 @@ bool RPC::processUnspent(const json& reply) {
anyUnconfirmed = true;
}
utxos->push_back(
newUtxos->push_back(
UnspentOutput{ qsAddr, QString::fromStdString(it["txid"]),
Settings::getDecimalString(it["amount"].get<json::number_float_t>()),
(int)confirmations, it["spendable"].get<json::boolean_t>() });
(*allBalances)[qsAddr] = (*allBalances)[qsAddr] + it["amount"].get<json::number_float_t>();
(*balancesMap)[qsAddr] = (*balancesMap)[qsAddr] + it["amount"].get<json::number_float_t>();
}
return anyUnconfirmed;
};
@@ -754,18 +754,23 @@ void RPC::refreshBalances() {
});
// 2. Get the UTXOs
// First, create a new UTXO list, deleting the old one;
delete utxos;
utxos = new QList<UnspentOutput>();
delete allBalances;
allBalances = new QMap<QString, double>();
// First, create a new UTXO list. It will be replacing the existing list when everything is processed.
auto newUtxos = new QList<UnspentOutput>();
auto newBalances = new QMap<QString, double>();
// Call the Transparent and Z unspent APIs serially and then, once they're done, update the UI
getTransparentUnspent([=] (json reply) {
auto anyTUnconfirmed = processUnspent(reply);
auto anyTUnconfirmed = processUnspent(reply, newBalances, newUtxos);
getZUnspent([=] (json reply) {
auto anyZUnconfirmed = processUnspent(reply);
auto anyZUnconfirmed = processUnspent(reply, newBalances, newUtxos);
// Swap out the balances and UTXOs
delete allBalances;
delete utxos;
allBalances = newBalances;
utxos = newUtxos;
updateUI(anyTUnconfirmed || anyZUnconfirmed);
});
@@ -1093,7 +1098,7 @@ void RPC::shutdownZcashd() {
Ui_ConnectionDialog connD;
connD.setupUi(&d);
connD.topIcon->setBasePixmap(QIcon(":/icons/res/icon.ico").pixmap(256, 256));
connD.status->setText(QObject::tr("Please wait for zec-qt-wallet to exit"));
connD.status->setText(QObject::tr("Please wait for ZecWallet to exit"));
connD.statusDetail->setText(QObject::tr("Waiting for zcashd to exit"));
QTimer waiter(main);

View File

@@ -94,7 +94,7 @@ private:
void refreshSentZTrans();
void refreshReceivedZTrans(QList<QString> zaddresses);
bool processUnspent (const json& reply);
bool processUnspent (const json& reply, QMap<QString, double>* newBalances, QList<UnspentOutput>* newUtxos);
void updateUI (bool anyUnconfirmed);
void getInfoThenRefresh(bool force);

View File

@@ -4,6 +4,6 @@ Section: base
Priority: optional
Architecture: amd64
Maintainer: Aditya Kulkarni <zcash@adityapk.com>
Description: zec-qt-wallet is a full node and UI wallet for Zcash.
zec-qt-wallet is a full node and UI wallet for Zcash. It comes with
Description: ZecWallet is a full node and UI wallet for Zcash.
ZecWallet is a full node and UI wallet for Zcash. It comes with
full support for shielded addresses and many apps for Zcash.

View File

@@ -1,13 +1,13 @@
[Desktop Entry]
Name=zec-qt-wallet
Name=ZecWallet
Comment=Full node and wallet for Zcash
GenericName=Wallet
Exec=/usr/local/bin/zec-qt-wallet
Icon=zec-qt-wallet.xpm
Exec=/usr/local/bin/zecwallet
Icon=zecwallet.xpm
Type=Application
StartupNotify=true
StartupWMClass=zecqtwallet
StartupWMClass=zecwallet
Categories=Utility;
MimeType=text/plain;inode/directory;
Keywords=zec-qt-wallet;
Keywords=zecwallet;

View File

@@ -60,7 +60,7 @@ export PATH=$PATH:/usr/local/bin
#Clean
echo -n "Cleaning..............."
make distclean >/dev/null 2>&1
rm -f artifacts/macOS-zec-qt-wallet-v$APP_VERSION.dmg
rm -f artifacts/macOS-zecwallet-v$APP_VERSION.dmg
echo "[OK]"
@@ -78,26 +78,27 @@ echo "[OK]"
#Qt deploy
echo -n "Deploying.............."
mkdir artifacts >/dev/null 2>&1
rm -f artifcats/zec-qt-wallet.dmg >/dev/null 2>&1
rm -f artifcats/zecwallet.dmg >/dev/null 2>&1
rm -f artifacts/rw* >/dev/null 2>&1
cp $ZCASH_DIR/src/zcashd zec-qt-wallet.app/Contents/MacOS/
cp $ZCASH_DIR/src/zcash-cli zec-qt-wallet.app/Contents/MacOS/
$QT_PATH/bin/macdeployqt zec-qt-wallet.app
cp $ZCASH_DIR/src/zcashd zecwallet.app/Contents/MacOS/
cp $ZCASH_DIR/src/zcash-cli zecwallet.app/Contents/MacOS/
$QT_PATH/bin/macdeployqt zecwallet.app
echo "[OK]"
echo -n "Building dmg..........."
create-dmg --volname "zec-qt-wallet-v$APP_VERSION" --volicon "res/logo.icns" --window-pos 200 120 --icon "zec-qt-wallet.app" 200 190 --app-drop-link 600 185 --hide-extension "zec-qt-wallet.app" --window-size 800 400 --hdiutil-quiet --background res/dmgbg.png artifacts/macOS-zec-qt-wallet-v$APP_VERSION.dmg zec-qt-wallet.app >/dev/null 2>&1
mv zecwallet.app ZecWallet.app
create-dmg --volname "ZecWallet-v$APP_VERSION" --volicon "res/logo.icns" --window-pos 200 120 --icon "ZecWallet.app" 200 190 --app-drop-link 600 185 --hide-extension "ZecWallet.app" --window-size 800 400 --hdiutil-quiet --background res/dmgbg.png artifacts/macOS-zecwallet-v$APP_VERSION.dmg ZecWallet.app >/dev/null 2>&1
#mkdir bin/dmgbuild >/dev/null 2>&1
#sed "s/RELEASE_VERSION/${APP_VERSION}/g" res/appdmg.json > bin/dmgbuild/appdmg.json
#cp res/logo.icns bin/dmgbuild/
#cp res/dmgbg.png bin/dmgbuild/
#cp -r zec-qt-wallet.app bin/dmgbuild/
#cp -r zecwallet.app bin/dmgbuild/
#appdmg --quiet bin/dmgbuild/appdmg.json artifacts/macOS-zec-qt-wallet-v$APP_VERSION.dmg >/dev/null
if [ ! -f artifacts/macOS-zec-qt-wallet-v$APP_VERSION.dmg ]; then
#appdmg --quiet bin/dmgbuild/appdmg.json artifacts/macOS-zecwallet-v$APP_VERSION.dmg >/dev/null
if [ ! -f artifacts/macOS-zecwallet-v$APP_VERSION.dmg ]; then
echo "[ERROR]"
exit 1
fi

View File

@@ -66,6 +66,7 @@ echo "[OK]"
echo -n "Building..............."
rm -rf bin/zec-qt-wallet* > /dev/null
rm -rf bin/zecwallet* > /dev/null
make clean > /dev/null
make -j$(nproc) > /dev/null
echo "[OK]"
@@ -73,7 +74,7 @@ echo "[OK]"
# Test for Qt
echo -n "Static link............"
if [[ $(ldd zec-qt-wallet | grep -i "Qt") ]]; then
if [[ $(ldd zecwallet | grep -i "Qt") ]]; then
echo "FOUND QT; ABORT";
exit 1
fi
@@ -81,27 +82,27 @@ echo "[OK]"
echo -n "Packaging.............."
mkdir bin/zec-qt-wallet-v$APP_VERSION > /dev/null
strip zec-qt-wallet
mkdir bin/zecwallet-v$APP_VERSION > /dev/null
strip zecwallet
cp zec-qt-wallet bin/zec-qt-wallet-v$APP_VERSION > /dev/null
cp $ZCASH_DIR/artifacts/zcashd bin/zec-qt-wallet-v$APP_VERSION > /dev/null
cp $ZCASH_DIR/artifacts/zcash-cli bin/zec-qt-wallet-v$APP_VERSION > /dev/null
cp README.md bin/zec-qt-wallet-v$APP_VERSION > /dev/null
cp LICENSE bin/zec-qt-wallet-v$APP_VERSION > /dev/null
cp zecwallet bin/zecwallet-v$APP_VERSION > /dev/null
cp $ZCASH_DIR/artifacts/zcashd bin/zecwallet-v$APP_VERSION > /dev/null
cp $ZCASH_DIR/artifacts/zcash-cli bin/zecwallet-v$APP_VERSION > /dev/null
cp README.md bin/zecwallet-v$APP_VERSION > /dev/null
cp LICENSE bin/zecwallet-v$APP_VERSION > /dev/null
cd bin && tar czf linux-zec-qt-wallet-v$APP_VERSION.tar.gz zec-qt-wallet-v$APP_VERSION/ > /dev/null
cd bin && tar czf linux-zecwallet-v$APP_VERSION.tar.gz zecwallet-v$APP_VERSION/ > /dev/null
cd ..
mkdir artifacts >/dev/null 2>&1
cp bin/linux-zec-qt-wallet-v$APP_VERSION.tar.gz ./artifacts/linux-binaries-zec-qt-wallet-v$APP_VERSION.tar.gz
cp bin/linux-zecwallet-v$APP_VERSION.tar.gz ./artifacts/linux-binaries-zecwallet-v$APP_VERSION.tar.gz
echo "[OK]"
if [ -f artifacts/linux-binaries-zec-qt-wallet-v$APP_VERSION.tar.gz ] ; then
if [ -f artifacts/linux-binaries-zecwallet-v$APP_VERSION.tar.gz ] ; then
echo -n "Package contents......."
# Test if the package is built OK
if tar tf "artifacts/linux-binaries-zec-qt-wallet-v$APP_VERSION.tar.gz" | wc -l | grep -q "6"; then
if tar tf "artifacts/linux-binaries-zecwallet-v$APP_VERSION.tar.gz" | wc -l | grep -q "6"; then
echo "[OK]"
else
echo "[ERROR]"
@@ -113,24 +114,24 @@ else
fi
echo -n "Building deb..........."
debdir=bin/deb/zec-qt-wallet-v$APP_VERSION
debdir=bin/deb/zecwallet-v$APP_VERSION
mkdir -p $debdir > /dev/null
mkdir $debdir/DEBIAN
mkdir -p $debdir/usr/local/bin
cat src/scripts/control | sed "s/RELEASE_VERSION/$APP_VERSION/g" > $debdir/DEBIAN/control
cp zec-qt-wallet $debdir/usr/local/bin/
cp zecwallet $debdir/usr/local/bin/
cp $ZCASH_DIR/artifacts/zcashd $debdir/usr/local/bin/zqw-zcashd
mkdir -p $debdir/usr/share/pixmaps/
cp res/zec-qt-wallet.xpm $debdir/usr/share/pixmaps/
cp res/zecwallet.xpm $debdir/usr/share/pixmaps/
mkdir -p $debdir/usr/share/applications
cp src/scripts/desktopentry $debdir/usr/share/applications/zec-qt-wallet.desktop
dpkg-deb --build $debdir >/dev/null
cp $debdir.deb artifacts/linux-deb-zec-qt-wallet-v$APP_VERSION.deb
cp $debdir.deb artifacts/linux-deb-zecwallet-v$APP_VERSION.deb
echo "[OK]"
@@ -173,22 +174,22 @@ echo "[OK]"
echo -n "Packaging.............."
mkdir release/zec-qt-wallet-v$APP_VERSION
cp release/zec-qt-wallet.exe release/zec-qt-wallet-v$APP_VERSION
cp $ZCASH_DIR/artifacts/zcashd.exe release/zec-qt-wallet-v$APP_VERSION > /dev/null
cp $ZCASH_DIR/artifacts/zcash-cli.exe release/zec-qt-wallet-v$APP_VERSION > /dev/null
cp README.md release/zec-qt-wallet-v$APP_VERSION
cp LICENSE release/zec-qt-wallet-v$APP_VERSION
cd release && zip -r Windows-binaries-zec-qt-wallet-v$APP_VERSION.zip zec-qt-wallet-v$APP_VERSION/ > /dev/null
mkdir release/zecwallet-v$APP_VERSION
cp release/zecwallet.exe release/zecwallet-v$APP_VERSION
cp $ZCASH_DIR/artifacts/zcashd.exe release/zecwallet-v$APP_VERSION > /dev/null
cp $ZCASH_DIR/artifacts/zcash-cli.exe release/zecwallet-v$APP_VERSION > /dev/null
cp README.md release/zecwallet-v$APP_VERSION
cp LICENSE release/zecwallet-v$APP_VERSION
cd release && zip -r Windows-binaries-zecwallet-v$APP_VERSION.zip zecwallet-v$APP_VERSION/ > /dev/null
cd ..
mkdir artifacts >/dev/null 2>&1
cp release/Windows-binaries-zec-qt-wallet-v$APP_VERSION.zip ./artifacts/
cp release/Windows-binaries-zecwallet-v$APP_VERSION.zip ./artifacts/
echo "[OK]"
if [ -f artifacts/Windows-binaries-zec-qt-wallet-v$APP_VERSION.zip ] ; then
if [ -f artifacts/Windows-binaries-zecwallet-v$APP_VERSION.zip ] ; then
echo -n "Package contents......."
if unzip -l "artifacts/Windows-binaries-zec-qt-wallet-v$APP_VERSION.zip" | wc -l | grep -q "11"; then
if unzip -l "artifacts/Windows-binaries-zecwallet-v$APP_VERSION.zip" | wc -l | grep -q "11"; then
echo "[OK]"
else
echo "[ERROR]"

View File

@@ -2,12 +2,12 @@ param (
[Parameter(Mandatory=$true)][string]$version
)
$target="zec-qt-wallet-v$version"
$target="zecwallet-v$version"
Remove-Item -Path release/wininstaller -Recurse -ErrorAction Ignore | Out-Null
New-Item release/wininstaller -itemtype directory | Out-Null
Copy-Item release/$target/zec-qt-wallet.exe release/wininstaller/
Copy-Item release/$target/zecwallet.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/
@@ -20,10 +20,10 @@ if (!$?) {
exit 1;
}
light.exe -ext WixUIExtension -cultures:en-us release/wininstaller/zec-qt-wallet.wixobj -out release/wininstaller/zec-qt-wallet.msi
light.exe -ext WixUIExtension -cultures:en-us release/wininstaller/zec-qt-wallet.wixobj -out release/wininstaller/zecwallet.msi
if (!$?) {
exit 1;
}
New-Item artifacts -itemtype directory -Force | Out-Null
Copy-Item release/wininstaller/zec-qt-wallet.msi ./artifacts/Windows-installer-$target.msi
Copy-Item release/wininstaller/zecwallet.msi ./artifacts/Windows-installer-$target.msi

View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Product Id="*" Name="zec-qt-wallet vRELEASE_VERSION" Language="1033" Version="RELEASE_VERSION" Manufacturer="zec-qt-wallet-org" UpgradeCode="fb9bf166-b55f-46b5-a990-9189bdf64533">
<Product Id="*" Name="ZecWallet vRELEASE_VERSION" Language="1033" Version="RELEASE_VERSION" Manufacturer="zec-qt-wallet-org" UpgradeCode="fb9bf166-b55f-46b5-a990-9189bdf64533">
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" />
<MajorUpgrade DowngradeErrorMessage="A newer version of [ProductName] is already installed." />
@@ -55,9 +55,9 @@
<Fragment>
<ComponentGroup Id="ProductComponents" Directory="INSTALLFOLDER">
<Component Id="ProductComponent" Guid="0D210F5A-53E0-4E7E-CAAD-15A26995505E">
<File Source="zec-qt-wallet.exe" KeyPath="yes">
<File Source="zecwallet.exe" KeyPath="yes">
<Shortcut Id="startMenuShotcut" Advertise="yes" Directory="ApplicationProgramsFolder"
Name="zec-qt-wallet" WorkingDirectory="INSTALLFOLDER" Icon="zecqtwalleticon.exe" >
Name="ZecWallet" WorkingDirectory="INSTALLFOLDER" Icon="zecqtwalleticon.exe" >
</Shortcut>
</File>
<File Source="LICENSE" />

View File

@@ -342,7 +342,7 @@ QString AppDataServer::connDesc(AppConnectionType t) {
return QObject::tr("Connected directly");
}
else {
return QObject::tr("Connected over the internet via zec-qt-wallet wormhole service");
return QObject::tr("Connected over the internet via ZecWallet wormhole service");
}
}