Make sure popup button cells wont get notifications after being dealloceated.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@21266 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
FredKiefer 2005-05-27 13:41:46 +00:00
parent e8a572e64b
commit 2e231a94c7
2 changed files with 12 additions and 0 deletions

View file

@ -85,6 +85,12 @@ static NSImage *_pbc_image[2];
- (void) dealloc
{
/*
* The popup must be closed here, just in case the cell goes away
* while the popup is still displayed. In that case the notification
* center would still send notifications to the deallocated cell.
*/
[self dismissPopUp];
/*
* We don't use methods here to clean up the selected item, the menu
* item and the menu as these methods internally update the menu,