Delete widgets without parents in CDockAreaLayout. (#241)

This commit is contained in:
shelomentsev 2020-08-20 15:56:37 +05:00 committed by GitHub
parent c44d0c87e3
commit 8361f90dce
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -86,6 +86,18 @@ public:
}
/**
* Delete widgets without parents in this layout
*/
~CDockAreaLayout()
{
for(auto Widget : m_Widgets)
{
if(!Widget->parent())
delete Widget;
}
}
/**
* Returns the number of widgets in this layout
*/