From ece8933d2efb23d9866a479d43d3b8a04b2aea7b Mon Sep 17 00:00:00 2001 From: imn Date: Wed, 5 Mar 2014 12:55:14 +0400 Subject: [PATCH] Forum: Warning Dialog in "Create Group" doesn't disappear --- src/GroupGUI/GroupGUI_GroupDlg.cxx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/GroupGUI/GroupGUI_GroupDlg.cxx b/src/GroupGUI/GroupGUI_GroupDlg.cxx index 464bee9e5..70e1b8308 100644 --- a/src/GroupGUI/GroupGUI_GroupDlg.cxx +++ b/src/GroupGUI/GroupGUI_GroupDlg.cxx @@ -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 && -- 2.39.2