[QNSView viewWillMoveToWindow:] remove observer from previous window
Even if there is not a new window, the notifications from the old one are not needed. Change-Id: I9c1858d25e49379ca4737e23beec06623e91b69c Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
This commit is contained in:
parent
5b70efb125
commit
f37990712b
@ -204,9 +204,9 @@ static QTouchDevice *touchDevice = 0;
|
||||
selector:@selector(windowNotification:)
|
||||
name:nil // Get all notifications
|
||||
object:newWindow];
|
||||
} else {
|
||||
[[NSNotificationCenter defaultCenter] removeObserver:self name:nil object:[self window]];
|
||||
}
|
||||
if ([self window])
|
||||
[[NSNotificationCenter defaultCenter] removeObserver:self name:nil object:[self window]];
|
||||
}
|
||||
- (void)updateGeometry
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user