ui: Support wallets unloaded dynamically
Summary:
Wallets unloaded dynamically will be reflected in the gui.
Partial backport of Core PR13111
https://github.com/bitcoin/bitcoin/pull/13111/commits/0ee77b20771fe34f8dbde6b16d7e2637859baec3
Reviewer note: we migrated from boost::bind to std::bind in D4133.
Depends on D4253
Test Plan:
make ./bitcoin-qt Help -> Debug -> Console createwallet test
On the main window and the debug window you should have the multiwallet drop down menu.
Select the test wallet in the main window. Select test in the debug window.
unloadwallet
This should remove the drop down menu from both windows. Additionally the main window should should change to displaying the information for [default_wallet].
unloadwallet
The main window should no longer display any wallet information as no wallets have been loaded.
loadwallet test
The test wallet's information should be displayed in the main window.
Reviewers: deadalnix, Fabien, jasonbcox, O1 Bitcoin ABC, #bitcoin_abc
Reviewed By: jasonbcox, O1 Bitcoin ABC, #bitcoin_abc
Differential Revision: https://reviews.bitcoinabc.org/D4254