Forum: Warning Dialog in "Create Group" doesn't disappear

This commit is contained in:
imn 2014-03-05 12:55:14 +04:00
parent 61a30de68f
commit ece8933d2e

View File

@ -787,12 +787,16 @@ int GroupGUI_GroupDlg::getSelectedSubshapes (TColStd_IndexedMapOfInteger& theMap
TopExp::MapShapes(aMainShape, aMainMap);
TopExp_Explorer anExp (aShape, getShapeType());
bool isShowWarning = true;
for (; anExp.More(); anExp.Next()) {
TopoDS_Shape aSubShape = anExp.Current();
int anIndex = aMainMap.FindIndex(aSubShape);
if (anIndex == 0) {
SUIT_MessageBox::warning(app->desktop(), QObject::tr("WRN_WARNING"),
if (isShowWarning) {
SUIT_MessageBox::warning(app->desktop(), QObject::tr("WRN_WARNING"),
tr("WRN_NOT_SUBSHAPE"));
isShowWarning = false;
}
}
else {
if (subSelectionWay() != ALL_SUBSHAPES &&