| 695 | |
| 696 | #ifdef ENABLE_WALLET |
| 697 | void RPCConsole::addWallet(WalletModel * const walletModel) |
| 698 | { |
| 699 | const QString name = walletModel->getWalletName(); |
| 700 | // use name for text and internal data object (to allow to move to a wallet id later) |
| 701 | QString display_name = name.isEmpty() ? "["+tr("default wallet")+"]" : name; |
| 702 | ui->WalletSelector->addItem(display_name, name); |
| 703 | if (ui->WalletSelector->count() == 2 && !isVisible()) { |
| 704 | // First wallet added, set to default so long as the window isn't presently visible (and potentially in use) |
| 705 | ui->WalletSelector->setCurrentIndex(1); |
| 706 | } |
| 707 | if (ui->WalletSelector->count() > 2) { |
| 708 | ui->WalletSelector->setVisible(true); |
| 709 | ui->WalletSelectorLabel->setVisible(true); |
| 710 | } |
| 711 | } |
| 712 | |
| 713 | void RPCConsole::removeWallet(WalletModel * const walletModel) |
| 714 | { |
nothing calls this directly
no test coverage detected