From: vsr Date: Thu, 3 Feb 2005 13:24:46 +0000 (+0000) Subject: PAL5597 X-Git-Tag: V2_2_0b4~16 X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=commitdiff_plain;h=9959a9373ff132f1b6de6e025b7fb9cd6548908c PAL5597 --- diff --git a/src/SMESHGUI/SMESHGUI.cxx b/src/SMESHGUI/SMESHGUI.cxx index ca77a9b2c..470c41276 100644 --- a/src/SMESHGUI/SMESHGUI.cxx +++ b/src/SMESHGUI/SMESHGUI.cxx @@ -127,6 +127,7 @@ #include #include #include +#include #include "utilities.h" @@ -2583,6 +2584,14 @@ bool SMESHGUI::CustomPopup(QAD_Desktop* parent, QPopupMenu* popup, const QString popup->removeItem( 1134 ); // Clipping popup->removeItem( 2000 ); // Scalar Bar } + // VSR 03/02/05 - check if actor is empty ----- start ----- + vtkUnstructuredGrid* vtkGrid = anActor->GetUnstructuredGrid(); + if ( vtkGrid->GetNumberOfPoints() + vtkGrid->GetNumberOfCells() == 0 ) { + popup->removeItem( QAD_Display_Popup_ID ); + popup->removeItem( QAD_DisplayOnly_Popup_ID ); + popup->removeItem( QAD_Erase_Popup_ID ); + } + // VSR 03/02/05 - check if actor is empty ----- finish ----- } else { // object doesn't have actor