From: vsv Date: Fri, 30 Nov 2018 09:17:13 +0000 (+0300) Subject: Fix for renaming: launch renaming only in column #1 X-Git-Tag: End2018~128 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=dcc5c65a487bb9b354431ccdaf1e8b859f195bc5;p=modules%2Fshaper.git Fix for renaming: launch renaming only in column #1 --- diff --git a/src/XGUI/XGUI_ObjectsBrowser.cpp b/src/XGUI/XGUI_ObjectsBrowser.cpp index 7f28e6f41..1862244a5 100644 --- a/src/XGUI/XGUI_ObjectsBrowser.cpp +++ b/src/XGUI/XGUI_ObjectsBrowser.cpp @@ -489,10 +489,12 @@ void XGUI_ObjectsBrowser::onEditItem() // Find index which corresponds the feature QModelIndex aIndex; foreach(QModelIndex aIdx, selectedIndexes()) { - ObjectPtr aFea = dataModel()->object(aIdx); - if (dataModel()->object(aIdx)->isSame(anObject)) { - aIndex = aIdx; - break; + if (aIdx.column() == 1) { + ObjectPtr aFea = dataModel()->object(aIdx); + if (dataModel()->object(aIdx)->isSame(anObject)) { + aIndex = aIdx; + break; + } } } if (aIndex.isValid()) {