mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-03-30 18:35:54 +02:00
gui: Add thread to run background activity in WalletController
This commit is contained in:
@@ -26,11 +26,17 @@ WalletController::WalletController(interfaces::Node& node, const PlatformStyle*
|
||||
for (std::unique_ptr<interfaces::Wallet>& wallet : m_node.getWallets()) {
|
||||
getOrCreateWallet(std::move(wallet));
|
||||
}
|
||||
|
||||
m_activity_thread.start();
|
||||
}
|
||||
|
||||
// Not using the default destructor because not all member types definitions are
|
||||
// available in the header, just forward declared.
|
||||
WalletController::~WalletController() {}
|
||||
WalletController::~WalletController()
|
||||
{
|
||||
m_activity_thread.quit();
|
||||
m_activity_thread.wait();
|
||||
}
|
||||
|
||||
std::vector<WalletModel*> WalletController::getWallets() const
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user