cocoaTouch/OverlayViewController.m
changeset 3357 3836a31879e7
parent 3356 3ae3fccb439e
child 3364 e5403e2bf02c
--- a/cocoaTouch/OverlayViewController.m	Sun Apr 18 23:19:15 2010 +0000
+++ b/cocoaTouch/OverlayViewController.m	Mon Apr 19 01:39:55 2010 +0000
@@ -67,21 +67,28 @@
     
     // add timer too runloop, otherwise it doesn't work
     [[NSRunLoop currentRunLoop] addTimer:dimTimer forMode:NSDefaultRunLoopMode];
-    // listen for dismissal of the popover (see below)x
-    [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(dismissPopover) name:@"dismissPopover" object:nil];
+    
+    // listen for dismissal of the popover (see below)
+    [[NSNotificationCenter defaultCenter] addObserver:self
+                                             selector:@selector(dismissPopover)
+                                                 name:@"dismissPopover"
+                                               object:nil];
     // present the overlay after 2 seconds
-    [NSTimer scheduledTimerWithTimeInterval:2 target:self selector:@selector(showMenuAfterwards) userInfo:nil repeats:NO];
+    [NSTimer scheduledTimerWithTimeInterval:2
+                                     target:self
+                                   selector:@selector(showMenuAfterwards)
+                                   userInfo:nil
+                                    repeats:NO];
 }
 
 -(void) viewDidUnload {
-	[dimTimer invalidate];
-	self.dimTimer = nil;
     self.popoverController = nil;
     self.popupMenu = nil;
     [super viewDidUnload];
 }
 
 -(void) dealloc {
+	[dimTimer invalidate];
     [popupMenu release];
     [popoverController release];
     // dimTimer is autoreleased