-void wxAppBase::DeletePendingObjects()
-{
- wxList::compatibility_iterator node = wxPendingDelete.GetFirst();
- while (node)
- {
- wxObject *obj = node->GetData();
-
- // remove it from the list first so that if we get back here somehow
- // during the object deletion (e.g. wxYield called from its dtor) we
- // wouldn't try to delete it the second time
- if ( wxPendingDelete.Member(obj) )
- wxPendingDelete.Erase(node);
-
- delete obj;
-
- // Deleting one object may have deleted other pending
- // objects, so start from beginning of list again.
- node = wxPendingDelete.GetFirst();
- }
-}
-