Add sapling support while generating addresses
This commit is contained in:
@@ -152,6 +152,11 @@ void Settings::setTestnet(bool isTestnet) {
|
||||
this->_isTestnet = isTestnet;
|
||||
}
|
||||
|
||||
bool Settings::isSaplingAddress(QString addr) {
|
||||
return ( isTestnet() && addr.startsWith("ztestsapling")) ||
|
||||
(!isTestnet() && addr.startsWith("zs"));
|
||||
}
|
||||
|
||||
bool Settings::isSyncing() {
|
||||
return _isSyncing;
|
||||
}
|
||||
@@ -160,6 +165,19 @@ void Settings::setSyncing(bool syncing) {
|
||||
this->_isSyncing = syncing;
|
||||
}
|
||||
|
||||
int Settings::getBlockNumber() {
|
||||
return this->_blockNumber;
|
||||
}
|
||||
|
||||
void Settings::setBlockNumber(int number) {
|
||||
this->_blockNumber = number;
|
||||
}
|
||||
|
||||
bool Settings::isSaplingActive() {
|
||||
return (isTestnet() && getBlockNumber() > 280000) ||
|
||||
(!isTestnet() && getBlockNumber() > 419200);
|
||||
}
|
||||
|
||||
double Settings::getZECPrice() {
|
||||
return zecPrice;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user