mirror of
https://github.com/monero-project/monero-gui.git
synced 2024-12-23 12:09:57 +00:00
make splash less resource intensive
This commit is contained in:
parent
ad2943fb20
commit
f0d2e58376
1 changed files with 8 additions and 4 deletions
8
main.qml
8
main.qml
|
@ -52,7 +52,7 @@ ApplicationWindow {
|
||||||
property var currentWallet;
|
property var currentWallet;
|
||||||
property var transaction;
|
property var transaction;
|
||||||
property alias password : passwordDialog.password
|
property alias password : passwordDialog.password
|
||||||
|
property int splashCounter: 0
|
||||||
|
|
||||||
function altKeyReleased() { ctrlPressed = false; }
|
function altKeyReleased() { ctrlPressed = false; }
|
||||||
|
|
||||||
|
@ -225,11 +225,15 @@ ApplicationWindow {
|
||||||
|
|
||||||
function onWalletNewBlock(blockHeight) {
|
function onWalletNewBlock(blockHeight) {
|
||||||
if (splash.visible) {
|
if (splash.visible) {
|
||||||
var progressText = qsTr("Synchronizing blocks %1/%2").arg(blockHeight.toFixed(0)).arg(currentWallet.daemonBlockChainHeight().toFixed(0));
|
var currHeight = blockHeight.toFixed(0)
|
||||||
|
if(currHeight > splashCounter + 1000){
|
||||||
|
splashCounter = currHeight
|
||||||
|
var progressText = qsTr("Synchronizing blocks %1/%2").arg(currHeight).arg(currentWallet.daemonBlockChainHeight().toFixed(0));
|
||||||
console.log("Progress text: " + progressText);
|
console.log("Progress text: " + progressText);
|
||||||
splash.heightProgressText = progressText
|
splash.heightProgressText = progressText
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
function walletsFound() {
|
function walletsFound() {
|
||||||
|
|
Loading…
Reference in a new issue