From 7c301f22bfa9dc05ef20ecbebdf7e14df0c726c1 Mon Sep 17 00:00:00 2001 From: mo khan Date: Wed, 12 Jun 2013 21:38:16 -0600 Subject: rename start timer to start random location timer --- .../mo.xcuserdatad/UserInterfaceState.xcuserstate | Bin 16635 -> 16612 bytes Wobble/ViewController.m | 6 +++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Wobble.xcodeproj/project.xcworkspace/xcuserdata/mo.xcuserdatad/UserInterfaceState.xcuserstate b/Wobble.xcodeproj/project.xcworkspace/xcuserdata/mo.xcuserdatad/UserInterfaceState.xcuserstate index 95b319f..3d5bfaf 100644 Binary files a/Wobble.xcodeproj/project.xcworkspace/xcuserdata/mo.xcuserdatad/UserInterfaceState.xcuserstate and b/Wobble.xcodeproj/project.xcworkspace/xcuserdata/mo.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/Wobble/ViewController.m b/Wobble/ViewController.m index 0b18b8e..d240307 100644 --- a/Wobble/ViewController.m +++ b/Wobble/ViewController.m @@ -12,7 +12,7 @@ { [super viewDidLoad]; [self.ball addGestureRecognizer:[[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(onTouch:)]]; - [self startTimer]; + [self startRandomLocationTimer]; } -(CGPoint)createRandomLocationFor:(CGPoint)currentLocation @@ -30,11 +30,11 @@ { self.ball.center = [self createRandomLocationFor:self.ball.center]; } completion:^(BOOL b) { - [self startTimer]; + [self startRandomLocationTimer]; }]; } -- (void)startTimer +- (void)startRandomLocationTimer { self.timer = [NSTimer scheduledTimerWithTimeInterval:5 target:self selector:@selector(moveBallToRandomLocation) userInfo:nil repeats:NO]; } -- cgit v1.2.3