X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHYDROGUI%2FHYDROGUI_BathymetrySelectionOp.cxx;h=8f723525b11fc5676efb61d15b84b8d3d5597266;hb=92c3e5ddda56d434c842e744b3db1341ad2f87f5;hp=aa21b0046331c17c568501ee06eb9a2579e9f89c;hpb=3c05f4947cb1d3fa887ac56cc901f28fe7022414;p=modules%2Fhydro.git diff --git a/src/HYDROGUI/HYDROGUI_BathymetrySelectionOp.cxx b/src/HYDROGUI/HYDROGUI_BathymetrySelectionOp.cxx index aa21b004..8f723525 100644 --- a/src/HYDROGUI/HYDROGUI_BathymetrySelectionOp.cxx +++ b/src/HYDROGUI/HYDROGUI_BathymetrySelectionOp.cxx @@ -32,7 +32,7 @@ #include #include -#define _DEVDEBUG_ +//#define _DEVDEBUG_ #include "HYDRO_trace.hxx" HYDROGUI_BathymetrySelectionOp::HYDROGUI_BathymetrySelectionOp( HYDROGUI_Module* theModule ) @@ -110,32 +110,14 @@ void HYDROGUI_BathymetrySelectionOp::activateSelection( bool isActive ) QList baths = getShownBathymetries( module() ); if( isActive ) { -// QList aSelectorList; -// QString aViewType = OCCViewer_Viewer::Type(); -// LightApp_SelectionMgr* aSelectionMgr = module()->getApp()->selectionMgr(); -// aSelectionMgr->selectors(aViewType, aSelectorList); -// QList::iterator anIter, anIterEnd = aSelectorList.end(); -// for( anIter = aSelectorList.begin(); anIter != anIterEnd; anIter++ ) -// { -// SUIT_Selector* aSelector = *anIter; -// aSelector->setEnabled( false ); -// } - const int aSelectionMode = 1; // Cf. AIS_PointCloud 0=selection by points ? - //ctx->Deactivate( Standard_True ); - //ctx->OpenLocalContext( Standard_True ); foreach( Handle(HYDROGUI_BathymetryPrs) bath, baths ) { DEBTRACE("bathy name: " << bath->GetShape()->getObject()->GetName().toStdString()); ctx->Deactivate(bath); ctx->RemoveFilters(); - //ctx->Activate( bath, aSelectionMode, Standard_True ); ctx->SetSelectionModeActive (bath, aSelectionMode, Standard_True, AIS_SelectionModesConcurrency_Multiple, Standard_False); - ctx->SetSelectionModeActive (bath, 0, Standard_True, AIS_SelectionModesConcurrency_Multiple, Standard_False); bath->SetAutoHilight( Standard_False ); // True bloque le passage dans hilightSelected... -// DEBTRACE("immediateMode: " << ctx->MainPrsMgr()->IsImmediateModeOn()); -// if (!ctx->MainPrsMgr()->IsImmediateModeOn()) -// ctx->MainPrsMgr()->BeginImmediateDraw(); } ctx->UpdateCurrentViewer(); } @@ -144,12 +126,12 @@ void HYDROGUI_BathymetrySelectionOp::activateSelection( bool isActive ) foreach( Handle(HYDROGUI_BathymetryPrs) bath, baths ) { bath->ClearSelected(); + bath->ClearSelectedPoints(); bath->SetAutoHilight( Standard_True ); bath->GetShape()->TextLabels( false ); ctx->Deactivate( bath ); ctx->SetSelectionModeActive (bath, 2, Standard_True, AIS_SelectionModesConcurrency_Multiple, Standard_False); } - //ctx->CloseLocalContext( -1, Standard_True ); } myIsActive = isActive;