| 61 | } |
| 62 | |
| 63 | void WalletModel::startPollBalance() |
| 64 | { |
| 65 | // Update the cached balance right away, so every view can make use of it, |
| 66 | // so them don't need to waste resources recalculating it. |
| 67 | pollBalanceChanged(); |
| 68 | |
| 69 | // This timer will be fired repeatedly to update the balance |
| 70 | // Since the QTimer::timeout is a private signal, it cannot be used |
| 71 | // in the GUIUtil::ExceptionSafeConnect directly. |
| 72 | connect(timer, &QTimer::timeout, this, &WalletModel::timerTimeout); |
| 73 | GUIUtil::ExceptionSafeConnect(this, &WalletModel::timerTimeout, this, &WalletModel::pollBalanceChanged); |
| 74 | timer->start(MODEL_UPDATE_DELAY); |
| 75 | } |
| 76 | |
| 77 | void WalletModel::setClientModel(ClientModel* client_model) |
| 78 | { |
nothing calls this directly
no test coverage detected