mirror of
https://github.com/Retropex/bitcoin.git
synced 2025-06-02 15:32:34 +02:00
GUI: Restore keyboard shortcuts for context menu entries
This partially reverts f385ad7651
.
This commit is contained in:
parent
b0e5fbf6fa
commit
02b5263cd4
@ -114,9 +114,9 @@ AddressBookPage::AddressBookPage(const PlatformStyle *platformStyle, Mode _mode,
|
|||||||
|
|
||||||
// Build context menu
|
// Build context menu
|
||||||
contextMenu = new QMenu(this);
|
contextMenu = new QMenu(this);
|
||||||
contextMenu->addAction(tr("Copy Address"), this, &AddressBookPage::on_copyAddress_clicked);
|
contextMenu->addAction(tr("&Copy Address"), this, &AddressBookPage::on_copyAddress_clicked);
|
||||||
contextMenu->addAction(tr("Copy Label"), this, &AddressBookPage::onCopyLabelAction);
|
contextMenu->addAction(tr("Copy &Label"), this, &AddressBookPage::onCopyLabelAction);
|
||||||
contextMenu->addAction(tr("Edit"), this, &AddressBookPage::onEditAction);
|
contextMenu->addAction(tr("&Edit"), this, &AddressBookPage::onEditAction);
|
||||||
|
|
||||||
if (tab == SendingTab) {
|
if (tab == SendingTab) {
|
||||||
contextMenu->addAction(tr("Delete"), this, &AddressBookPage::on_deleteAddress_clicked);
|
contextMenu->addAction(tr("Delete"), this, &AddressBookPage::on_deleteAddress_clicked);
|
||||||
|
@ -27,8 +27,8 @@ QRImageWidget::QRImageWidget(QWidget *parent):
|
|||||||
QLabel(parent), contextMenu(nullptr)
|
QLabel(parent), contextMenu(nullptr)
|
||||||
{
|
{
|
||||||
contextMenu = new QMenu(this);
|
contextMenu = new QMenu(this);
|
||||||
contextMenu->addAction(tr("Save Image…"), this, &QRImageWidget::saveImage);
|
contextMenu->addAction(tr("&Save Image…"), this, &QRImageWidget::saveImage);
|
||||||
contextMenu->addAction(tr("Copy Image"), this, &QRImageWidget::copyImage);
|
contextMenu->addAction(tr("&Copy Image"), this, &QRImageWidget::copyImage);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool QRImageWidget::setQR(const QString& data, const QString& text)
|
bool QRImageWidget::setQR(const QString& data, const QString& text)
|
||||||
|
@ -675,11 +675,11 @@ void RPCConsole::setClientModel(ClientModel *model, int bestblock_height, int64_
|
|||||||
|
|
||||||
// create peer table context menu
|
// create peer table context menu
|
||||||
peersTableContextMenu = new QMenu(this);
|
peersTableContextMenu = new QMenu(this);
|
||||||
peersTableContextMenu->addAction(tr("Disconnect"), this, &RPCConsole::disconnectSelectedNode);
|
peersTableContextMenu->addAction(tr("&Disconnect"), this, &RPCConsole::disconnectSelectedNode);
|
||||||
peersTableContextMenu->addAction(ts.ban_for + " " + tr("1 hour"), [this] { banSelectedNode(60 * 60); });
|
peersTableContextMenu->addAction(ts.ban_for + " " + tr("1 &hour"), [this] { banSelectedNode(60 * 60); });
|
||||||
peersTableContextMenu->addAction(ts.ban_for + " " + tr("1 day"), [this] { banSelectedNode(60 * 60 * 24); });
|
peersTableContextMenu->addAction(ts.ban_for + " " + tr("1 &day"), [this] { banSelectedNode(60 * 60 * 24); });
|
||||||
peersTableContextMenu->addAction(ts.ban_for + " " + tr("1 week"), [this] { banSelectedNode(60 * 60 * 24 * 7); });
|
peersTableContextMenu->addAction(ts.ban_for + " " + tr("1 &week"), [this] { banSelectedNode(60 * 60 * 24 * 7); });
|
||||||
peersTableContextMenu->addAction(ts.ban_for + " " + tr("1 year"), [this] { banSelectedNode(60 * 60 * 24 * 365); });
|
peersTableContextMenu->addAction(ts.ban_for + " " + tr("1 &year"), [this] { banSelectedNode(60 * 60 * 24 * 365); });
|
||||||
connect(ui->peerWidget, &QTableView::customContextMenuRequested, this, &RPCConsole::showPeersTableContextMenu);
|
connect(ui->peerWidget, &QTableView::customContextMenuRequested, this, &RPCConsole::showPeersTableContextMenu);
|
||||||
|
|
||||||
// peer table signal handling - update peer details when selecting new node
|
// peer table signal handling - update peer details when selecting new node
|
||||||
@ -701,7 +701,7 @@ void RPCConsole::setClientModel(ClientModel *model, int bestblock_height, int64_
|
|||||||
|
|
||||||
// create ban table context menu
|
// create ban table context menu
|
||||||
banTableContextMenu = new QMenu(this);
|
banTableContextMenu = new QMenu(this);
|
||||||
banTableContextMenu->addAction(tr("Unban"), this, &RPCConsole::unbanSelectedNode);
|
banTableContextMenu->addAction(tr("&Unban"), this, &RPCConsole::unbanSelectedNode);
|
||||||
connect(ui->banlistWidget, &QTableView::customContextMenuRequested, this, &RPCConsole::showBanTableContextMenu);
|
connect(ui->banlistWidget, &QTableView::customContextMenuRequested, this, &RPCConsole::showBanTableContextMenu);
|
||||||
|
|
||||||
// ban table signal handling - clear peer details when clicking a peer in the ban table
|
// ban table signal handling - clear peer details when clicking a peer in the ban table
|
||||||
|
Loading…
Reference in New Issue
Block a user