Last active
March 31, 2016 19:46
-
-
Save burnsra/7f5d03889aa0896bb1162e8b8d5c989a to your computer and use it in GitHub Desktop.
Non-blocking NSTimer
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var timer: NSTimer? | |
timer = NSTimer.scheduledTimerWithTimeInterval(5.0, target: self, selector: #selector(self.test(_:)), userInfo: nil, repeats: true) | |
NSRunLoop.mainRunLoop().addTimer(timer!, forMode: NSRunLoopCommonModes) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment