├── SimpleTimer
├── SimpleTimer.xcodeproj
│ ├── project.xcworkspace
│ │ └── contents.xcworkspacedata
│ └── project.pbxproj
├── SimpleTimer
│ ├── SimpleTimer.entitlements
│ ├── Images.xcassets
│ │ ├── AppIcon.appiconset
│ │ │ └── Contents.json
│ │ └── LaunchImage.launchimage
│ │ │ └── Contents.json
│ ├── Info.plist
│ ├── AppDelegate.swift
│ ├── Timer.swift
│ ├── ViewController.swift
│ └── Base.lproj
│ │ └── Main.storyboard
├── SimpleTimerTodayExtenstion
│ ├── SimpleTimerTodayExtenstion.entitlements
│ ├── Info.plist
│ ├── TodayViewController.swift
│ └── MainInterface.storyboard
├── SimpleTimerKit
│ ├── SimpleTimerKit.h
│ └── Info.plist
├── SimpleTimerKitTests
│ ├── Info.plist
│ └── SimpleTimerKitTests.swift
└── SimpleTimerTests
│ ├── Info.plist
│ └── SimpleTimerTests.swift
└── .gitignore
/SimpleTimer/SimpleTimer.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimer/SimpleTimer.entitlements:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | com.apple.security.application-groups
6 |
7 | group.simpleTimerSharedDefaults
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimerTodayExtenstion/SimpleTimerTodayExtenstion.entitlements:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | com.apple.security.application-groups
6 |
7 | group.simpleTimerSharedDefaults
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimerKit/SimpleTimerKit.h:
--------------------------------------------------------------------------------
1 | //
2 | // SimpleTimerKit.h
3 | // SimpleTimerKit
4 | //
5 | // Created by 王 巍 on 14-8-2.
6 | // Copyright (c) 2014年 OneV's Den. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | //! Project version number for SimpleTimerKit.
12 | FOUNDATION_EXPORT double SimpleTimerKitVersionNumber;
13 |
14 | //! Project version string for SimpleTimerKit.
15 | FOUNDATION_EXPORT const unsigned char SimpleTimerKitVersionString[];
16 |
17 | // In this header, you should import all the public headers of your framework using statements like #import
18 |
19 |
20 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Created by http://www.gitignore.io
2 |
3 | ### Xcode ###
4 | build/
5 | *.pbxuser
6 | !default.pbxuser
7 | *.mode1v3
8 | !default.mode1v3
9 | *.mode2v3
10 | !default.mode2v3
11 | *.perspectivev3
12 | !default.perspectivev3
13 | xcuserdata
14 | *.xccheckout
15 | *.moved-aside
16 | DerivedData
17 | *.xcuserstate
18 |
19 |
20 | ### OSX ###
21 | .DS_Store
22 | .AppleDouble
23 | .LSOverride
24 |
25 | # Icon must end with two \r
26 | Icon
27 |
28 |
29 | # Thumbnails
30 | ._*
31 |
32 | # Files that might appear on external disk
33 | .Spotlight-V100
34 | .Trashes
35 |
36 | # Directories potentially created on remote AFP share
37 | .AppleDB
38 | .AppleDesktop
39 | Network Trash Folder
40 | Temporary Items
41 | .apdisk
42 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimerKitTests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | ${EXECUTABLE_NAME}
9 | CFBundleIdentifier
10 | com.onevcat.${PRODUCT_NAME:rfc1034identifier}
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | ${PRODUCT_NAME}
15 | CFBundlePackageType
16 | BNDL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 |
24 |
25 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimerTests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | ${EXECUTABLE_NAME}
9 | CFBundleIdentifier
10 | com.onevcat.${PRODUCT_NAME:rfc1034identifier}
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | ${PRODUCT_NAME}
15 | CFBundlePackageType
16 | BNDL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 |
24 |
25 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimerKit/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | ${EXECUTABLE_NAME}
9 | CFBundleIdentifier
10 | com.onevcat.${PRODUCT_NAME:rfc1034identifier}
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | ${PRODUCT_NAME}
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | ${CURRENT_PROJECT_VERSION}
23 | NSPrincipalClass
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimerTests/SimpleTimerTests.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SimpleTimerTests.swift
3 | // SimpleTimerTests
4 | //
5 | // Created by 王 巍 on 14-8-1.
6 | // Copyright (c) 2014年 OneV's Den. All rights reserved.
7 | //
8 |
9 | import UIKit
10 | import XCTest
11 |
12 | class SimpleTimerTests: XCTestCase {
13 |
14 | override func setUp() {
15 | super.setUp()
16 | // Put setup code here. This method is called before the invocation of each test method in the class.
17 | }
18 |
19 | override func tearDown() {
20 | // Put teardown code here. This method is called after the invocation of each test method in the class.
21 | super.tearDown()
22 | }
23 |
24 | func testExample() {
25 | // This is an example of a functional test case.
26 | XCTAssert(true, "Pass")
27 | }
28 |
29 | func testPerformanceExample() {
30 | // This is an example of a performance test case.
31 | self.measureBlock() {
32 | // Put the code you want to measure the time of here.
33 | }
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimerKitTests/SimpleTimerKitTests.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SimpleTimerKitTests.swift
3 | // SimpleTimerKitTests
4 | //
5 | // Created by 王 巍 on 14-8-2.
6 | // Copyright (c) 2014年 OneV's Den. All rights reserved.
7 | //
8 |
9 | import UIKit
10 | import XCTest
11 |
12 | class SimpleTimerKitTests: XCTestCase {
13 |
14 | override func setUp() {
15 | super.setUp()
16 | // Put setup code here. This method is called before the invocation of each test method in the class.
17 | }
18 |
19 | override func tearDown() {
20 | // Put teardown code here. This method is called after the invocation of each test method in the class.
21 | super.tearDown()
22 | }
23 |
24 | func testExample() {
25 | // This is an example of a functional test case.
26 | XCTAssert(true, "Pass")
27 | }
28 |
29 | func testPerformanceExample() {
30 | // This is an example of a performance test case.
31 | self.measureBlock() {
32 | // Put the code you want to measure the time of here.
33 | }
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimer/Images.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "iphone",
5 | "size" : "29x29",
6 | "scale" : "2x"
7 | },
8 | {
9 | "idiom" : "iphone",
10 | "size" : "40x40",
11 | "scale" : "2x"
12 | },
13 | {
14 | "idiom" : "iphone",
15 | "size" : "60x60",
16 | "scale" : "2x"
17 | },
18 | {
19 | "idiom" : "ipad",
20 | "size" : "29x29",
21 | "scale" : "1x"
22 | },
23 | {
24 | "idiom" : "ipad",
25 | "size" : "29x29",
26 | "scale" : "2x"
27 | },
28 | {
29 | "idiom" : "ipad",
30 | "size" : "40x40",
31 | "scale" : "1x"
32 | },
33 | {
34 | "idiom" : "ipad",
35 | "size" : "40x40",
36 | "scale" : "2x"
37 | },
38 | {
39 | "idiom" : "ipad",
40 | "size" : "76x76",
41 | "scale" : "1x"
42 | },
43 | {
44 | "idiom" : "ipad",
45 | "size" : "76x76",
46 | "scale" : "2x"
47 | }
48 | ],
49 | "info" : {
50 | "version" : 1,
51 | "author" : "xcode"
52 | }
53 | }
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimerTodayExtenstion/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleDisplayName
8 | SimpleTimerTodayExtenstion
9 | CFBundleExecutable
10 | ${EXECUTABLE_NAME}
11 | CFBundleIdentifier
12 | com.onevcat.SimpleTimer.${PRODUCT_NAME:rfc1034identifier}
13 | CFBundleInfoDictionaryVersion
14 | 6.0
15 | CFBundleName
16 | ${PRODUCT_NAME}
17 | CFBundlePackageType
18 | XPC!
19 | CFBundleShortVersionString
20 | 1.0
21 | CFBundleSignature
22 | ????
23 | CFBundleVersion
24 | 1
25 | NSExtension
26 |
27 | NSExtensionMainStoryboard
28 | MainInterface
29 | NSExtensionPointIdentifier
30 | com.apple.widget-extension
31 |
32 |
33 |
34 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimer/Images.xcassets/LaunchImage.launchimage/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "orientation" : "portrait",
5 | "idiom" : "iphone",
6 | "extent" : "full-screen",
7 | "minimum-system-version" : "7.0",
8 | "scale" : "2x"
9 | },
10 | {
11 | "orientation" : "portrait",
12 | "idiom" : "iphone",
13 | "subtype" : "retina4",
14 | "extent" : "full-screen",
15 | "minimum-system-version" : "7.0",
16 | "scale" : "2x"
17 | },
18 | {
19 | "orientation" : "portrait",
20 | "idiom" : "ipad",
21 | "extent" : "full-screen",
22 | "minimum-system-version" : "7.0",
23 | "scale" : "1x"
24 | },
25 | {
26 | "orientation" : "landscape",
27 | "idiom" : "ipad",
28 | "extent" : "full-screen",
29 | "minimum-system-version" : "7.0",
30 | "scale" : "1x"
31 | },
32 | {
33 | "orientation" : "portrait",
34 | "idiom" : "ipad",
35 | "extent" : "full-screen",
36 | "minimum-system-version" : "7.0",
37 | "scale" : "2x"
38 | },
39 | {
40 | "orientation" : "landscape",
41 | "idiom" : "ipad",
42 | "extent" : "full-screen",
43 | "minimum-system-version" : "7.0",
44 | "scale" : "2x"
45 | }
46 | ],
47 | "info" : {
48 | "version" : 1,
49 | "author" : "xcode"
50 | }
51 | }
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimer/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | ${EXECUTABLE_NAME}
9 | CFBundleIdentifier
10 | com.onevcat.${PRODUCT_NAME:rfc1034identifier}
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | ${PRODUCT_NAME}
15 | CFBundlePackageType
16 | APPL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleURLTypes
22 |
23 |
24 | CFBundleTypeRole
25 | Editor
26 | CFBundleURLName
27 | SimplerTimerFinishReport
28 | CFBundleURLSchemes
29 |
30 | simpleTimer
31 |
32 |
33 |
34 | CFBundleVersion
35 | 1
36 | LSRequiresIPhoneOS
37 |
38 | UIMainStoryboardFile
39 | Main
40 | UIRequiredDeviceCapabilities
41 |
42 | armv7
43 |
44 | UISupportedInterfaceOrientations
45 |
46 | UIInterfaceOrientationPortrait
47 | UIInterfaceOrientationLandscapeLeft
48 | UIInterfaceOrientationLandscapeRight
49 |
50 | UISupportedInterfaceOrientations~ipad
51 |
52 | UIInterfaceOrientationPortrait
53 | UIInterfaceOrientationPortraitUpsideDown
54 | UIInterfaceOrientationLandscapeLeft
55 | UIInterfaceOrientationLandscapeRight
56 |
57 |
58 |
59 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimer/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.swift
3 | // SimpleTimer
4 | //
5 | // Created by 王 巍 on 14-8-1.
6 | // Copyright (c) 2014年 OneV's Den. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | @UIApplicationMain
12 | class AppDelegate: UIResponder, UIApplicationDelegate {
13 |
14 | var window: UIWindow?
15 |
16 |
17 | func application(application: UIApplication!, didFinishLaunchingWithOptions launchOptions: NSDictionary!) -> Bool {
18 | // Override point for customization after application launch.
19 | return true
20 | }
21 |
22 | func applicationWillResignActive(application: UIApplication!) {
23 | // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
24 | // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
25 | }
26 |
27 | func applicationDidEnterBackground(application: UIApplication!) {
28 | // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
29 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
30 | }
31 |
32 | func applicationWillEnterForeground(application: UIApplication!) {
33 | // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
34 | }
35 |
36 | func applicationDidBecomeActive(application: UIApplication!) {
37 | // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
38 | }
39 |
40 | func applicationWillTerminate(application: UIApplication!) {
41 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
42 | }
43 |
44 | func application(application: UIApplication!, openURL url: NSURL!, sourceApplication: String!, annotation: AnyObject!) -> Bool {
45 | if url.scheme == "simpleTimer" {
46 | if url.host == "finished" {
47 | NSNotificationCenter.defaultCenter()
48 | .postNotificationName(taskDidFinishedInWidgetNotification, object: nil)
49 | }
50 | return true
51 | }
52 |
53 | return false
54 | }
55 | }
56 |
57 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimerTodayExtenstion/TodayViewController.swift:
--------------------------------------------------------------------------------
1 | //
2 | // TodayViewController.swift
3 | // SimpleTimerTodayExtenstion
4 | //
5 | // Created by 王 巍 on 14-8-2.
6 | // Copyright (c) 2014年 OneV's Den. All rights reserved.
7 | //
8 |
9 | import UIKit
10 | import NotificationCenter
11 | import SimpleTimerKit
12 |
13 | class TodayViewController: UIViewController, NCWidgetProviding {
14 |
15 | @IBOutlet weak var lblTimer: UILabel!
16 |
17 | var timer: Timer!
18 |
19 | override func viewDidLoad() {
20 | super.viewDidLoad()
21 | // Do any additional setup after loading the view from its nib.
22 |
23 | if let userDefaults = NSUserDefaults(suiteName: "group.simpleTimerSharedDefaults") {
24 | let leftTimeWhenQuit = userDefaults.integerForKey(keyLeftTime)
25 | let quitDate = userDefaults.integerForKey(keyQuitDate)
26 |
27 | let passedTimeFromQuit = NSDate().timeIntervalSinceDate(NSDate(timeIntervalSince1970: NSTimeInterval(quitDate)))
28 |
29 | let leftTime = leftTimeWhenQuit - Int(passedTimeFromQuit)
30 |
31 | if (leftTime > 0) {
32 | timer = Timer(timeInteral: NSTimeInterval(leftTime))
33 | timer.start(updateTick: {
34 | [weak self] leftTick in self!.updateLabel()
35 | }, stopHandler: {
36 | [weak self] finished in self!.showOpenAppButton()
37 | })
38 | } else {
39 | showOpenAppButton()
40 | }
41 | }
42 | }
43 |
44 | private func updateLabel() {
45 | lblTimer.text = timer.leftTimeString
46 | }
47 |
48 | private func showOpenAppButton() {
49 | lblTimer.text = "Finished"
50 | preferredContentSize = CGSizeMake(0, 100)
51 |
52 | let button = UIButton(frame: CGRectMake(0, 50, 50, 63))
53 | button.setTitle("Open", forState: UIControlState.Normal)
54 | button.addTarget(self, action: "buttonPressed:", forControlEvents: UIControlEvents.TouchUpInside)
55 |
56 | view.addSubview(button)
57 |
58 | }
59 |
60 | dynamic private func buttonPressed(sender: AnyObject!) {
61 | extensionContext?.openURL(NSURL(string: "simpleTimer://finished")!, completionHandler: nil)
62 | }
63 |
64 | override func didReceiveMemoryWarning() {
65 | super.didReceiveMemoryWarning()
66 | // Dispose of any resources that can be recreated.
67 | }
68 |
69 | func widgetPerformUpdateWithCompletionHandler(completionHandler: ((NCUpdateResult) -> Void)!) {
70 | // Perform any setup necessary in order to update the view.
71 |
72 | // If an error is encoutered, use NCUpdateResult.Failed
73 | // If there's no update required, use NCUpdateResult.NoData
74 | // If there's an update, use NCUpdateResult.NewData
75 |
76 | completionHandler(NCUpdateResult.NewData)
77 | }
78 |
79 | }
80 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimer/Timer.swift:
--------------------------------------------------------------------------------
1 | //
2 | // Timer.swift
3 | // SimpleTimer
4 | //
5 | // Created by 王 巍 on 14-8-1.
6 | // Copyright (c) 2014年 OneV's Den. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | public let keyLeftTime = "com.onevcat.simpleTimer.lefttime"
12 | public let keyQuitDate = "com.onevcat.simpleTimer.quitdate"
13 |
14 | let timerErrorDomain = "SimpleTimerError"
15 |
16 | public enum SimperTimerError: Int {
17 | case AlreadyRunning = 1001
18 | case NegativeLeftTime = 1002
19 | case NotRunning = 1003
20 | }
21 |
22 | extension NSTimeInterval {
23 | func toString() -> String {
24 | let totalSecond = Int(self)
25 | let minute = totalSecond / 60
26 | let second = totalSecond % 60
27 |
28 | switch (minute, second) {
29 | case (0...9, 0...9):
30 | return "0\(minute):0\(second)"
31 | case (0...9, _):
32 | return "0\(minute):\(second)"
33 | case (_, 0...9):
34 | return "\(minute):0\(second)"
35 | default:
36 | return "\(minute):\(second)"
37 | }
38 | }
39 | }
40 |
41 | public class Timer: NSObject {
42 |
43 | public var running: Bool = false
44 |
45 | public var leftTime: NSTimeInterval {
46 | didSet {
47 | if leftTime < 0 {
48 | leftTime = 0
49 | }
50 | }
51 | }
52 |
53 | public var leftTimeString: String {
54 | get {
55 | return leftTime.toString()
56 | }
57 | }
58 |
59 | private var timerTickHandler: (NSTimeInterval -> ())? = nil
60 | private var timerStopHandler: (Bool ->())? = nil
61 | private var timer: NSTimer!
62 |
63 | public init(timeInteral: NSTimeInterval) {
64 | leftTime = timeInteral
65 | }
66 |
67 | public func start(#updateTick: (NSTimeInterval -> Void)?, stopHandler: (Bool -> Void)?) -> (start: Bool, error: NSError?) {
68 | if running {
69 | return (false, NSError(domain: timerErrorDomain, code: SimperTimerError.AlreadyRunning.rawValue, userInfo:nil))
70 | }
71 |
72 | if leftTime < 0 {
73 | return (false, NSError(domain: timerErrorDomain, code: SimperTimerError.NegativeLeftTime.rawValue, userInfo:nil))
74 | }
75 |
76 | timerTickHandler = updateTick
77 | timerStopHandler = stopHandler
78 |
79 | running = true
80 |
81 | timer = NSTimer.scheduledTimerWithTimeInterval(1, target: self, selector:"countTick", userInfo: nil, repeats: true)
82 |
83 | return (true, nil)
84 | }
85 |
86 | public func stop(interrupt: Bool) -> (stopped: Bool, error: NSError?) {
87 | if !running {
88 | return (false, NSError(domain: timerErrorDomain, code: SimperTimerError.NotRunning.rawValue, userInfo:nil))
89 | }
90 |
91 | running = false
92 | timer.invalidate()
93 | timer = nil
94 |
95 | if let stopHandler = timerStopHandler {
96 | stopHandler(!interrupt)
97 | }
98 |
99 | timerStopHandler = nil
100 | timerTickHandler = nil
101 |
102 | return (true, nil)
103 | }
104 |
105 | dynamic private func countTick() {
106 | leftTime = leftTime - 1
107 | if let tickHandler = timerTickHandler {
108 | tickHandler(leftTime)
109 | }
110 | if leftTime <= 0 {
111 | stop(false)
112 | }
113 |
114 | }
115 | }
116 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimerTodayExtenstion/MainInterface.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimer/ViewController.swift:
--------------------------------------------------------------------------------
1 | //
2 | // ViewController.swift
3 | // SimpleTimer
4 | //
5 | // Created by 王 巍 on 14-8-1.
6 | // Copyright (c) 2014年 OneV's Den. All rights reserved.
7 | //
8 |
9 | import UIKit
10 | import SimpleTimerKit
11 |
12 | let defaultTimeInterval: NSTimeInterval = 10
13 | let taskDidFinishedInWidgetNotification: String = "com.onevcat.simpleTimer.TaskDidFinishedInWidgetNotification"
14 |
15 | class ViewController: UIViewController {
16 |
17 | @IBOutlet weak var lblTimer: UILabel!
18 |
19 | var timer: Timer!
20 |
21 | override func viewDidLoad() {
22 | super.viewDidLoad()
23 | // Do any additional setup after loading the view, typically from a nib.
24 | NSNotificationCenter.defaultCenter()
25 | .addObserver(self, selector: "applicationWillResignActive",name: UIApplicationWillResignActiveNotification, object: nil)
26 | NSNotificationCenter.defaultCenter()
27 | .addObserver(self, selector: "taskFinishedInWidget", name: taskDidFinishedInWidgetNotification, object: nil)
28 | }
29 |
30 | override func didReceiveMemoryWarning() {
31 | super.didReceiveMemoryWarning()
32 | // Dispose of any resources that can be recreated.
33 | }
34 |
35 | private func updateLabel() {
36 | lblTimer.text = timer.leftTimeString
37 | }
38 |
39 | private func showFinishAlert(# finished: Bool) {
40 | let ac = UIAlertController(title: nil , message: finished ? "Finished" : "Stopped", preferredStyle: .Alert)
41 | ac.addAction(UIAlertAction(title: "OK", style: .Default, handler: {[weak ac] action in ac!.dismissViewControllerAnimated(true, completion: nil)}))
42 |
43 | presentViewController(ac, animated: true, completion: nil)
44 | }
45 |
46 | dynamic private func applicationWillResignActive() {
47 | if timer == nil {
48 | clearDefaults()
49 | } else {
50 | if timer.running {
51 | saveDefaults()
52 | } else {
53 | clearDefaults()
54 | }
55 | }
56 | }
57 |
58 | dynamic private func taskFinishedInWidget() {
59 | if let realTimer = timer {
60 | let (stopped, error) = realTimer.stop(false)
61 | if !stopped {
62 | if let realError = error {
63 | println("error: \(realError.code)")
64 | }
65 | }
66 | }
67 | }
68 |
69 | private func saveDefaults() {
70 | if let userDefault = NSUserDefaults(suiteName: "group.simpleTimerSharedDefaults") {
71 | userDefault.setInteger(Int(timer.leftTime), forKey: keyLeftTime)
72 | userDefault.setInteger(Int(NSDate().timeIntervalSince1970), forKey: keyQuitDate)
73 |
74 | userDefault.synchronize()
75 | }
76 | }
77 |
78 | private func clearDefaults() {
79 | if let userDefault = NSUserDefaults(suiteName: "group.simpleTimerSharedDefaults") {
80 | userDefault.removeObjectForKey(keyLeftTime)
81 | userDefault.removeObjectForKey(keyQuitDate)
82 |
83 | userDefault.synchronize()
84 | }
85 | }
86 |
87 | @IBAction func btnStartPressed(sender: AnyObject) {
88 | if timer == nil {
89 | timer = Timer(timeInteral: defaultTimeInterval)
90 | }
91 |
92 | let (started, error) = timer.start(updateTick: {
93 | [weak self] leftTick in self!.updateLabel()
94 | }, stopHandler: {
95 | [weak self] finished in
96 | self!.showFinishAlert(finished: finished)
97 | self!.timer = nil
98 | })
99 |
100 | if started {
101 | updateLabel()
102 | } else {
103 | if let realError = error {
104 | println("error: \(realError.code)")
105 | }
106 | }
107 | }
108 |
109 | @IBAction func btnStopPressed(sender: AnyObject) {
110 | if let realTimer = timer {
111 | let (stopped, error) = realTimer.stop(true)
112 | if !stopped {
113 | if let realError = error {
114 | println("error: \(realError.code)")
115 | }
116 | }
117 | }
118 | }
119 |
120 | }
121 |
122 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimer/Base.lproj/Main.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
34 |
44 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
--------------------------------------------------------------------------------
/SimpleTimer/SimpleTimer.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | D127E242198B34FC00A09E62 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = D127E241198B34FC00A09E62 /* AppDelegate.swift */; };
11 | D127E244198B34FC00A09E62 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = D127E243198B34FC00A09E62 /* ViewController.swift */; };
12 | D127E247198B34FC00A09E62 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = D127E245198B34FC00A09E62 /* Main.storyboard */; };
13 | D127E249198B34FC00A09E62 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = D127E248198B34FC00A09E62 /* Images.xcassets */; };
14 | D127E255198B34FC00A09E62 /* SimpleTimerTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D127E254198B34FC00A09E62 /* SimpleTimerTests.swift */; };
15 | D12A181F198CB2E0007CE843 /* NotificationCenter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D12A181E198CB2E0007CE843 /* NotificationCenter.framework */; };
16 | D12A1824198CB2E0007CE843 /* TodayViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = D12A1823198CB2E0007CE843 /* TodayViewController.swift */; };
17 | D12A1826198CB2E0007CE843 /* MainInterface.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = D12A1825198CB2E0007CE843 /* MainInterface.storyboard */; };
18 | D12A1829198CB2E0007CE843 /* SimpleTimerTodayExtenstion.appex in Embed App Extensions */ = {isa = PBXBuildFile; fileRef = D12A181C198CB2E0007CE843 /* SimpleTimerTodayExtenstion.appex */; };
19 | D12A183C198CB9EF007CE843 /* SimpleTimerKit.h in Headers */ = {isa = PBXBuildFile; fileRef = D12A183B198CB9EF007CE843 /* SimpleTimerKit.h */; settings = {ATTRIBUTES = (Public, ); }; };
20 | D12A1842198CB9EF007CE843 /* SimpleTimerKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D12A1837198CB9EF007CE843 /* SimpleTimerKit.framework */; };
21 | D12A1849198CB9EF007CE843 /* SimpleTimerKitTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = D12A1848198CB9EF007CE843 /* SimpleTimerKitTests.swift */; };
22 | D12A184C198CB9EF007CE843 /* SimpleTimerKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D12A1837198CB9EF007CE843 /* SimpleTimerKit.framework */; };
23 | D12A184D198CB9EF007CE843 /* SimpleTimerKit.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = D12A1837198CB9EF007CE843 /* SimpleTimerKit.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, ); }; };
24 | D12A185F198CBA3A007CE843 /* Timer.swift in Sources */ = {isa = PBXBuildFile; fileRef = D1B6B784198B5EC700DCF3A3 /* Timer.swift */; };
25 | D12A1860198CBBB5007CE843 /* SimpleTimerKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = D12A1837198CB9EF007CE843 /* SimpleTimerKit.framework */; };
26 | /* End PBXBuildFile section */
27 |
28 | /* Begin PBXContainerItemProxy section */
29 | D127E24F198B34FC00A09E62 /* PBXContainerItemProxy */ = {
30 | isa = PBXContainerItemProxy;
31 | containerPortal = D127E234198B34FC00A09E62 /* Project object */;
32 | proxyType = 1;
33 | remoteGlobalIDString = D127E23B198B34FC00A09E62;
34 | remoteInfo = SimpleTimer;
35 | };
36 | D12A1827198CB2E0007CE843 /* PBXContainerItemProxy */ = {
37 | isa = PBXContainerItemProxy;
38 | containerPortal = D127E234198B34FC00A09E62 /* Project object */;
39 | proxyType = 1;
40 | remoteGlobalIDString = D12A181B198CB2E0007CE843;
41 | remoteInfo = SimpleTimerTodayExtenstion;
42 | };
43 | D12A182A198CB2E0007CE843 /* PBXContainerItemProxy */ = {
44 | isa = PBXContainerItemProxy;
45 | containerPortal = D127E234198B34FC00A09E62 /* Project object */;
46 | proxyType = 1;
47 | remoteGlobalIDString = D12A181B198CB2E0007CE843;
48 | remoteInfo = SimpleTimerTodayExtenstion;
49 | };
50 | D12A1843198CB9EF007CE843 /* PBXContainerItemProxy */ = {
51 | isa = PBXContainerItemProxy;
52 | containerPortal = D127E234198B34FC00A09E62 /* Project object */;
53 | proxyType = 1;
54 | remoteGlobalIDString = D12A1836198CB9EF007CE843;
55 | remoteInfo = SimpleTimerKit;
56 | };
57 | D12A184A198CB9EF007CE843 /* PBXContainerItemProxy */ = {
58 | isa = PBXContainerItemProxy;
59 | containerPortal = D127E234198B34FC00A09E62 /* Project object */;
60 | proxyType = 1;
61 | remoteGlobalIDString = D12A1836198CB9EF007CE843;
62 | remoteInfo = SimpleTimerKit;
63 | };
64 | D12A184E198CB9F0007CE843 /* PBXContainerItemProxy */ = {
65 | isa = PBXContainerItemProxy;
66 | containerPortal = D127E234198B34FC00A09E62 /* Project object */;
67 | proxyType = 1;
68 | remoteGlobalIDString = D12A1836198CB9EF007CE843;
69 | remoteInfo = SimpleTimerKit;
70 | };
71 | D12A1857198CB9F1007CE843 /* PBXContainerItemProxy */ = {
72 | isa = PBXContainerItemProxy;
73 | containerPortal = D127E234198B34FC00A09E62 /* Project object */;
74 | proxyType = 1;
75 | remoteGlobalIDString = D12A1836198CB9EF007CE843;
76 | remoteInfo = SimpleTimerKit;
77 | };
78 | D12A1859198CB9F1007CE843 /* PBXContainerItemProxy */ = {
79 | isa = PBXContainerItemProxy;
80 | containerPortal = D127E234198B34FC00A09E62 /* Project object */;
81 | proxyType = 1;
82 | remoteGlobalIDString = D12A1836198CB9EF007CE843;
83 | remoteInfo = SimpleTimerKit;
84 | };
85 | D12A185B198CB9F1007CE843 /* PBXContainerItemProxy */ = {
86 | isa = PBXContainerItemProxy;
87 | containerPortal = D127E234198B34FC00A09E62 /* Project object */;
88 | proxyType = 1;
89 | remoteGlobalIDString = D12A1836198CB9EF007CE843;
90 | remoteInfo = SimpleTimerKit;
91 | };
92 | D12A185D198CB9F1007CE843 /* PBXContainerItemProxy */ = {
93 | isa = PBXContainerItemProxy;
94 | containerPortal = D127E234198B34FC00A09E62 /* Project object */;
95 | proxyType = 1;
96 | remoteGlobalIDString = D12A1836198CB9EF007CE843;
97 | remoteInfo = SimpleTimerKit;
98 | };
99 | /* End PBXContainerItemProxy section */
100 |
101 | /* Begin PBXCopyFilesBuildPhase section */
102 | D12A182F198CB2E0007CE843 /* Embed App Extensions */ = {
103 | isa = PBXCopyFilesBuildPhase;
104 | buildActionMask = 2147483647;
105 | dstPath = "";
106 | dstSubfolderSpec = 13;
107 | files = (
108 | D12A1829198CB2E0007CE843 /* SimpleTimerTodayExtenstion.appex in Embed App Extensions */,
109 | );
110 | name = "Embed App Extensions";
111 | runOnlyForDeploymentPostprocessing = 0;
112 | };
113 | D12A1853198CB9F0007CE843 /* Embed Frameworks */ = {
114 | isa = PBXCopyFilesBuildPhase;
115 | buildActionMask = 2147483647;
116 | dstPath = "";
117 | dstSubfolderSpec = 10;
118 | files = (
119 | D12A184D198CB9EF007CE843 /* SimpleTimerKit.framework in Embed Frameworks */,
120 | );
121 | name = "Embed Frameworks";
122 | runOnlyForDeploymentPostprocessing = 0;
123 | };
124 | /* End PBXCopyFilesBuildPhase section */
125 |
126 | /* Begin PBXFileReference section */
127 | D127E23C198B34FC00A09E62 /* SimpleTimer.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = SimpleTimer.app; sourceTree = BUILT_PRODUCTS_DIR; };
128 | D127E240198B34FC00A09E62 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
129 | D127E241198B34FC00A09E62 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; };
130 | D127E243198B34FC00A09E62 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; };
131 | D127E246198B34FC00A09E62 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; };
132 | D127E248198B34FC00A09E62 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = ""; };
133 | D127E24E198B34FC00A09E62 /* SimpleTimerTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = SimpleTimerTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
134 | D127E253198B34FC00A09E62 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
135 | D127E254198B34FC00A09E62 /* SimpleTimerTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SimpleTimerTests.swift; sourceTree = ""; };
136 | D12A181C198CB2E0007CE843 /* SimpleTimerTodayExtenstion.appex */ = {isa = PBXFileReference; explicitFileType = "wrapper.app-extension"; includeInIndex = 0; path = SimpleTimerTodayExtenstion.appex; sourceTree = BUILT_PRODUCTS_DIR; };
137 | D12A181E198CB2E0007CE843 /* NotificationCenter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = NotificationCenter.framework; path = System/Library/Frameworks/NotificationCenter.framework; sourceTree = SDKROOT; };
138 | D12A1822198CB2E0007CE843 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
139 | D12A1823198CB2E0007CE843 /* TodayViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TodayViewController.swift; sourceTree = ""; };
140 | D12A1825198CB2E0007CE843 /* MainInterface.storyboard */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; path = MainInterface.storyboard; sourceTree = ""; };
141 | D12A1830198CB4A4007CE843 /* SimpleTimer.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.xml; path = SimpleTimer.entitlements; sourceTree = ""; };
142 | D12A1831198CB4E5007CE843 /* SimpleTimerTodayExtenstion.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.xml; path = SimpleTimerTodayExtenstion.entitlements; sourceTree = ""; };
143 | D12A1837198CB9EF007CE843 /* SimpleTimerKit.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = SimpleTimerKit.framework; sourceTree = BUILT_PRODUCTS_DIR; };
144 | D12A183A198CB9EF007CE843 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
145 | D12A183B198CB9EF007CE843 /* SimpleTimerKit.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = SimpleTimerKit.h; sourceTree = ""; };
146 | D12A1841198CB9EF007CE843 /* SimpleTimerKitTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = SimpleTimerKitTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
147 | D12A1847198CB9EF007CE843 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
148 | D12A1848198CB9EF007CE843 /* SimpleTimerKitTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SimpleTimerKitTests.swift; sourceTree = ""; };
149 | D1B6B784198B5EC700DCF3A3 /* Timer.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Timer.swift; sourceTree = ""; };
150 | /* End PBXFileReference section */
151 |
152 | /* Begin PBXFrameworksBuildPhase section */
153 | D127E239198B34FC00A09E62 /* Frameworks */ = {
154 | isa = PBXFrameworksBuildPhase;
155 | buildActionMask = 2147483647;
156 | files = (
157 | D12A184C198CB9EF007CE843 /* SimpleTimerKit.framework in Frameworks */,
158 | );
159 | runOnlyForDeploymentPostprocessing = 0;
160 | };
161 | D127E24B198B34FC00A09E62 /* Frameworks */ = {
162 | isa = PBXFrameworksBuildPhase;
163 | buildActionMask = 2147483647;
164 | files = (
165 | );
166 | runOnlyForDeploymentPostprocessing = 0;
167 | };
168 | D12A1819198CB2E0007CE843 /* Frameworks */ = {
169 | isa = PBXFrameworksBuildPhase;
170 | buildActionMask = 2147483647;
171 | files = (
172 | D12A1860198CBBB5007CE843 /* SimpleTimerKit.framework in Frameworks */,
173 | D12A181F198CB2E0007CE843 /* NotificationCenter.framework in Frameworks */,
174 | );
175 | runOnlyForDeploymentPostprocessing = 0;
176 | };
177 | D12A1833198CB9EF007CE843 /* Frameworks */ = {
178 | isa = PBXFrameworksBuildPhase;
179 | buildActionMask = 2147483647;
180 | files = (
181 | );
182 | runOnlyForDeploymentPostprocessing = 0;
183 | };
184 | D12A183E198CB9EF007CE843 /* Frameworks */ = {
185 | isa = PBXFrameworksBuildPhase;
186 | buildActionMask = 2147483647;
187 | files = (
188 | D12A1842198CB9EF007CE843 /* SimpleTimerKit.framework in Frameworks */,
189 | );
190 | runOnlyForDeploymentPostprocessing = 0;
191 | };
192 | /* End PBXFrameworksBuildPhase section */
193 |
194 | /* Begin PBXGroup section */
195 | D127E233198B34FC00A09E62 = {
196 | isa = PBXGroup;
197 | children = (
198 | D127E23E198B34FC00A09E62 /* SimpleTimer */,
199 | D127E251198B34FC00A09E62 /* SimpleTimerTests */,
200 | D12A1820198CB2E0007CE843 /* SimpleTimerTodayExtenstion */,
201 | D12A1838198CB9EF007CE843 /* SimpleTimerKit */,
202 | D12A1845198CB9EF007CE843 /* SimpleTimerKitTests */,
203 | D12A181D198CB2E0007CE843 /* Frameworks */,
204 | D127E23D198B34FC00A09E62 /* Products */,
205 | );
206 | sourceTree = "";
207 | };
208 | D127E23D198B34FC00A09E62 /* Products */ = {
209 | isa = PBXGroup;
210 | children = (
211 | D127E23C198B34FC00A09E62 /* SimpleTimer.app */,
212 | D127E24E198B34FC00A09E62 /* SimpleTimerTests.xctest */,
213 | D12A181C198CB2E0007CE843 /* SimpleTimerTodayExtenstion.appex */,
214 | D12A1837198CB9EF007CE843 /* SimpleTimerKit.framework */,
215 | D12A1841198CB9EF007CE843 /* SimpleTimerKitTests.xctest */,
216 | );
217 | name = Products;
218 | sourceTree = "";
219 | };
220 | D127E23E198B34FC00A09E62 /* SimpleTimer */ = {
221 | isa = PBXGroup;
222 | children = (
223 | D12A1830198CB4A4007CE843 /* SimpleTimer.entitlements */,
224 | D127E241198B34FC00A09E62 /* AppDelegate.swift */,
225 | D127E243198B34FC00A09E62 /* ViewController.swift */,
226 | D127E245198B34FC00A09E62 /* Main.storyboard */,
227 | D127E248198B34FC00A09E62 /* Images.xcassets */,
228 | D127E23F198B34FC00A09E62 /* Supporting Files */,
229 | D1B6B784198B5EC700DCF3A3 /* Timer.swift */,
230 | );
231 | path = SimpleTimer;
232 | sourceTree = "";
233 | };
234 | D127E23F198B34FC00A09E62 /* Supporting Files */ = {
235 | isa = PBXGroup;
236 | children = (
237 | D127E240198B34FC00A09E62 /* Info.plist */,
238 | );
239 | name = "Supporting Files";
240 | sourceTree = "";
241 | };
242 | D127E251198B34FC00A09E62 /* SimpleTimerTests */ = {
243 | isa = PBXGroup;
244 | children = (
245 | D127E254198B34FC00A09E62 /* SimpleTimerTests.swift */,
246 | D127E252198B34FC00A09E62 /* Supporting Files */,
247 | );
248 | path = SimpleTimerTests;
249 | sourceTree = "";
250 | };
251 | D127E252198B34FC00A09E62 /* Supporting Files */ = {
252 | isa = PBXGroup;
253 | children = (
254 | D127E253198B34FC00A09E62 /* Info.plist */,
255 | );
256 | name = "Supporting Files";
257 | sourceTree = "";
258 | };
259 | D12A181D198CB2E0007CE843 /* Frameworks */ = {
260 | isa = PBXGroup;
261 | children = (
262 | D12A181E198CB2E0007CE843 /* NotificationCenter.framework */,
263 | );
264 | name = Frameworks;
265 | sourceTree = "";
266 | };
267 | D12A1820198CB2E0007CE843 /* SimpleTimerTodayExtenstion */ = {
268 | isa = PBXGroup;
269 | children = (
270 | D12A1831198CB4E5007CE843 /* SimpleTimerTodayExtenstion.entitlements */,
271 | D12A1823198CB2E0007CE843 /* TodayViewController.swift */,
272 | D12A1825198CB2E0007CE843 /* MainInterface.storyboard */,
273 | D12A1821198CB2E0007CE843 /* Supporting Files */,
274 | );
275 | path = SimpleTimerTodayExtenstion;
276 | sourceTree = "";
277 | };
278 | D12A1821198CB2E0007CE843 /* Supporting Files */ = {
279 | isa = PBXGroup;
280 | children = (
281 | D12A1822198CB2E0007CE843 /* Info.plist */,
282 | );
283 | name = "Supporting Files";
284 | sourceTree = "";
285 | };
286 | D12A1838198CB9EF007CE843 /* SimpleTimerKit */ = {
287 | isa = PBXGroup;
288 | children = (
289 | D12A183B198CB9EF007CE843 /* SimpleTimerKit.h */,
290 | D12A1839198CB9EF007CE843 /* Supporting Files */,
291 | );
292 | path = SimpleTimerKit;
293 | sourceTree = "";
294 | };
295 | D12A1839198CB9EF007CE843 /* Supporting Files */ = {
296 | isa = PBXGroup;
297 | children = (
298 | D12A183A198CB9EF007CE843 /* Info.plist */,
299 | );
300 | name = "Supporting Files";
301 | sourceTree = "";
302 | };
303 | D12A1845198CB9EF007CE843 /* SimpleTimerKitTests */ = {
304 | isa = PBXGroup;
305 | children = (
306 | D12A1848198CB9EF007CE843 /* SimpleTimerKitTests.swift */,
307 | D12A1846198CB9EF007CE843 /* Supporting Files */,
308 | );
309 | path = SimpleTimerKitTests;
310 | sourceTree = "";
311 | };
312 | D12A1846198CB9EF007CE843 /* Supporting Files */ = {
313 | isa = PBXGroup;
314 | children = (
315 | D12A1847198CB9EF007CE843 /* Info.plist */,
316 | );
317 | name = "Supporting Files";
318 | sourceTree = "";
319 | };
320 | /* End PBXGroup section */
321 |
322 | /* Begin PBXHeadersBuildPhase section */
323 | D12A1834198CB9EF007CE843 /* Headers */ = {
324 | isa = PBXHeadersBuildPhase;
325 | buildActionMask = 2147483647;
326 | files = (
327 | D12A183C198CB9EF007CE843 /* SimpleTimerKit.h in Headers */,
328 | );
329 | runOnlyForDeploymentPostprocessing = 0;
330 | };
331 | /* End PBXHeadersBuildPhase section */
332 |
333 | /* Begin PBXNativeTarget section */
334 | D127E23B198B34FC00A09E62 /* SimpleTimer */ = {
335 | isa = PBXNativeTarget;
336 | buildConfigurationList = D127E258198B34FC00A09E62 /* Build configuration list for PBXNativeTarget "SimpleTimer" */;
337 | buildPhases = (
338 | D127E238198B34FC00A09E62 /* Sources */,
339 | D127E239198B34FC00A09E62 /* Frameworks */,
340 | D127E23A198B34FC00A09E62 /* Resources */,
341 | D12A182F198CB2E0007CE843 /* Embed App Extensions */,
342 | D12A1853198CB9F0007CE843 /* Embed Frameworks */,
343 | );
344 | buildRules = (
345 | );
346 | dependencies = (
347 | D12A1828198CB2E0007CE843 /* PBXTargetDependency */,
348 | D12A182B198CB2E0007CE843 /* PBXTargetDependency */,
349 | D12A184B198CB9EF007CE843 /* PBXTargetDependency */,
350 | D12A184F198CB9F0007CE843 /* PBXTargetDependency */,
351 | );
352 | name = SimpleTimer;
353 | productName = SimpleTimer;
354 | productReference = D127E23C198B34FC00A09E62 /* SimpleTimer.app */;
355 | productType = "com.apple.product-type.application";
356 | };
357 | D127E24D198B34FC00A09E62 /* SimpleTimerTests */ = {
358 | isa = PBXNativeTarget;
359 | buildConfigurationList = D127E25B198B34FC00A09E62 /* Build configuration list for PBXNativeTarget "SimpleTimerTests" */;
360 | buildPhases = (
361 | D127E24A198B34FC00A09E62 /* Sources */,
362 | D127E24B198B34FC00A09E62 /* Frameworks */,
363 | D127E24C198B34FC00A09E62 /* Resources */,
364 | );
365 | buildRules = (
366 | );
367 | dependencies = (
368 | D127E250198B34FC00A09E62 /* PBXTargetDependency */,
369 | );
370 | name = SimpleTimerTests;
371 | productName = SimpleTimerTests;
372 | productReference = D127E24E198B34FC00A09E62 /* SimpleTimerTests.xctest */;
373 | productType = "com.apple.product-type.bundle.unit-test";
374 | };
375 | D12A181B198CB2E0007CE843 /* SimpleTimerTodayExtenstion */ = {
376 | isa = PBXNativeTarget;
377 | buildConfigurationList = D12A182E198CB2E0007CE843 /* Build configuration list for PBXNativeTarget "SimpleTimerTodayExtenstion" */;
378 | buildPhases = (
379 | D12A1818198CB2E0007CE843 /* Sources */,
380 | D12A1819198CB2E0007CE843 /* Frameworks */,
381 | D12A181A198CB2E0007CE843 /* Resources */,
382 | );
383 | buildRules = (
384 | );
385 | dependencies = (
386 | );
387 | name = SimpleTimerTodayExtenstion;
388 | productName = SimpleTimerTodayExtenstion;
389 | productReference = D12A181C198CB2E0007CE843 /* SimpleTimerTodayExtenstion.appex */;
390 | productType = "com.apple.product-type.app-extension";
391 | };
392 | D12A1836198CB9EF007CE843 /* SimpleTimerKit */ = {
393 | isa = PBXNativeTarget;
394 | buildConfigurationList = D12A1850198CB9F0007CE843 /* Build configuration list for PBXNativeTarget "SimpleTimerKit" */;
395 | buildPhases = (
396 | D12A1832198CB9EF007CE843 /* Sources */,
397 | D12A1833198CB9EF007CE843 /* Frameworks */,
398 | D12A1834198CB9EF007CE843 /* Headers */,
399 | D12A1835198CB9EF007CE843 /* Resources */,
400 | );
401 | buildRules = (
402 | );
403 | dependencies = (
404 | );
405 | name = SimpleTimerKit;
406 | productName = SimpleTimerKit;
407 | productReference = D12A1837198CB9EF007CE843 /* SimpleTimerKit.framework */;
408 | productType = "com.apple.product-type.framework";
409 | };
410 | D12A1840198CB9EF007CE843 /* SimpleTimerKitTests */ = {
411 | isa = PBXNativeTarget;
412 | buildConfigurationList = D12A1854198CB9F0007CE843 /* Build configuration list for PBXNativeTarget "SimpleTimerKitTests" */;
413 | buildPhases = (
414 | D12A183D198CB9EF007CE843 /* Sources */,
415 | D12A183E198CB9EF007CE843 /* Frameworks */,
416 | D12A183F198CB9EF007CE843 /* Resources */,
417 | );
418 | buildRules = (
419 | );
420 | dependencies = (
421 | D12A1844198CB9EF007CE843 /* PBXTargetDependency */,
422 | D12A1858198CB9F1007CE843 /* PBXTargetDependency */,
423 | D12A185A198CB9F1007CE843 /* PBXTargetDependency */,
424 | D12A185C198CB9F1007CE843 /* PBXTargetDependency */,
425 | D12A185E198CB9F1007CE843 /* PBXTargetDependency */,
426 | );
427 | name = SimpleTimerKitTests;
428 | productName = SimpleTimerKitTests;
429 | productReference = D12A1841198CB9EF007CE843 /* SimpleTimerKitTests.xctest */;
430 | productType = "com.apple.product-type.bundle.unit-test";
431 | };
432 | /* End PBXNativeTarget section */
433 |
434 | /* Begin PBXProject section */
435 | D127E234198B34FC00A09E62 /* Project object */ = {
436 | isa = PBXProject;
437 | attributes = {
438 | LastUpgradeCheck = 0600;
439 | ORGANIZATIONNAME = "OneV's Den";
440 | TargetAttributes = {
441 | D127E23B198B34FC00A09E62 = {
442 | CreatedOnToolsVersion = 6.0;
443 | DevelopmentTeam = T499X543T7;
444 | SystemCapabilities = {
445 | com.apple.ApplicationGroups.iOS = {
446 | enabled = 1;
447 | };
448 | };
449 | };
450 | D127E24D198B34FC00A09E62 = {
451 | CreatedOnToolsVersion = 6.0;
452 | TestTargetID = D127E23B198B34FC00A09E62;
453 | };
454 | D12A181B198CB2E0007CE843 = {
455 | CreatedOnToolsVersion = 6.0;
456 | DevelopmentTeam = T499X543T7;
457 | SystemCapabilities = {
458 | com.apple.ApplicationGroups.iOS = {
459 | enabled = 1;
460 | };
461 | };
462 | };
463 | D12A1836198CB9EF007CE843 = {
464 | CreatedOnToolsVersion = 6.0;
465 | DevelopmentTeam = T499X543T7;
466 | };
467 | D12A1840198CB9EF007CE843 = {
468 | CreatedOnToolsVersion = 6.0;
469 | TestTargetID = D12A1836198CB9EF007CE843;
470 | };
471 | };
472 | };
473 | buildConfigurationList = D127E237198B34FC00A09E62 /* Build configuration list for PBXProject "SimpleTimer" */;
474 | compatibilityVersion = "Xcode 3.2";
475 | developmentRegion = English;
476 | hasScannedForEncodings = 0;
477 | knownRegions = (
478 | en,
479 | Base,
480 | );
481 | mainGroup = D127E233198B34FC00A09E62;
482 | productRefGroup = D127E23D198B34FC00A09E62 /* Products */;
483 | projectDirPath = "";
484 | projectRoot = "";
485 | targets = (
486 | D127E23B198B34FC00A09E62 /* SimpleTimer */,
487 | D127E24D198B34FC00A09E62 /* SimpleTimerTests */,
488 | D12A181B198CB2E0007CE843 /* SimpleTimerTodayExtenstion */,
489 | D12A1836198CB9EF007CE843 /* SimpleTimerKit */,
490 | D12A1840198CB9EF007CE843 /* SimpleTimerKitTests */,
491 | );
492 | };
493 | /* End PBXProject section */
494 |
495 | /* Begin PBXResourcesBuildPhase section */
496 | D127E23A198B34FC00A09E62 /* Resources */ = {
497 | isa = PBXResourcesBuildPhase;
498 | buildActionMask = 2147483647;
499 | files = (
500 | D127E247198B34FC00A09E62 /* Main.storyboard in Resources */,
501 | D127E249198B34FC00A09E62 /* Images.xcassets in Resources */,
502 | );
503 | runOnlyForDeploymentPostprocessing = 0;
504 | };
505 | D127E24C198B34FC00A09E62 /* Resources */ = {
506 | isa = PBXResourcesBuildPhase;
507 | buildActionMask = 2147483647;
508 | files = (
509 | );
510 | runOnlyForDeploymentPostprocessing = 0;
511 | };
512 | D12A181A198CB2E0007CE843 /* Resources */ = {
513 | isa = PBXResourcesBuildPhase;
514 | buildActionMask = 2147483647;
515 | files = (
516 | D12A1826198CB2E0007CE843 /* MainInterface.storyboard in Resources */,
517 | );
518 | runOnlyForDeploymentPostprocessing = 0;
519 | };
520 | D12A1835198CB9EF007CE843 /* Resources */ = {
521 | isa = PBXResourcesBuildPhase;
522 | buildActionMask = 2147483647;
523 | files = (
524 | );
525 | runOnlyForDeploymentPostprocessing = 0;
526 | };
527 | D12A183F198CB9EF007CE843 /* Resources */ = {
528 | isa = PBXResourcesBuildPhase;
529 | buildActionMask = 2147483647;
530 | files = (
531 | );
532 | runOnlyForDeploymentPostprocessing = 0;
533 | };
534 | /* End PBXResourcesBuildPhase section */
535 |
536 | /* Begin PBXSourcesBuildPhase section */
537 | D127E238198B34FC00A09E62 /* Sources */ = {
538 | isa = PBXSourcesBuildPhase;
539 | buildActionMask = 2147483647;
540 | files = (
541 | D127E244198B34FC00A09E62 /* ViewController.swift in Sources */,
542 | D127E242198B34FC00A09E62 /* AppDelegate.swift in Sources */,
543 | );
544 | runOnlyForDeploymentPostprocessing = 0;
545 | };
546 | D127E24A198B34FC00A09E62 /* Sources */ = {
547 | isa = PBXSourcesBuildPhase;
548 | buildActionMask = 2147483647;
549 | files = (
550 | D127E255198B34FC00A09E62 /* SimpleTimerTests.swift in Sources */,
551 | );
552 | runOnlyForDeploymentPostprocessing = 0;
553 | };
554 | D12A1818198CB2E0007CE843 /* Sources */ = {
555 | isa = PBXSourcesBuildPhase;
556 | buildActionMask = 2147483647;
557 | files = (
558 | D12A1824198CB2E0007CE843 /* TodayViewController.swift in Sources */,
559 | );
560 | runOnlyForDeploymentPostprocessing = 0;
561 | };
562 | D12A1832198CB9EF007CE843 /* Sources */ = {
563 | isa = PBXSourcesBuildPhase;
564 | buildActionMask = 2147483647;
565 | files = (
566 | D12A185F198CBA3A007CE843 /* Timer.swift in Sources */,
567 | );
568 | runOnlyForDeploymentPostprocessing = 0;
569 | };
570 | D12A183D198CB9EF007CE843 /* Sources */ = {
571 | isa = PBXSourcesBuildPhase;
572 | buildActionMask = 2147483647;
573 | files = (
574 | D12A1849198CB9EF007CE843 /* SimpleTimerKitTests.swift in Sources */,
575 | );
576 | runOnlyForDeploymentPostprocessing = 0;
577 | };
578 | /* End PBXSourcesBuildPhase section */
579 |
580 | /* Begin PBXTargetDependency section */
581 | D127E250198B34FC00A09E62 /* PBXTargetDependency */ = {
582 | isa = PBXTargetDependency;
583 | target = D127E23B198B34FC00A09E62 /* SimpleTimer */;
584 | targetProxy = D127E24F198B34FC00A09E62 /* PBXContainerItemProxy */;
585 | };
586 | D12A1828198CB2E0007CE843 /* PBXTargetDependency */ = {
587 | isa = PBXTargetDependency;
588 | target = D12A181B198CB2E0007CE843 /* SimpleTimerTodayExtenstion */;
589 | targetProxy = D12A1827198CB2E0007CE843 /* PBXContainerItemProxy */;
590 | };
591 | D12A182B198CB2E0007CE843 /* PBXTargetDependency */ = {
592 | isa = PBXTargetDependency;
593 | target = D12A181B198CB2E0007CE843 /* SimpleTimerTodayExtenstion */;
594 | targetProxy = D12A182A198CB2E0007CE843 /* PBXContainerItemProxy */;
595 | };
596 | D12A1844198CB9EF007CE843 /* PBXTargetDependency */ = {
597 | isa = PBXTargetDependency;
598 | target = D12A1836198CB9EF007CE843 /* SimpleTimerKit */;
599 | targetProxy = D12A1843198CB9EF007CE843 /* PBXContainerItemProxy */;
600 | };
601 | D12A184B198CB9EF007CE843 /* PBXTargetDependency */ = {
602 | isa = PBXTargetDependency;
603 | target = D12A1836198CB9EF007CE843 /* SimpleTimerKit */;
604 | targetProxy = D12A184A198CB9EF007CE843 /* PBXContainerItemProxy */;
605 | };
606 | D12A184F198CB9F0007CE843 /* PBXTargetDependency */ = {
607 | isa = PBXTargetDependency;
608 | target = D12A1836198CB9EF007CE843 /* SimpleTimerKit */;
609 | targetProxy = D12A184E198CB9F0007CE843 /* PBXContainerItemProxy */;
610 | };
611 | D12A1858198CB9F1007CE843 /* PBXTargetDependency */ = {
612 | isa = PBXTargetDependency;
613 | target = D12A1836198CB9EF007CE843 /* SimpleTimerKit */;
614 | targetProxy = D12A1857198CB9F1007CE843 /* PBXContainerItemProxy */;
615 | };
616 | D12A185A198CB9F1007CE843 /* PBXTargetDependency */ = {
617 | isa = PBXTargetDependency;
618 | target = D12A1836198CB9EF007CE843 /* SimpleTimerKit */;
619 | targetProxy = D12A1859198CB9F1007CE843 /* PBXContainerItemProxy */;
620 | };
621 | D12A185C198CB9F1007CE843 /* PBXTargetDependency */ = {
622 | isa = PBXTargetDependency;
623 | target = D12A1836198CB9EF007CE843 /* SimpleTimerKit */;
624 | targetProxy = D12A185B198CB9F1007CE843 /* PBXContainerItemProxy */;
625 | };
626 | D12A185E198CB9F1007CE843 /* PBXTargetDependency */ = {
627 | isa = PBXTargetDependency;
628 | target = D12A1836198CB9EF007CE843 /* SimpleTimerKit */;
629 | targetProxy = D12A185D198CB9F1007CE843 /* PBXContainerItemProxy */;
630 | };
631 | /* End PBXTargetDependency section */
632 |
633 | /* Begin PBXVariantGroup section */
634 | D127E245198B34FC00A09E62 /* Main.storyboard */ = {
635 | isa = PBXVariantGroup;
636 | children = (
637 | D127E246198B34FC00A09E62 /* Base */,
638 | );
639 | name = Main.storyboard;
640 | sourceTree = "";
641 | };
642 | /* End PBXVariantGroup section */
643 |
644 | /* Begin XCBuildConfiguration section */
645 | D127E256198B34FC00A09E62 /* Debug */ = {
646 | isa = XCBuildConfiguration;
647 | buildSettings = {
648 | ALWAYS_SEARCH_USER_PATHS = NO;
649 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
650 | CLANG_CXX_LIBRARY = "libc++";
651 | CLANG_ENABLE_MODULES = YES;
652 | CLANG_ENABLE_OBJC_ARC = YES;
653 | CLANG_WARN_BOOL_CONVERSION = YES;
654 | CLANG_WARN_CONSTANT_CONVERSION = YES;
655 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
656 | CLANG_WARN_EMPTY_BODY = YES;
657 | CLANG_WARN_ENUM_CONVERSION = YES;
658 | CLANG_WARN_INT_CONVERSION = YES;
659 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
660 | CLANG_WARN_UNREACHABLE_CODE = YES;
661 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
662 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
663 | COPY_PHASE_STRIP = NO;
664 | ENABLE_STRICT_OBJC_MSGSEND = YES;
665 | GCC_C_LANGUAGE_STANDARD = gnu99;
666 | GCC_DYNAMIC_NO_PIC = NO;
667 | GCC_OPTIMIZATION_LEVEL = 0;
668 | GCC_PREPROCESSOR_DEFINITIONS = (
669 | "DEBUG=1",
670 | "$(inherited)",
671 | );
672 | GCC_SYMBOLS_PRIVATE_EXTERN = NO;
673 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
674 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
675 | GCC_WARN_UNDECLARED_SELECTOR = YES;
676 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
677 | GCC_WARN_UNUSED_FUNCTION = YES;
678 | GCC_WARN_UNUSED_VARIABLE = YES;
679 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
680 | MTL_ENABLE_DEBUG_INFO = YES;
681 | ONLY_ACTIVE_ARCH = YES;
682 | SDKROOT = iphoneos;
683 | SWIFT_OPTIMIZATION_LEVEL = "-Onone";
684 | TARGETED_DEVICE_FAMILY = "1,2";
685 | };
686 | name = Debug;
687 | };
688 | D127E257198B34FC00A09E62 /* Release */ = {
689 | isa = XCBuildConfiguration;
690 | buildSettings = {
691 | ALWAYS_SEARCH_USER_PATHS = NO;
692 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
693 | CLANG_CXX_LIBRARY = "libc++";
694 | CLANG_ENABLE_MODULES = YES;
695 | CLANG_ENABLE_OBJC_ARC = YES;
696 | CLANG_WARN_BOOL_CONVERSION = YES;
697 | CLANG_WARN_CONSTANT_CONVERSION = YES;
698 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
699 | CLANG_WARN_EMPTY_BODY = YES;
700 | CLANG_WARN_ENUM_CONVERSION = YES;
701 | CLANG_WARN_INT_CONVERSION = YES;
702 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
703 | CLANG_WARN_UNREACHABLE_CODE = YES;
704 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
705 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
706 | COPY_PHASE_STRIP = YES;
707 | ENABLE_NS_ASSERTIONS = NO;
708 | ENABLE_STRICT_OBJC_MSGSEND = YES;
709 | GCC_C_LANGUAGE_STANDARD = gnu99;
710 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
711 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
712 | GCC_WARN_UNDECLARED_SELECTOR = YES;
713 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
714 | GCC_WARN_UNUSED_FUNCTION = YES;
715 | GCC_WARN_UNUSED_VARIABLE = YES;
716 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
717 | MTL_ENABLE_DEBUG_INFO = NO;
718 | SDKROOT = iphoneos;
719 | TARGETED_DEVICE_FAMILY = "1,2";
720 | VALIDATE_PRODUCT = YES;
721 | };
722 | name = Release;
723 | };
724 | D127E259198B34FC00A09E62 /* Debug */ = {
725 | isa = XCBuildConfiguration;
726 | buildSettings = {
727 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
728 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
729 | CODE_SIGN_ENTITLEMENTS = SimpleTimer/SimpleTimer.entitlements;
730 | INFOPLIST_FILE = SimpleTimer/Info.plist;
731 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
732 | PRODUCT_NAME = "$(TARGET_NAME)";
733 | };
734 | name = Debug;
735 | };
736 | D127E25A198B34FC00A09E62 /* Release */ = {
737 | isa = XCBuildConfiguration;
738 | buildSettings = {
739 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
740 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
741 | CODE_SIGN_ENTITLEMENTS = SimpleTimer/SimpleTimer.entitlements;
742 | INFOPLIST_FILE = SimpleTimer/Info.plist;
743 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
744 | PRODUCT_NAME = "$(TARGET_NAME)";
745 | };
746 | name = Release;
747 | };
748 | D127E25C198B34FC00A09E62 /* Debug */ = {
749 | isa = XCBuildConfiguration;
750 | buildSettings = {
751 | BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/SimpleTimer.app/SimpleTimer";
752 | FRAMEWORK_SEARCH_PATHS = (
753 | "$(SDKROOT)/Developer/Library/Frameworks",
754 | "$(inherited)",
755 | );
756 | GCC_PREPROCESSOR_DEFINITIONS = (
757 | "DEBUG=1",
758 | "$(inherited)",
759 | );
760 | INFOPLIST_FILE = SimpleTimerTests/Info.plist;
761 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
762 | PRODUCT_NAME = "$(TARGET_NAME)";
763 | TEST_HOST = "$(BUNDLE_LOADER)";
764 | };
765 | name = Debug;
766 | };
767 | D127E25D198B34FC00A09E62 /* Release */ = {
768 | isa = XCBuildConfiguration;
769 | buildSettings = {
770 | BUNDLE_LOADER = "$(BUILT_PRODUCTS_DIR)/SimpleTimer.app/SimpleTimer";
771 | FRAMEWORK_SEARCH_PATHS = (
772 | "$(SDKROOT)/Developer/Library/Frameworks",
773 | "$(inherited)",
774 | );
775 | INFOPLIST_FILE = SimpleTimerTests/Info.plist;
776 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
777 | PRODUCT_NAME = "$(TARGET_NAME)";
778 | TEST_HOST = "$(BUNDLE_LOADER)";
779 | };
780 | name = Release;
781 | };
782 | D12A182C198CB2E0007CE843 /* Debug */ = {
783 | isa = XCBuildConfiguration;
784 | buildSettings = {
785 | CODE_SIGN_ENTITLEMENTS = SimpleTimerTodayExtenstion/SimpleTimerTodayExtenstion.entitlements;
786 | CODE_SIGN_IDENTITY = "iPhone Developer";
787 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
788 | GCC_PREPROCESSOR_DEFINITIONS = (
789 | "DEBUG=1",
790 | "$(inherited)",
791 | );
792 | INFOPLIST_FILE = SimpleTimerTodayExtenstion/Info.plist;
793 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
794 | PRODUCT_NAME = "$(TARGET_NAME)";
795 | PROVISIONING_PROFILE = "";
796 | SKIP_INSTALL = YES;
797 | };
798 | name = Debug;
799 | };
800 | D12A182D198CB2E0007CE843 /* Release */ = {
801 | isa = XCBuildConfiguration;
802 | buildSettings = {
803 | CODE_SIGN_ENTITLEMENTS = SimpleTimerTodayExtenstion/SimpleTimerTodayExtenstion.entitlements;
804 | CODE_SIGN_IDENTITY = "iPhone Developer";
805 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
806 | INFOPLIST_FILE = SimpleTimerTodayExtenstion/Info.plist;
807 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @executable_path/../../Frameworks";
808 | PRODUCT_NAME = "$(TARGET_NAME)";
809 | PROVISIONING_PROFILE = "";
810 | SKIP_INSTALL = YES;
811 | };
812 | name = Release;
813 | };
814 | D12A1851198CB9F0007CE843 /* Debug */ = {
815 | isa = XCBuildConfiguration;
816 | buildSettings = {
817 | APPLICATION_EXTENSION_API_ONLY = YES;
818 | CURRENT_PROJECT_VERSION = 1;
819 | DEFINES_MODULE = YES;
820 | DYLIB_COMPATIBILITY_VERSION = 1;
821 | DYLIB_CURRENT_VERSION = 1;
822 | DYLIB_INSTALL_NAME_BASE = "@rpath";
823 | GCC_PREPROCESSOR_DEFINITIONS = (
824 | "DEBUG=1",
825 | "$(inherited)",
826 | );
827 | INFOPLIST_FILE = SimpleTimerKit/Info.plist;
828 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
829 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
830 | PRODUCT_NAME = "$(TARGET_NAME)";
831 | SKIP_INSTALL = YES;
832 | VERSIONING_SYSTEM = "apple-generic";
833 | VERSION_INFO_PREFIX = "";
834 | };
835 | name = Debug;
836 | };
837 | D12A1852198CB9F0007CE843 /* Release */ = {
838 | isa = XCBuildConfiguration;
839 | buildSettings = {
840 | APPLICATION_EXTENSION_API_ONLY = YES;
841 | CURRENT_PROJECT_VERSION = 1;
842 | DEFINES_MODULE = YES;
843 | DYLIB_COMPATIBILITY_VERSION = 1;
844 | DYLIB_CURRENT_VERSION = 1;
845 | DYLIB_INSTALL_NAME_BASE = "@rpath";
846 | INFOPLIST_FILE = SimpleTimerKit/Info.plist;
847 | INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
848 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
849 | PRODUCT_NAME = "$(TARGET_NAME)";
850 | SKIP_INSTALL = YES;
851 | VERSIONING_SYSTEM = "apple-generic";
852 | VERSION_INFO_PREFIX = "";
853 | };
854 | name = Release;
855 | };
856 | D12A1855198CB9F0007CE843 /* Debug */ = {
857 | isa = XCBuildConfiguration;
858 | buildSettings = {
859 | FRAMEWORK_SEARCH_PATHS = (
860 | "$(SDKROOT)/Developer/Library/Frameworks",
861 | "$(inherited)",
862 | );
863 | GCC_PREPROCESSOR_DEFINITIONS = (
864 | "DEBUG=1",
865 | "$(inherited)",
866 | );
867 | INFOPLIST_FILE = SimpleTimerKitTests/Info.plist;
868 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
869 | PRODUCT_NAME = "$(TARGET_NAME)";
870 | };
871 | name = Debug;
872 | };
873 | D12A1856198CB9F0007CE843 /* Release */ = {
874 | isa = XCBuildConfiguration;
875 | buildSettings = {
876 | FRAMEWORK_SEARCH_PATHS = (
877 | "$(SDKROOT)/Developer/Library/Frameworks",
878 | "$(inherited)",
879 | );
880 | INFOPLIST_FILE = SimpleTimerKitTests/Info.plist;
881 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
882 | PRODUCT_NAME = "$(TARGET_NAME)";
883 | };
884 | name = Release;
885 | };
886 | /* End XCBuildConfiguration section */
887 |
888 | /* Begin XCConfigurationList section */
889 | D127E237198B34FC00A09E62 /* Build configuration list for PBXProject "SimpleTimer" */ = {
890 | isa = XCConfigurationList;
891 | buildConfigurations = (
892 | D127E256198B34FC00A09E62 /* Debug */,
893 | D127E257198B34FC00A09E62 /* Release */,
894 | );
895 | defaultConfigurationIsVisible = 0;
896 | defaultConfigurationName = Release;
897 | };
898 | D127E258198B34FC00A09E62 /* Build configuration list for PBXNativeTarget "SimpleTimer" */ = {
899 | isa = XCConfigurationList;
900 | buildConfigurations = (
901 | D127E259198B34FC00A09E62 /* Debug */,
902 | D127E25A198B34FC00A09E62 /* Release */,
903 | );
904 | defaultConfigurationIsVisible = 0;
905 | defaultConfigurationName = Release;
906 | };
907 | D127E25B198B34FC00A09E62 /* Build configuration list for PBXNativeTarget "SimpleTimerTests" */ = {
908 | isa = XCConfigurationList;
909 | buildConfigurations = (
910 | D127E25C198B34FC00A09E62 /* Debug */,
911 | D127E25D198B34FC00A09E62 /* Release */,
912 | );
913 | defaultConfigurationIsVisible = 0;
914 | defaultConfigurationName = Release;
915 | };
916 | D12A182E198CB2E0007CE843 /* Build configuration list for PBXNativeTarget "SimpleTimerTodayExtenstion" */ = {
917 | isa = XCConfigurationList;
918 | buildConfigurations = (
919 | D12A182C198CB2E0007CE843 /* Debug */,
920 | D12A182D198CB2E0007CE843 /* Release */,
921 | );
922 | defaultConfigurationIsVisible = 0;
923 | };
924 | D12A1850198CB9F0007CE843 /* Build configuration list for PBXNativeTarget "SimpleTimerKit" */ = {
925 | isa = XCConfigurationList;
926 | buildConfigurations = (
927 | D12A1851198CB9F0007CE843 /* Debug */,
928 | D12A1852198CB9F0007CE843 /* Release */,
929 | );
930 | defaultConfigurationIsVisible = 0;
931 | };
932 | D12A1854198CB9F0007CE843 /* Build configuration list for PBXNativeTarget "SimpleTimerKitTests" */ = {
933 | isa = XCConfigurationList;
934 | buildConfigurations = (
935 | D12A1855198CB9F0007CE843 /* Debug */,
936 | D12A1856198CB9F0007CE843 /* Release */,
937 | );
938 | defaultConfigurationIsVisible = 0;
939 | };
940 | /* End XCConfigurationList section */
941 | };
942 | rootObject = D127E234198B34FC00A09E62 /* Project object */;
943 | }
944 |
--------------------------------------------------------------------------------