mirror of
https://git.salome-platform.org/gitpub/modules/geom.git
synced 2024-12-26 17:30:35 +05:00
21939: Issue a warning dialog if the result of MakeShell is a compound of faces
This commit is contained in:
parent
d7caf30133
commit
6fa43b8d27
@ -32,6 +32,7 @@
|
||||
|
||||
#include <GEOMImpl_Types.hxx>
|
||||
|
||||
#include <SUIT_MessageBox.h>
|
||||
#include <SUIT_ResourceMgr.h>
|
||||
#include <SUIT_Session.h>
|
||||
#include <SalomeApp_Application.h>
|
||||
@ -260,8 +261,17 @@ bool BuildGUI_ShellDlg::execute( ObjectList& objects )
|
||||
|
||||
GEOM::GEOM_Object_var anObj = anOper->MakeShell( objlist.in() );
|
||||
|
||||
if ( !anObj->_is_nil() )
|
||||
if ( !anObj->_is_nil() ) {
|
||||
TopoDS_Shape aShell;
|
||||
GEOMBase::GetShape(anObj, aShell, TopAbs_SHELL);
|
||||
|
||||
if (aShell.IsNull()) {
|
||||
SUIT_MessageBox::warning(this,
|
||||
QObject::tr("GEOM_WRN_WARNING"),
|
||||
QObject::tr("GEOM_WRN_FACES_NOT_SHELL"));
|
||||
}
|
||||
objects.push_back( anObj._retn() );
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@ -2316,6 +2316,10 @@ Please, select face, shell or solid and try again</translation>
|
||||
<source>GEOM_WRN_WARNING</source>
|
||||
<translation>Warning</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>GEOM_WRN_FACES_NOT_SHELL</source>
|
||||
<translation>Unable to create a shell. Result is a compound of faces.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>WRN_SHAPE_UNCLOSED</source>
|
||||
<translation>Unable to create solid from unclosed shape %1</translation>
|
||||
|
Loading…
Reference in New Issue
Block a user