summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2004-01-12 16:07:13 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2004-01-12 16:07:13 (GMT)
commit002679fdba0e1ea19aca7e7a4303da25ab34df7c (patch)
treef959dad5ec42383acfd4b0e692adf64121f04be6
parent1b2e663dfb940a28eecde01784913c9006d0e2b3 (diff)
downloadCMake-002679fdba0e1ea19aca7e7a4303da25ab34df7c.zip
CMake-002679fdba0e1ea19aca7e7a4303da25ab34df7c.tar.gz
CMake-002679fdba0e1ea19aca7e7a4303da25ab34df7c.tar.bz2
BUG: make sure property list is cleared between cache loadings
-rw-r--r--Source/MFCDialog/PropertyList.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/Source/MFCDialog/PropertyList.cpp b/Source/MFCDialog/PropertyList.cpp
index 01ab486..2534841 100644
--- a/Source/MFCDialog/PropertyList.cpp
+++ b/Source/MFCDialog/PropertyList.cpp
@@ -185,6 +185,7 @@ void CPropertyList::AddProperty(const char* name,
pItem->m_HelpString = helpString;
InvalidateList();
}
+ pItem->m_Advanced = advanced;
return;
}
}
@@ -718,10 +719,14 @@ void CPropertyList::RemoveAll()
for(int i =0; i < c; ++i)
{
CPropertyItem* pItem = (CPropertyItem*) GetItemDataPtr(0);
- m_PropertyItems.erase(pItem);
- delete pItem;
this->DeleteString(0);
}
+ for(std::set<CPropertyItem*>::iterator ii = m_PropertyItems.begin();
+ ii != m_PropertyItems.end(); ++ii)
+ {
+ delete *ii;
+ }
+ m_PropertyItems.clear();
m_Dirty = false;
this->HideControls();
InvalidateList();