mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-14 13:30:48 +03:00
0027318: Memory is not released in Select3D_SensitiveSet when destroying AIS_InteractiveContext without removing objects
- destructor was added to SelectMgr_SelectableObject to clean up selections; - test case for issue #27318 Warnings elimination
This commit is contained in:
@@ -69,6 +69,17 @@ SelectMgr_SelectableObject::SelectMgr_SelectableObject (const PrsMgr_TypeOfPrese
|
||||
myHilightDrawer->Link (myDrawer);
|
||||
}
|
||||
|
||||
//==================================================
|
||||
// Function: Destructor
|
||||
// Purpose : Clears all selections of the object
|
||||
//==================================================
|
||||
SelectMgr_SelectableObject::~SelectMgr_SelectableObject()
|
||||
{
|
||||
for (Standard_Integer aSelIdx = 1; aSelIdx <= myselections.Length(); ++aSelIdx)
|
||||
{
|
||||
myselections.Value (aSelIdx)->Clear();
|
||||
}
|
||||
}
|
||||
|
||||
//==================================================
|
||||
// Function: HasSelection
|
||||
|
@@ -56,6 +56,8 @@ class SelectMgr_SelectableObject : public PrsMgr_PresentableObject
|
||||
|
||||
public:
|
||||
|
||||
//! Clears all selections of the object
|
||||
Standard_EXPORT virtual ~SelectMgr_SelectableObject();
|
||||
|
||||
//! Recovers and calculates any sensitive primitive,
|
||||
//! aSelection, available in Shape mode, specified by
|
||||
|
Reference in New Issue
Block a user