-(void)viewWillDisappeaar:(BOOL)animated- (void)viewDidDisappear:(BOOL)animated
{
[self.contentPlayer pause];
if (self.adsManager) {
[self.adsManager destroy];
self.adsManager = nil;
}
self.contentPlayer = nil;
[super viewDidDisappear:animated];
}
- (void)dealloc
{
NSLog(@"VideoViewController Dealloc");
}
I know that i need to destroy the adsManager and call contentComplete to make a new Request.
My Problem is that it doesn't work, when i call this in the viewDidDisappear Callback, which is the only place i can, as described before.
I implemented a workaround where i create a new adsLoader everytime i leave a VideoView, but i still think that it is a bug on your side.
Regarding the Memory leak.
My code Snipped doesn't make a call to dealloc it only also prints something to console when the object gets deallocated.
Its a handy thing if you have a hunch wich class won't get deallocated.
You can find a trace of the allocations here: https://dl.dropboxusercontent.com/u/16539706/IMAAdvancedExampleRun.trace.zip