#include <SVTK_ViewWindow.h>
#include <SVTK_ViewModel.h>
+#include <VTKViewer_ViewManager.h>
+
#include "SMESHGUI_Utils.h"
#include "SMESHGUI_GEOMGenUtils.h"
#include "SMESHGUI_MeshUtils.h"
mgr->setValue( "SMESH", "SettingsElementsSelectTol", aTolItems );
// update current study settings
- SMESH::UpdateSelectionProp();
+ SMESH::UpdateSelectionProp( this );
if( vtkwnd ) {
// update VTK viewer properties
//=============================================================================
bool SMESHGUI::SetSettings(SUIT_Desktop* parent)
{
- MESSAGE("SMESHGUI::SetSettings.");
SMESHGUI::GetSMESHGUI();
SUIT_ResourceMgr* mgr = resourceMgr();
action( 10001 )->setOn( false );
action( 10003 )->setOn( true );
}
+
action( 10003 )->setOn( Shrink );
// Automatic Update
action( 10071 )->setOn( false );
// Selection
- SMESH::UpdateSelectionProp();
+ SMESH::UpdateSelectionProp( this );
// menus disable
- //action( 111 )->setEnabled( false ); // IMPORT DAT
+ action( 111 )->setEnabled( false ); // IMPORT DAT
+
+ //action( 112 )->setEnabled( false );
//parent->menuBar()->setItemEnabled(112, false); // IMPORT UNV
return true;
createSMESHAction( 6012, "TAPER", "ICON_TAPER" , 0, true );
createSMESHAction( 6013, "ASPECT", "ICON_ASPECT" , 0, true );
createSMESHAction( 6014, "MIN_ANG", "ICON_ANGLE" , 0, true );
- createSMESHAction( 6015, "WRAP", "ICON_WRAP" , 0, true );
+ createSMESHAction( 6015, "WARP", "ICON_WARP" , 0, true );
createSMESHAction( 6016, "SKEW", "ICON_SKEW", 0, true );
createSMESHAction( 6017, "ASPECT_3D", "ICON_ASPECT_3D", 0, true );
createSMESHAction( 6018, "LENGTH_2D", "ICON_LENGTH_2D", 0, true );
popupMgr()->setRule( action( 6014 ), aMeshInVtkHasFaces, true );
popupMgr()->setRule( action( 6014 ), "controlMode = 'eMinimumAngle'", false );
- popupMgr()->insert( action( 6015 ), anId, -1 ); // WRAP
+ popupMgr()->insert( action( 6015 ), anId, -1 ); // WARP
popupMgr()->setRule( action( 6015 ), aMeshInVtkHasFaces, true );
popupMgr()->setRule( action( 6015 ), "controlMode = 'eWarping'", false );
popupMgr()->setRule( action( 302 ), aRule + "&&" + isNotEmpty, true );
popupMgr()->insert( separator(), -1, -1 );
+
+ connect( application(), SIGNAL( viewManagerAdded( SUIT_ViewManager* ) ),
+ this, SLOT( onViewManagerAdded( SUIT_ViewManager* ) ) );
}
bool SMESHGUI::activateModule( SUIT_Study* study )
setMenuShown( true );
setToolShown( true );
+ SetSettings( desktop() );
return res;
- //SetSettings( desktop() );
}
bool SMESHGUI::deactivateModule( SUIT_Study* study )
{
list.append( SVTK_Viewer::Type() );
}
+
+void SMESHGUI::onViewManagerAdded( SUIT_ViewManager* mgr )
+{
+ if( dynamic_cast<VTKViewer_ViewManager*>( mgr ) )
+ SMESH::UpdateSelectionProp( this );
+}