From 2b72c4df83f5765cbb1d5e6c17cb1fe93dd83c6e Mon Sep 17 00:00:00 2001 From: asl Date: Wed, 11 Oct 2017 08:35:25 +0300 Subject: [PATCH] correction of the compilation after merge --- src/HYDROGUI/HYDROGUI_ShapeBathymetry.cxx | 8 ++++---- src/HYDRO_tests/test_HYDROGUI_BathymetryPrs.cxx | 17 +++++++++-------- 2 files changed, 13 insertions(+), 12 deletions(-) diff --git a/src/HYDROGUI/HYDROGUI_ShapeBathymetry.cxx b/src/HYDROGUI/HYDROGUI_ShapeBathymetry.cxx index 35e8362a..c88b8638 100644 --- a/src/HYDROGUI/HYDROGUI_ShapeBathymetry.cxx +++ b/src/HYDROGUI/HYDROGUI_ShapeBathymetry.cxx @@ -108,7 +108,7 @@ void HYDROGUI_ShapeBathymetry::UpdateWithColorScale( const Handle(AIS_ColorScale theColorScale->FindColor( z, aColor ); myColors->SetValue( i, aColor ); } - Handle(HYDROGUI_BathymetryPrs) aPntCloud = Handle(HYDROGUI_BathymetryPrs)::DownCast( getAISObject()[0] ); + Handle(HYDROGUI_BathymetryPrs) aPntCloud = Handle(HYDROGUI_BathymetryPrs)::DownCast( getAISObjects()[0] ); aPntCloud->SetPoints( myCoords, myColors ); getContext()->RecomputePrsOnly( aPntCloud, Standard_True ); getContext()->RecomputeSelectionOnly( aPntCloud ); @@ -233,7 +233,7 @@ void HYDROGUI_ShapeBathymetry::Rescale( double theMin, double theMax ) myMin = qMin( theMin, theMax ); myMax = qMax( theMin, theMax ); setToUpdateColorScale( true ); - getAISObject()->Redisplay(); + getAISObjects()[0]->Redisplay(); } void HYDROGUI_ShapeBathymetry::RescaleDefault() @@ -270,7 +270,7 @@ void HYDROGUI_ShapeBathymetry::Build() void HYDROGUI_ShapeBathymetry::TextLabels( bool isOn ) { - Handle(HYDROGUI_BathymetryPrs) prs = Handle(HYDROGUI_BathymetryPrs)::DownCast( getAISObject() ); + Handle(HYDROGUI_BathymetryPrs) prs = Handle(HYDROGUI_BathymetryPrs)::DownCast( getAISObjects()[0] ); if( prs.IsNull() ) return; @@ -280,5 +280,5 @@ void HYDROGUI_ShapeBathymetry::TextLabels( bool isOn ) getContext()->ClearSelected(); prs->SetTextLabels( selection ); - getAISObject()->Redisplay(); + getAISObjects()[0]->Redisplay(); } diff --git a/src/HYDRO_tests/test_HYDROGUI_BathymetryPrs.cxx b/src/HYDRO_tests/test_HYDROGUI_BathymetryPrs.cxx index 9523ab4c..f2c32cbd 100644 --- a/src/HYDRO_tests/test_HYDROGUI_BathymetryPrs.cxx +++ b/src/HYDRO_tests/test_HYDROGUI_BathymetryPrs.cxx @@ -21,6 +21,7 @@ #include #include #include +#include #include #include @@ -42,7 +43,7 @@ void test_HYDROGUI_BathymetryPrs::createBathPrs() { myBathPrs = new HYDROGUI_ShapeBathymetry( 0, TestViewer::context(), myBath ); myBathPrs->Build(); - myBathPrs->getAISObject()->SetAutoHilight( Standard_False ); + myBathPrs->getAISObjects()[0]->SetAutoHilight( Standard_False ); double min, max; myBathPrs->GetRange( min, max ); @@ -71,7 +72,7 @@ void test_HYDROGUI_BathymetryPrs::test_presentation() createBathPrs(); updateColors(); - Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObject(); + Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObjects()[0]; CPPUNIT_ASSERT( !bprs.IsNull() ); TestViewer::show( bprs, 0, 0, true, "bathy_prs" ); @@ -103,7 +104,7 @@ void test_HYDROGUI_BathymetryPrs::test_selection() createBathPrs(); updateColors(); - Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObject(); + Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObjects()[0]; CPPUNIT_ASSERT( !bprs.IsNull() ); TestViewer::show( bprs, 0, 1, true, "bathy_prs" ); @@ -134,7 +135,7 @@ void test_HYDROGUI_BathymetryPrs::test_rescale_by_selection() createBathPrs(); updateColors(); - Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObject(); + Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObjects()[0]; CPPUNIT_ASSERT( !bprs.IsNull() ); TestViewer::show( bprs, 0, 1, true, "bathy_prs" ); @@ -193,7 +194,7 @@ void test_HYDROGUI_BathymetryPrs::test_rescale_by_visible() createBathPrs(); updateColors(); - Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObject(); + Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObjects()[0]; CPPUNIT_ASSERT( !bprs.IsNull() ); TestViewer::show( bprs, 0, 1, true, "bathy_prs" ); @@ -240,7 +241,7 @@ void test_HYDROGUI_BathymetryPrs::test_text_presentation() createBathPrs(); updateColors(); - Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObject(); + Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObjects()[0]; CPPUNIT_ASSERT( !bprs.IsNull() ); TestViewer::show( bprs, 0, 1, true, "bathy_prs" ); @@ -291,7 +292,7 @@ void test_HYDROGUI_BathymetryPrs::test_rescale_default() createBathPrs(); updateColors(); - Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObject(); + Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObjects()[0]; CPPUNIT_ASSERT( !bprs.IsNull() ); TestViewer::show( bprs, 0, 1, true, "bathy_prs" ); @@ -348,7 +349,7 @@ void test_HYDROGUI_BathymetryPrs::test_fit_on_selected() createBathPrs(); updateColors(); - Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObject(); + Handle(AIS_InteractiveObject) bprs = myBathPrs->getAISObjects()[0]; CPPUNIT_ASSERT( !bprs.IsNull() ); TestViewer::show( bprs, 0, 1, true, "bathy_prs" ); -- 2.39.2