From 983317b4496eddf1083461b9c0ddf07261a6e9b2 Mon Sep 17 00:00:00 2001 From: Ilya Kitaev Date: Wed, 10 Aug 2016 15:18:56 +0300 Subject: [PATCH] Basic view: real wallet's balance --- main.qml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/main.qml b/main.qml index a7f2deb9..46506b87 100644 --- a/main.qml +++ b/main.qml @@ -143,6 +143,8 @@ ApplicationWindow { console.log("opening wallet at: ", wallet_path); // TODO: wallet password dialog wallet = walletManager.openWallet(wallet_path, "", persistentSettings.testnet); + + if (wallet.status !== Wallet.Status_Ok) { console.log("Error opening wallet: ", wallet.errorString); informationPopup.title = qsTr("Error") + translationManager.emptyString; @@ -164,8 +166,9 @@ ApplicationWindow { function onWalletUpdate() { console.log(">>> wallet updated") - leftPanel.unlockedBalanceText = walletManager.displayAmount(wallet.unlockedBalance); - leftPanel.balanceText = walletManager.displayAmount(wallet.balance); + basicPanel.unlockedBalanceText = leftPanel.unlockedBalanceText = walletManager.displayAmount(wallet.unlockedBalance); + basicPanel.balanceText = leftPanel.balanceText = walletManager.displayAmount(wallet.balance); + } function onWalletRefresh() {