Showing the changes to interface/src/scripting/AccountScriptingInterface.cpp (1 of 2 files). Show all
Unified · Split
| @@ -15,8 +15,9 @@ · 14 unmodified lines | |||
| 15 | 15 | ||
| 16 | AccountScriptingInterface::AccountScriptingInterface() { | 16 | AccountScriptingInterface::AccountScriptingInterface() { |
| 17 | AccountManager& accountManager = AccountManager::getInstance(); | 17 | AccountManager& accountManager = AccountManager::getInstance(); |
| 18 | connect(&accountManager, &AccountManager::balanceChanged, this, | 18 | bool succ = connect(&accountManager, &AccountManager::balanceChanged, this, |
| 19 | &AccountScriptingInterface::updateBalance); | 19 | &AccountScriptingInterface::updateBalance); |
| 20 | |||
| 20 | } | 21 | } |
| 21 | 22 | ||
| 22 | AccountScriptingInterface* AccountScriptingInterface::getInstance() { | 23 | AccountScriptingInterface* AccountScriptingInterface::getInstance() { |
| @@ -34,7 +35,7 @@ bool AccountScriptingInterface::isLoggedIn() { · 11 unmodified lines | |||
| 34 | return accountManager.isLoggedIn(); | 35 | return accountManager.isLoggedIn(); |
| 35 | } | 36 | } |
| 36 | 37 | ||
| 37 | void AccountScriptingInterface::updateBalance(qint64 newBalance) { | 38 | void AccountScriptingInterface::updateBalance() { |
| 38 | AccountManager& accountManager = AccountManager::getInstance(); | 39 | AccountManager& accountManager = AccountManager::getInstance(); |
| 39 | emit balanceChanged(accountManager.getAccountInfo().getBalanceInSatoshis()); | 40 | emit balanceChanged(accountManager.getAccountInfo().getBalanceInSatoshis()); |
| 40 | } | 41 | } |