From c87cdaea231e3682a5e553ec0f9a73bb7dfba86a Mon Sep 17 00:00:00 2001 From: thalieht Date: Wed, 25 Jan 2017 11:02:15 +0200 Subject: [PATCH] add hotkeys for Trackerlist Peerlist etc. --- src/gui/properties/proptabbar.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/gui/properties/proptabbar.cpp b/src/gui/properties/proptabbar.cpp index 11be20734..3cdaf06db 100644 --- a/src/gui/properties/proptabbar.cpp +++ b/src/gui/properties/proptabbar.cpp @@ -44,29 +44,34 @@ PropTabBar::PropTabBar(QWidget *parent) : m_btnGroup = new QButtonGroup(this); // General tab QPushButton *main_infos_button = new QPushButton(GuiIconProvider::instance()->getIcon("document-properties"), tr("General"), parent); - main_infos_button->setShortcut(QKeySequence(QString::fromUtf8("Alt+P"))); + main_infos_button->setShortcut(QKeySequence(Qt::ALT + Qt::Key_G)); addWidget(main_infos_button); m_btnGroup->addButton(main_infos_button, MAIN_TAB); // Trackers tab QPushButton *trackers_button = new QPushButton(GuiIconProvider::instance()->getIcon("network-server"), tr("Trackers"), parent); + trackers_button->setShortcut(QKeySequence(Qt::ALT + Qt::Key_C)); addWidget(trackers_button); m_btnGroup->addButton(trackers_button, TRACKERS_TAB); // Peers tab QPushButton *peers_button = new QPushButton(GuiIconProvider::instance()->getIcon("edit-find-user"), tr("Peers"), parent); + peers_button->setShortcut(QKeySequence(Qt::ALT + Qt::Key_R)); addWidget(peers_button); m_btnGroup->addButton(peers_button, PEERS_TAB); // URL seeds tab QPushButton *urlseeds_button = new QPushButton(GuiIconProvider::instance()->getIcon("network-server"), tr("HTTP Sources"), parent); + urlseeds_button->setShortcut(QKeySequence(Qt::ALT + Qt::Key_B)); addWidget(urlseeds_button); m_btnGroup->addButton(urlseeds_button, URLSEEDS_TAB); // Files tab QPushButton *files_button = new QPushButton(GuiIconProvider::instance()->getIcon("inode-directory"), tr("Content"), parent); + files_button->setShortcut(QKeySequence(Qt::ALT + Qt::Key_Z)); addWidget(files_button); m_btnGroup->addButton(files_button, FILES_TAB); // Spacer addItem(new QSpacerItem(0, 0, QSizePolicy::Expanding, QSizePolicy::Fixed)); // Speed tab QPushButton *speed_button = new QPushButton(GuiIconProvider::instance()->getIcon("office-chart-line"), tr("Speed"), parent); + speed_button->setShortcut(QKeySequence(Qt::ALT + Qt::Key_D)); addWidget(speed_button); m_btnGroup->addButton(speed_button, SPEED_TAB); // SIGNAL/SLOT