diff --git a/Presentation/WILDCardViewController.m b/Presentation/WILDCardViewController.m index e9d32f7b..d03fd4d2 100644 --- a/Presentation/WILDCardViewController.m +++ b/Presentation/WILDCardViewController.m @@ -94,7 +94,9 @@ -(void) dealloc DESTROY_DEALLOC(mAddColorOverlay); DESTROY_DEALLOC(mSearchContext); DESTROY_DEALLOC(mCurrentSearchString); + [mBackgroundPictureView setDelegate: nil]; DESTROY_DEALLOC(mBackgroundPictureView); + [mCardPictureView setDelegate: nil]; DESTROY_DEALLOC(mCardPictureView); [super dealloc]; @@ -458,6 +460,7 @@ -(void) loadCard: (WILDCard*)theCard WILDStack* theStack = [theCard stack]; WILDBackground* theBg = [theCard owningBackground]; + [mBackgroundPictureView setDelegate: nil]; DESTROY(mBackgroundPictureView); mBackgroundPictureView = [[WILDPictureView alloc] initWithFrame: [[self view] bounds]]; NSImage* bgPicture = [theBg picture]; @@ -482,6 +485,7 @@ -(void) loadCard: (WILDCard*)theCard // Load the actual card parts: if( !mBackgroundEditMode ) { + [mCardPictureView setDelegate: nil]; DESTROY(mCardPictureView); mCardPictureView = [[WILDPictureView alloc] initWithFrame: [[self view] bounds]]; NSImage* cdPicture = [theCard picture];