mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-18 13:17:55 +02:00
Merge 9bd109b78d into merged_master (Bitcoin PR #17120)
This commit is contained in:
commit
3feea6cb08
3 changed files with 17 additions and 7 deletions
|
|
@ -109,6 +109,12 @@ WalletModel* WalletController::getOrCreateWallet(std::unique_ptr<interfaces::Wal
|
|||
wallet_model->setParent(this);
|
||||
m_wallets.push_back(wallet_model);
|
||||
|
||||
// WalletModel::startPollBalance needs to be called in a thread managed by
|
||||
// Qt because of startTimer. Considering the current thread can be a RPC
|
||||
// thread, better delegate the calling to Qt with Qt::AutoConnection.
|
||||
const bool called = QMetaObject::invokeMethod(wallet_model, "startPollBalance");
|
||||
assert(called);
|
||||
|
||||
connect(wallet_model, &WalletModel::unload, [this, wallet_model] {
|
||||
// Defer removeAndDeleteWallet when no modal widget is active.
|
||||
// TODO: remove this workaround by removing usage of QDiallog::exec.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue