From 5d29cd0ac64b5e541b8c75775f1f5135c7ca6726 Mon Sep 17 00:00:00 2001 From: Magne Sjaastad Date: Wed, 15 Mar 2017 12:36:52 +0100 Subject: [PATCH] #872 Fixed ordering of actions in menu --- .../ProjectDataModel/RimContextCommandBuilder.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ApplicationCode/ProjectDataModel/RimContextCommandBuilder.cpp b/ApplicationCode/ProjectDataModel/RimContextCommandBuilder.cpp index 9b123d2d6c..caf3bd484d 100644 --- a/ApplicationCode/ProjectDataModel/RimContextCommandBuilder.cpp +++ b/ApplicationCode/ProjectDataModel/RimContextCommandBuilder.cpp @@ -405,7 +405,11 @@ QStringList RimContextCommandBuilder::commandsFromSelection() } else if (dynamic_cast(uiItem)) { - commandIds << "RicAsciiExportSummaryPlotFeature"; + // Do not add twice to make sure the first position in the menu is used for the action + if (!commandIds.contains("RicAsciiExportSummaryPlotFeature")) + { + commandIds << "RicAsciiExportSummaryPlotFeature"; + } } else if (dynamic_cast(uiItem)) {