connect( anApp, SIGNAL( operationFinished( const QString&, const QString&, const QStringList& ) ),
this, SLOT( onExternalOperationFinished( const QString&, const QString&, const QStringList& ) ) );
+ HYDROGUI_Tool::setOCCActionShown( this, OCCViewer_ViewWindow::MaximizedId, false );
+
return aRes;
}
myObjectStateMap.clear();
myShapesMap.clear();
+ myVTKPrsMap.clear();
// clear the data model's list of copying objects
HYDROGUI_DataModel::changeCopyingObjects( HYDROData_SequenceOfObjects() );
disconnect( getApp(), SIGNAL( operationFinished( const QString&, const QString&, const QStringList& ) ),
this, SLOT( onExternalOperationFinished( const QString&, const QString&, const QStringList& ) ) );
+ HYDROGUI_Tool::setOCCActionShown( this, OCCViewer_ViewWindow::MaximizedId, true );
+
return LightApp_Module::deactivateModule( theStudy );
}
bool anIsMustBeUpdatedImage = false;
bool anIsPolyline = false;
bool anIsProfile = false;
+ bool anAllAreProfiles = false;
bool anIsBathymetry = false;
bool anIsCalculation = false;
bool anIsImmersibleZone = false;
// check the selected data model objects
HYDROData_SequenceOfObjects aSeq = HYDROGUI_Tool::GetSelectedObjects( this );
+ int aNbOfSelectedProfiles = 0;
for( Standard_Integer anIndex = 1, aLength = aSeq.Length(); anIndex <= aLength; anIndex++ )
{
Handle(HYDROData_Entity) anObject = aSeq.Value( anIndex );
}
else if( anObject->GetKind() == KIND_POLYLINEXY )
anIsPolyline = true;
- else if( anObject->GetKind() == KIND_PROFILE )
+ else if( anObject->GetKind() == KIND_PROFILE ) {
anIsProfile = true;
+ aNbOfSelectedProfiles++;
+ }
else if( anObject->GetKind() == KIND_CALCULATION )
anIsCalculation = true;
else if( anObject->GetKind() == KIND_IMMERSIBLE_ZONE )
anIsGeomObject = HYDROData_Tool::IsGeometryObject( anObject );
}
+ // Check if all selected objects are profiles
+ anAllAreProfiles = ( aNbOfSelectedProfiles > 0 ) &&
+ ( aNbOfSelectedProfiles == aSeq.Length() );
+
// check the selected partitions
if( !anIsSelectedDataObjects && anIsObjectBrowser )
{
case KIND_PROFILE:
theMenu->addAction( action( CreateProfileId ) );
theMenu->addAction( action( ImportProfilesId ) );
+ theMenu->addAction( action( AllGeoreferencementId ) );
break;
case KIND_VISUAL_STATE:
theMenu->addAction( action( SaveVisualStateId ) );
else if( anIsProfile )
{
theMenu->addAction( action( EditProfileId ) );
+ theMenu->addAction( action( SelectedGeoreferencementId ) );
theMenu->addSeparator();
}
else if( anIsCalculation )
}
}
+ if ( anAllAreProfiles ) {
+ theMenu->addAction( action( SelectedGeoreferencementId ) );
+ theMenu->addSeparator();
+ }
+
theMenu->addAction( action( DeleteId ) );
theMenu->addSeparator();
if( OCCViewer_ViewFrame* aViewFrame = dynamic_cast<OCCViewer_ViewFrame*>( theViewWindow ) )
{
aViewFrame->onTopView();
+
+ HYDROGUI_Tool::setOCCActionShown( aViewFrame, OCCViewer_ViewWindow::MaximizedId, false );
}
}
}