mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-12-26 17:30:35 +05:00
0020830: EDF 1357 GUI : Hide/Show Icon
This commit is contained in:
parent
3b2ddf07cc
commit
1ad6590ec1
@ -42,6 +42,7 @@
|
||||
#include "SMESHGUI_FilterDlg.h"
|
||||
#include "SMESHGUI_FilterLibraryDlg.h"
|
||||
#include "SMESHGUI_FindElemByPointDlg.h"
|
||||
#include "SMESHGUI_GEOMGenUtils.h"
|
||||
#include "SMESHGUI_GroupDlg.h"
|
||||
#include "SMESHGUI_GroupOnShapeDlg.h"
|
||||
#include "SMESHGUI_GroupOpDlg.h"
|
||||
@ -5453,3 +5454,32 @@ void SMESHGUI::onHypothesisEdit( int result )
|
||||
SMESHGUI::Modified();
|
||||
updateObjBrowser( true );
|
||||
}
|
||||
|
||||
/*!
|
||||
* \brief Virtual public slot
|
||||
*
|
||||
* This method updates visibility state
|
||||
* Redefined to make visible geometry objects
|
||||
*/
|
||||
void SMESHGUI::initVisibilityState( SUIT_DataObject* theObject )
|
||||
{
|
||||
// in fact, here we assume that all geometry objects presentable
|
||||
LightApp_DataObject* anObj = dynamic_cast<LightApp_DataObject*>(theObject);
|
||||
if (!anObj)
|
||||
return;
|
||||
|
||||
SalomeApp_Application* app =
|
||||
dynamic_cast< SalomeApp_Application* >( SUIT_Session::session()->activeApplication() );
|
||||
if( !app )
|
||||
return;
|
||||
|
||||
SalomeApp_Study* appStudy = dynamic_cast<SalomeApp_Study*>( app->activeStudy() );
|
||||
if( !appStudy )
|
||||
return;
|
||||
|
||||
_PTR(Study) aStudy = appStudy->studyDS();
|
||||
_PTR(SObject) aSObject( aStudy->FindObjectID( anObj->entry().toLatin1().data() ) );
|
||||
SMESH::SMESH_IDSource_var anID = SMESH::SMESH_IDSource::_narrow( SMESH::SObjectToObject( aSObject ));
|
||||
if ( !anID->_is_nil() && anObj->visibilityState() == SUIT_DataObject::Unpresentable )
|
||||
anObj->setVisibilityState( SUIT_DataObject::Hidden );
|
||||
}
|
||||
|
@ -50,6 +50,7 @@ class vtkObject;
|
||||
class QDialog;
|
||||
|
||||
class SUIT_Desktop;
|
||||
class SUIT_DataObject;
|
||||
class SUIT_Study;
|
||||
class SUIT_ViewWindow;
|
||||
class SUIT_ResourceMgr;
|
||||
@ -191,6 +192,8 @@ protected:
|
||||
void* theClientData,
|
||||
void* theCallData );
|
||||
|
||||
virtual void initVisibilityState( SUIT_DataObject* );
|
||||
|
||||
private:
|
||||
void OnEditDelete();
|
||||
int addVtkFontPref( const QString& label,
|
||||
|
Loading…
Reference in New Issue
Block a user