*/
//================================================================================
- TVisualObjPtr GetVisualObj(int theStudyId, const char* theEntry){
+ TVisualObjPtr GetVisualObj(int theStudyId, const char* theEntry, bool nulData){
TVisualObjPtr aVisualObj;
TVisualObjCont::key_type aKey(theStudyId,theEntry);
try{
#if (OCC_VERSION_MAJOR << 16 | OCC_VERSION_MINOR << 8 | OCC_VERSION_MAINTENANCE) > 0x060100
OCC_CATCH_SIGNALS;
#endif
- objModified = aVisualObj->Update();
+ MESSAGE("GetVisualObj");
+ if (nulData)
+ objModified = aVisualObj->NulData();
+ else
+ objModified = aVisualObj->Update();
}
catch (...) {
#ifdef _DEBUG_
MESSAGE ( "SMESHGUI_VTKUtils::GetVisualObj(), freeMB=" << freeMB
<< ", usedMB=" << usedMB );
#endif
- bool continu = false;
- if ( usedMB * 10 > freeMB )
- // even dont try to show
- SUIT_MessageBox::warning(SMESHGUI::desktop(), QObject::tr("SMESH_WRN_WARNING"),
- QObject::tr("SMESH_NO_MESH_VISUALIZATION"));
- else
- // there is a chance to succeed
- continu = SUIT_MessageBox::warning
- (SMESHGUI::desktop(),
- QObject::tr("SMESH_WRN_WARNING"),
- QObject::tr("SMESH_CONTINUE_MESH_VISUALIZATION"),
- SUIT_MessageBox::Yes | SUIT_MessageBox::No,
- SUIT_MessageBox::Yes ) == SUIT_MessageBox::Yes;
- if ( !continu ) {
- // remove the corresponding actors from all views
- RemoveVisualObjectWithActors( theEntry );
- aVisualObj.reset();
- }
+// bool continu = false;
+// if ( usedMB * 10 > freeMB )
+// // even dont try to show
+// SUIT_MessageBox::warning(SMESHGUI::desktop(), QObject::tr("SMESH_WRN_WARNING"),
+// QObject::tr("SMESH_NO_MESH_VISUALIZATION"));
+// else
+// // there is a chance to succeed
+// continu = SUIT_MessageBox::warning
+// (SMESHGUI::desktop(),
+// QObject::tr("SMESH_WRN_WARNING"),
+// QObject::tr("SMESH_CONTINUE_MESH_VISUALIZATION"),
+// SUIT_MessageBox::Yes | SUIT_MessageBox::No,
+// SUIT_MessageBox::Yes ) == SUIT_MessageBox::Yes;
+// if ( !continu ) {
+// // remove the corresponding actors from all views
+// RemoveVisualObjectWithActors( theEntry );
+// aVisualObj.reset();
+// }
}
}
bool UpdateView(SUIT_ViewWindow *theWnd, EDisplaing theAction, const char* theEntry)
{
+ MESSAGE("UpdateView");
bool OK = false;
SVTK_ViewWindow* aViewWnd = GetVtkViewWindow(theWnd);
if (!aViewWnd)
bool UpdateView(EDisplaing theAction, const char* theEntry){
+ MESSAGE("UpdateView");
SalomeApp_Study* aStudy = dynamic_cast< SalomeApp_Study* >( GetActiveStudy() );
SalomeApp_Application* app = dynamic_cast< SalomeApp_Application* >( aStudy->application() );
SUIT_ViewWindow *aWnd = app->activeViewManager()->getActiveView();
bool Update(const Handle(SALOME_InteractiveObject)& theIO, bool theDisplay)
{
+ MESSAGE("Update");
_PTR(Study) aStudy = GetActiveStudyDocument();
CORBA::Long anId = aStudy->StudyId();
if ( TVisualObjPtr aVisualObj = SMESH::GetVisualObj(anId,theIO->getEntry())) {
return false;
}
+ bool UpdateNulData(const Handle(SALOME_InteractiveObject)& theIO, bool theDisplay)
+ {
+ MESSAGE("UpdateNulData");
+ _PTR(Study) aStudy = GetActiveStudyDocument();
+ CORBA::Long anId = aStudy->StudyId();
+ if ( TVisualObjPtr aVisualObj = SMESH::GetVisualObj(anId,theIO->getEntry(), true)) {
+ if ( theDisplay )
+ UpdateView(SMESH::eDisplay,theIO->getEntry());
+ return true;
+ }
+ return false;
+ }
void UpdateSelectionProp( SMESHGUI* theModule ) {
if( !theModule )