mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#4176 Enable Del keyboard shortcut for delete commands
This commit is contained in:
@@ -75,6 +75,17 @@ void RicWellPathDeleteFeature::onActionTriggered(bool isChecked)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RicWellPathDeleteFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setText("Delete Well Path(s)");
|
||||
std::vector<RimWellPath*> objects;
|
||||
caf::SelectionManager::instance()->objectsByType(&objects);
|
||||
if (objects.size() > 1u)
|
||||
{
|
||||
actionToSetup->setText("Delete Well Paths");
|
||||
}
|
||||
else
|
||||
{
|
||||
actionToSetup->setText("Delete Well Path");
|
||||
}
|
||||
actionToSetup->setIcon(QIcon(":/Erase.png"));
|
||||
actionToSetup->setShortcut(QKeySequence::Delete);
|
||||
actionToSetup->setShortcutVisibleInContextMenu(true);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user