mirror of
https://github.com/OPM/ResInsight.git
synced 2025-01-08 07:03:25 -06:00
#4176 Add keyboard shortcuts to Zoom all (Ctrl+Alt+A) and view directions (Ctrl+Alt+N/W/S/etc)
This commit is contained in:
parent
2c7ed49708
commit
e8efe81796
@ -79,5 +79,7 @@ void RicViewZoomAllFeature::onActionTriggered(bool isChecked)
|
||||
void RicViewZoomAllFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setText("Zoom All");
|
||||
actionToSetup->setToolTip("Zoom All (Ctrl+Alt+A)");
|
||||
actionToSetup->setIcon(QIcon(":/ZoomAll16x16.png"));
|
||||
applyShortcutWithHintToAction(actionToSetup, QKeySequence(tr("Ctrl+Alt+A")));
|
||||
}
|
||||
|
@ -315,17 +315,28 @@ void RiuMainWindow::createActions()
|
||||
|
||||
// View actions
|
||||
m_viewFromNorth = new QAction(QIcon(":/SouthViewArrow.png"), "Look South", this);
|
||||
m_viewFromNorth->setToolTip("Look South");
|
||||
m_viewFromNorth->setToolTip("Look South (Ctrl+Alt+S)");
|
||||
m_viewFromNorth->setShortcut(QKeySequence(tr("Ctrl+Alt+S")));
|
||||
|
||||
m_viewFromSouth = new QAction(QIcon(":/NorthViewArrow.png"), "Look North", this);
|
||||
m_viewFromSouth->setToolTip("Look North");
|
||||
m_viewFromSouth->setToolTip("Look North (Ctrl+Alt+N)");
|
||||
m_viewFromSouth->setShortcut(QKeySequence(tr("Ctrl+Alt+N")));
|
||||
|
||||
m_viewFromEast = new QAction(QIcon(":/WestViewArrow.png"), "Look West", this);
|
||||
m_viewFromEast->setToolTip("Look West");
|
||||
m_viewFromEast->setToolTip("Look West (Ctrl+Alt+W)");
|
||||
m_viewFromEast->setShortcut(QKeySequence(tr("Ctrl+Alt+W")));
|
||||
|
||||
m_viewFromWest = new QAction(QIcon(":/EastViewArrow.png"), "Look East", this);
|
||||
m_viewFromWest->setToolTip("Look East");
|
||||
m_viewFromWest->setToolTip("Look East (Ctrl+Alt+E)");
|
||||
m_viewFromWest->setShortcut(QKeySequence(tr("Ctrl+Alt+E")));
|
||||
|
||||
m_viewFromAbove = new QAction(QIcon(":/DownViewArrow.png"), "Look Down", this);
|
||||
m_viewFromAbove->setToolTip("Look Down");
|
||||
m_viewFromAbove->setToolTip("Look Down (Ctrl+Alt+D)");
|
||||
m_viewFromAbove->setShortcut(QKeySequence(tr("Ctrl+Alt+D")));
|
||||
|
||||
m_viewFromBelow = new QAction(QIcon(":/UpViewArrow.png"), "Look Up", this);
|
||||
m_viewFromBelow->setToolTip("Look Up");
|
||||
m_viewFromBelow->setToolTip("Look Up (Ctrl+Alt+U)");
|
||||
m_viewFromBelow->setShortcut(QKeySequence(tr("Ctrl+Alt+U")));
|
||||
|
||||
connect(m_viewFromNorth, SIGNAL(triggered()), SLOT(slotViewFromNorth()));
|
||||
connect(m_viewFromSouth, SIGNAL(triggered()), SLOT(slotViewFromSouth()));
|
||||
|
Loading…
Reference in New Issue
Block a user