HomePhabricator

refactor: Move wallet methods out of chain.h and node.h

Description

refactor: Move wallet methods out of chain.h and node.h

Summary:
https://github.com/bitcoin/bitcoin/pull/19099/commits/e4f435047121886edb6e6a6c4e4998e44ed2e36a

Add WalletClient interface so node interface is cleaner and don't need
wallet-specific methods.

The new NodeContext::wallet_client pointer will also be needed to eliminate
global wallet variables like ::vpwallets, because createWallet(), loadWallet(),
getWallets(), etc methods called by the GUI need a way to get a reference to
the list of open wallets if it is no longer a global variable.

Also tweaks splash screen registration for load wallet events to be delayed
until after wallet client is created.

https://github.com/bitcoin-core/gui/pull/102/commits/c056064a4a93be3601a63b37afea41f8b878df79

gui: Fix SplashScreen crash when run with -disablewallet

This is a backport of core#19099 [2/3] and core-gui#102 (small bugfix)

Depends on D10141

Test Plan:
ninja all check-all

Test for bugfix core-gui#102: src/qt/bitcoin-qt -disablewallet

Reviewers: #bitcoin_abc, Fabien

Reviewed By: #bitcoin_abc, Fabien

Subscribers: Klakurka, boardgamesaz, Fabien

Differential Revision: https://reviews.bitcoinabc.org/D10142

Details

Provenance
Russell Yanofsky <russ@yanofsky.org>Authored on May 28 2020, 13:48
PiRKCommitted on Sep 19 2021, 07:57
PiRKPushed on Sep 19 2021, 07:57
Reviewer
Restricted Project
Differential Revision
D10142: refactor: Move wallet methods out of chain.h and node.h
Parents
rABCf70965d1ae5b: refactor: Create interfaces earlier during initialization
Branches
Unknown
Tags
Unknown