# HG changeset patch # User lbajardsilogic # Date 1179315270 0 # Node ID 8e5f9a9aa43f1ed3e23c672e60f2fc61ec1a596a # Parent 51b1cbf1a7d71af667bec25eca6a8d47be972686 add destructor (clean PropertyBox vector) diff -r 51b1cbf1a7d7 -r 8e5f9a9aa43f widgets/PropertyStack.cpp --- a/widgets/PropertyStack.cpp Wed May 16 11:32:57 2007 +0000 +++ b/widgets/PropertyStack.cpp Wed May 16 11:34:30 2007 +0000 @@ -71,6 +71,23 @@ m_client, SLOT(propertyContainerSelected(View *, PropertyContainer *))); } +PropertyStack::~PropertyStack() +{ + blockSignals(true); + + while (count() > 0) + { + removeTab(0); + } + + for (size_t i = 0; i < m_boxes.size(); ++i) + { + delete m_boxes[i]; + } + m_boxes.clear(); + m_client = 0; +} + void PropertyStack::repopulate() { diff -r 51b1cbf1a7d7 -r 8e5f9a9aa43f widgets/PropertyStack.h --- a/widgets/PropertyStack.h Wed May 16 11:32:57 2007 +0000 +++ b/widgets/PropertyStack.h Wed May 16 11:34:30 2007 +0000 @@ -31,6 +31,7 @@ public: PropertyStack(QWidget *parent, View *client); + virtual ~PropertyStack(); View *getClient() { return m_client; } bool containsContainer(PropertyContainer *container) const;