|
Assignment #3 :: SQLite Stopwatch + History
This app has two tabs, one for a stopwatch, the other is a history of all the times that you've saved into the phone.
- Stopwatch utilizes some timer events
- Used customized graphics for buttons
- Has an icon
- Customized tab icons
- NSMutable Array
- Tabs
- UILabel
- UIButton
- sqlite3
- NSDate
- NSTimer
- Thanks to Kyungsoo Im's example code
- Thanks to Adalgiso for the icon tip
To create a timer which repeats constantly at a 0.13 second interval:
NSTimer *timer = [[NSTimer scheduledTimerWithTimeInterval:0.13 target:self selector:@selector(testTimer:) userInfo:nil repeats:YES] retain];
To kill a timer:
To set up times and get the interval since the time:
//Initialize the time
NSDate *refTime = [[NSDate date] retain];
// Get the time since refTime was declared
double t = [[NSDate date] timeIntervalSinceDate:refTime];
|