From 2ca0651c272b155f0782ce79a4a63d5f9d9f466d Mon Sep 17 00:00:00 2001 From: mzn Date: Mon, 22 Jun 2015 11:54:29 +0300 Subject: [PATCH] refs #567: let the land covers to be recognized as reference objects of a cc zone --- src/HYDROData/HYDROData_Region.cxx | 3 +-- src/HYDROGUI/HYDROGUI_Zone.cxx | 4 ++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/HYDROData/HYDROData_Region.cxx b/src/HYDROData/HYDROData_Region.cxx index 194d80e6..20a86e42 100644 --- a/src/HYDROData/HYDROData_Region.cxx +++ b/src/HYDROData/HYDROData_Region.cxx @@ -174,8 +174,7 @@ Handle(HYDROData_Zone) HYDROData_Region::addNewZone( const Handle(HYDROData_Docu for ( int i = 0, n = theRefObjects.length(); i < n; ++i ) { const QString& anObjName = theRefObjects.at( i ); - Handle(HYDROData_Object) aRefObject = - Handle(HYDROData_Object)::DownCast( theDoc->FindObjectByName( anObjName ) ); + Handle(HYDROData_Entity) aRefObject = theDoc->FindObjectByName( anObjName ); if ( aRefObject.IsNull() ) continue; diff --git a/src/HYDROGUI/HYDROGUI_Zone.cxx b/src/HYDROGUI/HYDROGUI_Zone.cxx index 8561008c..469695cf 100644 --- a/src/HYDROGUI/HYDROGUI_Zone.cxx +++ b/src/HYDROGUI/HYDROGUI_Zone.cxx @@ -66,8 +66,8 @@ QString HYDROGUI_Zone::getRefObjectNames() const HYDROData_SequenceOfObjects::Iterator anIter( aSeq ); for ( ; anIter.More(); anIter.Next() ) { - Handle(HYDROData_Object) aRefGeomObj = - Handle(HYDROData_Object)::DownCast( anIter.Value() ); + Handle(HYDROData_Entity) aRefGeomObj = + Handle(HYDROData_Entity)::DownCast( anIter.Value() ); if ( !aRefGeomObj.IsNull() ) { // Get Ref.Object name -- 2.39.2