mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-14 13:30:48 +03:00
0024023: Revamp the OCCT Handle -- downcast (automatic)
Automatic update by command "occt_upgrade . -downcast" C-style cast of Handle to that of derived type (now illegal) is replaced by call to DownCast() Const reference local variables of Handle type initialized by result of DownCast are replaced by normal variables.
This commit is contained in:
@@ -106,8 +106,7 @@ Standard_Real SelectMgr_SensitiveEntitySet::Center (const Standard_Integer theIn
|
||||
{
|
||||
const Handle(SelectBasics_SensitiveEntity)& aBasicEntity =
|
||||
GetSensitiveById (theIndex)->BaseSensitive();
|
||||
const Handle(Select3D_SensitiveEntity)& aSensitive =
|
||||
Handle(Select3D_SensitiveEntity)::DownCast (aBasicEntity);
|
||||
Handle(Select3D_SensitiveEntity) aSensitive (Handle(Select3D_SensitiveEntity)::DownCast (aBasicEntity));
|
||||
const gp_Pnt aCenter = aSensitive->CenterOfGeometry();
|
||||
Standard_Real aCenterCoord = 0.0;
|
||||
aCenterCoord = theAxis == 0 ? aCenter.X() :
|
||||
|
Reference in New Issue
Block a user