From e4974dd5b7613f1564dc30dd7f66f9983b4318ee Mon Sep 17 00:00:00 2001 From: "A.myc" Date: Wed, 26 Oct 2016 19:13:00 +0800 Subject: [PATCH] project02 & project03 --- .../Calendar.xcodeproj/project.pbxproj" | 518 +++++++++++++++++ .../Calendar/Calendar/AppDelegate.h" | 17 + .../Calendar/Calendar/AppDelegate.m" | 48 ++ .../AppIcon.appiconset/Contents.json" | 68 +++ .../Base.lproj/LaunchScreen.storyboard" | 27 + .../project02/Calendar/Calendar/Info.plist" | 43 ++ .../Calendar/Calendar/ViewController.h" | 15 + .../Calendar/Calendar/ViewController.m" | 30 + .../Calendar/Calendar/calendarView.h" | 13 + .../Calendar/Calendar/calendarView.m" | 222 ++++++++ .../project02/Calendar/Calendar/main.m" | 16 + .../Calendar/CalendarTests/CalendarTests.m" | 39 ++ .../Calendar/CalendarTests/Info.plist" | 24 + .../CalendarUITests/CalendarUITests.m" | 40 ++ .../Calendar/CalendarUITests/Info.plist" | 24 + .../TaskList.xcodeproj/project.pbxproj" | 519 ++++++++++++++++++ .../contents.xcworkspacedata" | 7 + .../TaskList/TaskList/AppDelegate.h" | 26 + .../TaskList/TaskList/AppDelegate.m" | 125 +++++ .../AppIcon.appiconset/Contents.json" | 38 ++ .../Base.lproj/LaunchScreen.storyboard" | 27 + .../TaskList/Base.lproj/Main.storyboard" | 26 + .../project03/TaskList/TaskList/Info.plist" | 36 ++ .../TaskList/TaskList/ViewController.h" | 20 + .../TaskList/TaskList/ViewController.m" | 28 + .../project03/TaskList/TaskList/main.m" | 20 + .../TaskList/TaskListTests/Info.plist" | 24 + .../TaskList/TaskListTests/TaskListTests.m" | 40 ++ .../TaskList/TaskListUITests/Info.plist" | 24 + .../TaskListUITests/TaskListUITests.m" | 40 ++ 30 files changed, 2144 insertions(+) create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar.xcodeproj/project.pbxproj" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/AppDelegate.h" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/AppDelegate.m" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Assets.xcassets/AppIcon.appiconset/Contents.json" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Base.lproj/LaunchScreen.storyboard" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Info.plist" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/ViewController.h" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/ViewController.m" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/calendarView.h" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/calendarView.m" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/main.m" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarTests/CalendarTests.m" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarTests/Info.plist" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarUITests/CalendarUITests.m" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarUITests/Info.plist" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList.xcodeproj/project.pbxproj" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList.xcodeproj/project.xcworkspace/contents.xcworkspacedata" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/AppDelegate.h" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/AppDelegate.m" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Assets.xcassets/AppIcon.appiconset/Contents.json" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Base.lproj/LaunchScreen.storyboard" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Base.lproj/Main.storyboard" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Info.plist" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/ViewController.h" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/ViewController.m" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/main.m" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListTests/Info.plist" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListTests/TaskListTests.m" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListUITests/Info.plist" create mode 100755 "21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListUITests/TaskListUITests.m" diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar.xcodeproj/project.pbxproj" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar.xcodeproj/project.pbxproj" new file mode 100755 index 0000000..4f7ad53 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar.xcodeproj/project.pbxproj" @@ -0,0 +1,518 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + 75F6DE2E1DB45B0100101EE8 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 75F6DE2D1DB45B0100101EE8 /* main.m */; }; + 75F6DE311DB45B0100101EE8 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 75F6DE301DB45B0100101EE8 /* AppDelegate.m */; }; + 75F6DE341DB45B0100101EE8 /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 75F6DE331DB45B0100101EE8 /* ViewController.m */; }; + 75F6DE391DB45B0100101EE8 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 75F6DE381DB45B0100101EE8 /* Assets.xcassets */; }; + 75F6DE3C1DB45B0100101EE8 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 75F6DE3A1DB45B0100101EE8 /* LaunchScreen.storyboard */; }; + 75F6DE471DB45B0100101EE8 /* CalendarTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 75F6DE461DB45B0100101EE8 /* CalendarTests.m */; }; + 75F6DE521DB45B0100101EE8 /* CalendarUITests.m in Sources */ = {isa = PBXBuildFile; fileRef = 75F6DE511DB45B0100101EE8 /* CalendarUITests.m */; }; + 75F6DE611DB4601E00101EE8 /* calendarView.m in Sources */ = {isa = PBXBuildFile; fileRef = 75F6DE601DB4601E00101EE8 /* calendarView.m */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 75F6DE431DB45B0100101EE8 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 75F6DE211DB45B0100101EE8 /* Project object */; + proxyType = 1; + remoteGlobalIDString = 75F6DE281DB45B0100101EE8; + remoteInfo = Calendar; + }; + 75F6DE4E1DB45B0100101EE8 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 75F6DE211DB45B0100101EE8 /* Project object */; + proxyType = 1; + remoteGlobalIDString = 75F6DE281DB45B0100101EE8; + remoteInfo = Calendar; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + 75F6DE291DB45B0100101EE8 /* Calendar.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Calendar.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 75F6DE2D1DB45B0100101EE8 /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; + 75F6DE2F1DB45B0100101EE8 /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; + 75F6DE301DB45B0100101EE8 /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; + 75F6DE321DB45B0100101EE8 /* ViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ViewController.h; sourceTree = ""; }; + 75F6DE331DB45B0100101EE8 /* ViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ViewController.m; sourceTree = ""; }; + 75F6DE381DB45B0100101EE8 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 75F6DE3B1DB45B0100101EE8 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + 75F6DE3D1DB45B0100101EE8 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 75F6DE421DB45B0100101EE8 /* CalendarTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = CalendarTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 75F6DE461DB45B0100101EE8 /* CalendarTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = CalendarTests.m; sourceTree = ""; }; + 75F6DE481DB45B0100101EE8 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 75F6DE4D1DB45B0100101EE8 /* CalendarUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = CalendarUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 75F6DE511DB45B0100101EE8 /* CalendarUITests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = CalendarUITests.m; sourceTree = ""; }; + 75F6DE531DB45B0100101EE8 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 75F6DE5F1DB4601E00101EE8 /* calendarView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = calendarView.h; sourceTree = ""; }; + 75F6DE601DB4601E00101EE8 /* calendarView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = calendarView.m; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 75F6DE261DB45B0100101EE8 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 75F6DE3F1DB45B0100101EE8 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 75F6DE4A1DB45B0100101EE8 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 75F6DE201DB45B0100101EE8 = { + isa = PBXGroup; + children = ( + 75F6DE2B1DB45B0100101EE8 /* Calendar */, + 75F6DE451DB45B0100101EE8 /* CalendarTests */, + 75F6DE501DB45B0100101EE8 /* CalendarUITests */, + 75F6DE2A1DB45B0100101EE8 /* Products */, + ); + sourceTree = ""; + }; + 75F6DE2A1DB45B0100101EE8 /* Products */ = { + isa = PBXGroup; + children = ( + 75F6DE291DB45B0100101EE8 /* Calendar.app */, + 75F6DE421DB45B0100101EE8 /* CalendarTests.xctest */, + 75F6DE4D1DB45B0100101EE8 /* CalendarUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + 75F6DE2B1DB45B0100101EE8 /* Calendar */ = { + isa = PBXGroup; + children = ( + 75F6DE2F1DB45B0100101EE8 /* AppDelegate.h */, + 75F6DE301DB45B0100101EE8 /* AppDelegate.m */, + 75F6DE321DB45B0100101EE8 /* ViewController.h */, + 75F6DE331DB45B0100101EE8 /* ViewController.m */, + 75F6DE5F1DB4601E00101EE8 /* calendarView.h */, + 75F6DE601DB4601E00101EE8 /* calendarView.m */, + 75F6DE381DB45B0100101EE8 /* Assets.xcassets */, + 75F6DE3A1DB45B0100101EE8 /* LaunchScreen.storyboard */, + 75F6DE3D1DB45B0100101EE8 /* Info.plist */, + 75F6DE2C1DB45B0100101EE8 /* Supporting Files */, + ); + path = Calendar; + sourceTree = ""; + }; + 75F6DE2C1DB45B0100101EE8 /* Supporting Files */ = { + isa = PBXGroup; + children = ( + 75F6DE2D1DB45B0100101EE8 /* main.m */, + ); + name = "Supporting Files"; + sourceTree = ""; + }; + 75F6DE451DB45B0100101EE8 /* CalendarTests */ = { + isa = PBXGroup; + children = ( + 75F6DE461DB45B0100101EE8 /* CalendarTests.m */, + 75F6DE481DB45B0100101EE8 /* Info.plist */, + ); + path = CalendarTests; + sourceTree = ""; + }; + 75F6DE501DB45B0100101EE8 /* CalendarUITests */ = { + isa = PBXGroup; + children = ( + 75F6DE511DB45B0100101EE8 /* CalendarUITests.m */, + 75F6DE531DB45B0100101EE8 /* Info.plist */, + ); + path = CalendarUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 75F6DE281DB45B0100101EE8 /* Calendar */ = { + isa = PBXNativeTarget; + buildConfigurationList = 75F6DE561DB45B0100101EE8 /* Build configuration list for PBXNativeTarget "Calendar" */; + buildPhases = ( + 75F6DE251DB45B0100101EE8 /* Sources */, + 75F6DE261DB45B0100101EE8 /* Frameworks */, + 75F6DE271DB45B0100101EE8 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = Calendar; + productName = Calendar; + productReference = 75F6DE291DB45B0100101EE8 /* Calendar.app */; + productType = "com.apple.product-type.application"; + }; + 75F6DE411DB45B0100101EE8 /* CalendarTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 75F6DE591DB45B0100101EE8 /* Build configuration list for PBXNativeTarget "CalendarTests" */; + buildPhases = ( + 75F6DE3E1DB45B0100101EE8 /* Sources */, + 75F6DE3F1DB45B0100101EE8 /* Frameworks */, + 75F6DE401DB45B0100101EE8 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 75F6DE441DB45B0100101EE8 /* PBXTargetDependency */, + ); + name = CalendarTests; + productName = CalendarTests; + productReference = 75F6DE421DB45B0100101EE8 /* CalendarTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + 75F6DE4C1DB45B0100101EE8 /* CalendarUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 75F6DE5C1DB45B0100101EE8 /* Build configuration list for PBXNativeTarget "CalendarUITests" */; + buildPhases = ( + 75F6DE491DB45B0100101EE8 /* Sources */, + 75F6DE4A1DB45B0100101EE8 /* Frameworks */, + 75F6DE4B1DB45B0100101EE8 /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 75F6DE4F1DB45B0100101EE8 /* PBXTargetDependency */, + ); + name = CalendarUITests; + productName = CalendarUITests; + productReference = 75F6DE4D1DB45B0100101EE8 /* CalendarUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 75F6DE211DB45B0100101EE8 /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 0730; + ORGANIZATIONNAME = "戈宇泽"; + TargetAttributes = { + 75F6DE281DB45B0100101EE8 = { + CreatedOnToolsVersion = 7.3.1; + DevelopmentTeam = SS9HKPN8LV; + }; + 75F6DE411DB45B0100101EE8 = { + CreatedOnToolsVersion = 7.3.1; + DevelopmentTeam = SS9HKPN8LV; + TestTargetID = 75F6DE281DB45B0100101EE8; + }; + 75F6DE4C1DB45B0100101EE8 = { + CreatedOnToolsVersion = 7.3.1; + DevelopmentTeam = SS9HKPN8LV; + TestTargetID = 75F6DE281DB45B0100101EE8; + }; + }; + }; + buildConfigurationList = 75F6DE241DB45B0100101EE8 /* Build configuration list for PBXProject "Calendar" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 75F6DE201DB45B0100101EE8; + productRefGroup = 75F6DE2A1DB45B0100101EE8 /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 75F6DE281DB45B0100101EE8 /* Calendar */, + 75F6DE411DB45B0100101EE8 /* CalendarTests */, + 75F6DE4C1DB45B0100101EE8 /* CalendarUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 75F6DE271DB45B0100101EE8 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 75F6DE3C1DB45B0100101EE8 /* LaunchScreen.storyboard in Resources */, + 75F6DE391DB45B0100101EE8 /* Assets.xcassets in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 75F6DE401DB45B0100101EE8 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 75F6DE4B1DB45B0100101EE8 /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 75F6DE251DB45B0100101EE8 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 75F6DE341DB45B0100101EE8 /* ViewController.m in Sources */, + 75F6DE311DB45B0100101EE8 /* AppDelegate.m in Sources */, + 75F6DE611DB4601E00101EE8 /* calendarView.m in Sources */, + 75F6DE2E1DB45B0100101EE8 /* main.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 75F6DE3E1DB45B0100101EE8 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 75F6DE471DB45B0100101EE8 /* CalendarTests.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 75F6DE491DB45B0100101EE8 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 75F6DE521DB45B0100101EE8 /* CalendarUITests.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 75F6DE441DB45B0100101EE8 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 75F6DE281DB45B0100101EE8 /* Calendar */; + targetProxy = 75F6DE431DB45B0100101EE8 /* PBXContainerItemProxy */; + }; + 75F6DE4F1DB45B0100101EE8 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 75F6DE281DB45B0100101EE8 /* Calendar */; + targetProxy = 75F6DE4E1DB45B0100101EE8 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + 75F6DE3A1DB45B0100101EE8 /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 75F6DE3B1DB45B0100101EE8 /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 75F6DE541DB45B0100101EE8 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.3; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 75F6DE551DB45B0100101EE8 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.3; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + TARGETED_DEVICE_FAMILY = "1,2"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 75F6DE571DB45B0100101EE8 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + INFOPLIST_FILE = Calendar/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = com.gyz.Calendar; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Debug; + }; + 75F6DE581DB45B0100101EE8 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + INFOPLIST_FILE = Calendar/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = com.gyz.Calendar; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 75F6DE5A1DB45B0100101EE8 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + INFOPLIST_FILE = CalendarTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = com.gyz.CalendarTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Calendar.app/Calendar"; + }; + name = Debug; + }; + 75F6DE5B1DB45B0100101EE8 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + INFOPLIST_FILE = CalendarTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = com.gyz.CalendarTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Calendar.app/Calendar"; + }; + name = Release; + }; + 75F6DE5D1DB45B0100101EE8 /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + INFOPLIST_FILE = CalendarUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = com.gyz.CalendarUITests; + PRODUCT_NAME = "$(TARGET_NAME)"; + TEST_TARGET_NAME = Calendar; + }; + name = Debug; + }; + 75F6DE5E1DB45B0100101EE8 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INFOPLIST_FILE = CalendarUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = com.gyz.CalendarUITests; + PRODUCT_NAME = "$(TARGET_NAME)"; + TEST_TARGET_NAME = Calendar; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 75F6DE241DB45B0100101EE8 /* Build configuration list for PBXProject "Calendar" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 75F6DE541DB45B0100101EE8 /* Debug */, + 75F6DE551DB45B0100101EE8 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 75F6DE561DB45B0100101EE8 /* Build configuration list for PBXNativeTarget "Calendar" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 75F6DE571DB45B0100101EE8 /* Debug */, + 75F6DE581DB45B0100101EE8 /* Release */, + ); + defaultConfigurationIsVisible = 0; + }; + 75F6DE591DB45B0100101EE8 /* Build configuration list for PBXNativeTarget "CalendarTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 75F6DE5A1DB45B0100101EE8 /* Debug */, + 75F6DE5B1DB45B0100101EE8 /* Release */, + ); + defaultConfigurationIsVisible = 0; + }; + 75F6DE5C1DB45B0100101EE8 /* Build configuration list for PBXNativeTarget "CalendarUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 75F6DE5D1DB45B0100101EE8 /* Debug */, + 75F6DE5E1DB45B0100101EE8 /* Release */, + ); + defaultConfigurationIsVisible = 0; + }; +/* End XCConfigurationList section */ + }; + rootObject = 75F6DE211DB45B0100101EE8 /* Project object */; +} diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/AppDelegate.h" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/AppDelegate.h" new file mode 100755 index 0000000..b1d2272 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/AppDelegate.h" @@ -0,0 +1,17 @@ +// +// AppDelegate.h +// Calendar +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import + +@interface AppDelegate : UIResponder + +@property (strong, nonatomic) UIWindow *window; + + +@end + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/AppDelegate.m" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/AppDelegate.m" new file mode 100755 index 0000000..9ca1a6e --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/AppDelegate.m" @@ -0,0 +1,48 @@ +// +// AppDelegate.m +// Calendar +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import "AppDelegate.h" +#import "ViewController.h" + +@interface AppDelegate () + +@end + +@implementation AppDelegate + + +- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { + self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]]; + self.window.rootViewController = [[ViewController alloc] init]; + [self.window makeKeyAndVisible]; + return YES; +} + +- (void)applicationWillResignActive:(UIApplication *)application { + // 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. + // 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. +} + +- (void)applicationDidEnterBackground:(UIApplication *)application { + // 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. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. +} + +- (void)applicationWillEnterForeground:(UIApplication *)application { + // 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. +} + +- (void)applicationDidBecomeActive:(UIApplication *)application { + // 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. +} + +- (void)applicationWillTerminate:(UIApplication *)application { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. +} + +@end diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100755 index 0000000..36d2c80 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,68 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "1x" + }, + { + "idiom" : "ipad", + "size" : "76x76", + "scale" : "2x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Base.lproj/LaunchScreen.storyboard" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Base.lproj/LaunchScreen.storyboard" new file mode 100755 index 0000000..2e721e1 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Info.plist" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Info.plist" new file mode 100755 index 0000000..d338c77 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/Info.plist" @@ -0,0 +1,43 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UILaunchStoryboardName + LaunchScreen + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + + UISupportedInterfaceOrientations~ipad + + UIInterfaceOrientationPortrait + UIInterfaceOrientationPortraitUpsideDown + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/ViewController.h" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/ViewController.h" new file mode 100755 index 0000000..aedb0dd --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/ViewController.h" @@ -0,0 +1,15 @@ +// +// ViewController.h +// Calendar +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import +#import "calendarView.h" +@interface ViewController : UIViewController + + +@end + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/ViewController.m" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/ViewController.m" new file mode 100755 index 0000000..43374b5 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/ViewController.m" @@ -0,0 +1,30 @@ +// +// ViewController.m +// Calendar +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import "ViewController.h" + +@interface ViewController () +@property (nonatomic, weak) calendarView* calView; +@end + +@implementation ViewController + +- (void)viewDidLoad { + [super viewDidLoad]; + calendarView *view = [[calendarView alloc] initWithFrame:CGRectMake(0, 0, [[UIScreen mainScreen] bounds].size.width, [[UIScreen mainScreen] bounds].size.height)]; + self.calView = view; + [self.calView setBackgroundColor:[UIColor redColor]]; + [self.view addSubview:self.calView]; +} + +- (void)didReceiveMemoryWarning { + [super didReceiveMemoryWarning]; + +} + +@end diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/calendarView.h" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/calendarView.h" new file mode 100755 index 0000000..39dc5dd --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/calendarView.h" @@ -0,0 +1,13 @@ +// +// calendarView.h +// Calendar +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import +#import +@interface calendarView : UIView + +@end diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/calendarView.m" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/calendarView.m" new file mode 100755 index 0000000..b7bde58 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/calendarView.m" @@ -0,0 +1,222 @@ +// +// calendarView.m +// Calendar +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import "calendarView.h" +#define RowDistance 5 + +@interface calendarView() +@property (nonatomic, strong) NSCalendar *cal; +@property (nonatomic) NSInteger days; +@end + +@implementation calendarView +{ + CGPoint calStart; + NSInteger monthCal[6][7]; +} + +- (instancetype)initWithFrame:(CGRect)frame +{ + if(self = [super initWithFrame:frame]) + { + self.cal = [[NSCalendar alloc] initWithCalendarIdentifier:NSCalendarIdentifierGregorian]; + for(int i=0; i<6; i++) + { + for(int j=0;j<7;j++) + { + monthCal[i][j] = 0; + } + } + } + return self; +} + +- (void)drawRect:(CGRect)rect +{ + [self drawTitle]; + [self setMonthCal]; + UIFont *font = [UIFont systemFontOfSize:15 weight:14]; + NSDictionary* attributes = @{NSFontAttributeName : font}; + NSString *strToBeDraw = [[NSString alloc] init]; + CGSize spaceSize = [@" " sizeWithAttributes:attributes]; + CGFloat fixedX = calStart.x; + for(int i = 0; i < 6; i++) + { + for(int j = 0; j < 7; j++) + { + if(monthCal[i][j] != 0) + { + strToBeDraw = [self getDayString:monthCal[i][j]]; + } + else + { + strToBeDraw = @" "; + } + [strToBeDraw drawAtPoint:calStart withAttributes:attributes]; + calStart.x += spaceSize.width*2; + } + calStart.x = fixedX; + calStart.y += spaceSize.height; + } + +} + +- (void)setMonthCal +{ + NSInteger j = [self getFirstDate] - 1; + NSInteger days = 1; + for(NSInteger i=0;i<6;i++) + { + for(; j<7;j++) + { + if(days <=self.days) + { + monthCal[i][j] = days; + days++; + } + } + j = 0; + } +} + +- (NSString*)getDayString:(NSInteger)day +{ + if(day<10) + { + NSMutableString *str = [NSMutableString stringWithFormat:@" %ld",day]; + return [NSString stringWithString:str]; + } + else + { + return [NSString stringWithFormat:@"%ld",day]; + } +} + +- (void)drawTitle +{ + UIFont *font = [UIFont systemFontOfSize:18 weight:20]; + NSDictionary* attributes = @{NSFontAttributeName : font}; + CGSize textSize = [@"2016" sizeWithAttributes:attributes]; + + UILabel *title = [[UILabel alloc] initWithFrame:CGRectMake(0, 0.25 * self.frame.size.height, self.frame.size.width, textSize.height)]; + title.backgroundColor = [UIColor clearColor]; + title.textColor = [UIColor blackColor]; + title.textAlignment = NSTextAlignmentCenter; + title.text = [self getTitle]; + [self addSubview:title]; + + CGSize calSize = [@"00 00 00 00 00 00 00" sizeWithAttributes:attributes]; + CGPoint startPoint = {(self.frame.size.width - calSize.width) / 2, title.frame.origin.y+title.frame.size.height + RowDistance}; + UILabel *weekTitle = [[UILabel alloc] initWithFrame:CGRectMake(startPoint.x, startPoint.y, calSize.width, calSize.height)]; + weekTitle.backgroundColor = [UIColor clearColor]; + weekTitle.textColor = [UIColor blackColor]; + weekTitle.textAlignment = NSTextAlignmentCenter; + weekTitle.text = @"日 一 二 三 四 五 六"; + [self addSubview:weekTitle]; + + CGFloat y = weekTitle.frame.origin.y; + CGFloat h = weekTitle.frame.size.height; + calStart.x = weekTitle.frame.origin.x+RowDistance*4; + calStart.y = y+h+RowDistance; +} + +- (NSInteger)getFirstDate +{ + NSDate *today = [NSDate date]; + NSInteger month = [self.cal component:NSCalendarUnitMonth fromDate:today]; + NSInteger year = [self.cal component:NSCalendarUnitYear fromDate:today]; + NSDateComponents *component = [[NSDateComponents alloc] init]; + [component setDay:1]; + [component setMonth:month]; + [component setYear:year]; + NSDate *firstDay = [self.cal dateFromComponents:component]; + self.days = [self.cal rangeOfUnit:NSCalendarUnitDay inUnit:NSCalendarUnitMonth forDate:firstDay].length; + NSInteger weekday = [self.cal component:NSCalendarUnitWeekday fromDate:firstDay]; + return weekday; +} + +- (NSString *)getTitle +{ + NSMutableString *title = [[NSMutableString alloc] init]; + NSDate *today = [NSDate date]; + NSInteger month = [self.cal component:NSCalendarUnitMonth fromDate:today]; + NSInteger year = [self.cal component:NSCalendarUnitYear fromDate:today]; + title = [NSMutableString stringWithString:[self convert:month]]; + [title appendString:@" "]; + [title appendString:[NSMutableString stringWithFormat:@"%ld",(long)year]]; + return title; +} + +-(NSString*)convert:(NSInteger) month +{ + NSString *m = [[NSString alloc] init]; + switch (month) { + case 1:{ + m = @"一月"; + break;} + + case 2:{ + m = @"二月"; + break;} + + case 3:{ + m = @"三月"; + break; + } + + case 4:{ + m = @"四月"; + break; + } + + case 5:{ + m = @"五月"; + break; + } + + case 6:{ + m = @"六月"; + break; + } + + case 7:{ + m = @"七月"; + break; + } + + case 8:{ + m = @"八月"; + break; + } + + case 9:{ + m = @"九月"; + break; + } + + case 10:{ + m = @"十月"; + break; + } + + case 11:{ + m = @"十一月"; + break; + } + + case 12:{ + m = @"十二月"; + break; + } + + default: + break; + } + return m; +} +@end diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/main.m" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/main.m" new file mode 100755 index 0000000..c916cca --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/Calendar/main.m" @@ -0,0 +1,16 @@ +// +// main.m +// Calendar +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import +#import "AppDelegate.h" + +int main(int argc, char * argv[]) { + @autoreleasepool { + return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); + } +} diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarTests/CalendarTests.m" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarTests/CalendarTests.m" new file mode 100755 index 0000000..067ed9b --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarTests/CalendarTests.m" @@ -0,0 +1,39 @@ +// +// CalendarTests.m +// CalendarTests +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import + +@interface CalendarTests : XCTestCase + +@end + +@implementation CalendarTests + +- (void)setUp { + [super setUp]; + // Put setup code here. This method is called before the invocation of each test method in the class. +} + +- (void)tearDown { + // Put teardown code here. This method is called after the invocation of each test method in the class. + [super tearDown]; +} + +- (void)testExample { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. +} + +- (void)testPerformanceExample { + // This is an example of a performance test case. + [self measureBlock:^{ + // Put the code you want to measure the time of here. + }]; +} + +@end diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarTests/Info.plist" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarTests/Info.plist" new file mode 100755 index 0000000..ba72822 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarTests/Info.plist" @@ -0,0 +1,24 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1 + + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarUITests/CalendarUITests.m" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarUITests/CalendarUITests.m" new file mode 100755 index 0000000..26ba3fd --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarUITests/CalendarUITests.m" @@ -0,0 +1,40 @@ +// +// CalendarUITests.m +// CalendarUITests +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import + +@interface CalendarUITests : XCTestCase + +@end + +@implementation CalendarUITests + +- (void)setUp { + [super setUp]; + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + self.continueAfterFailure = NO; + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + [[[XCUIApplication alloc] init] launch]; + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. +} + +- (void)tearDown { + // Put teardown code here. This method is called after the invocation of each test method in the class. + [super tearDown]; +} + +- (void)testExample { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. +} + +@end diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarUITests/Info.plist" "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarUITests/Info.plist" new file mode 100755 index 0000000..ba72822 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project02/Calendar/CalendarUITests/Info.plist" @@ -0,0 +1,24 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1 + + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList.xcodeproj/project.pbxproj" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList.xcodeproj/project.pbxproj" new file mode 100755 index 0000000..3829ce3 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList.xcodeproj/project.pbxproj" @@ -0,0 +1,519 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXBuildFile section */ + 5A2193031BE64863008B2BEE /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A2193021BE64863008B2BEE /* main.m */; }; + 5A2193061BE64863008B2BEE /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A2193051BE64863008B2BEE /* AppDelegate.m */; }; + 5A2193091BE64863008B2BEE /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A2193081BE64863008B2BEE /* ViewController.m */; }; + 5A21930C1BE64863008B2BEE /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 5A21930A1BE64863008B2BEE /* Main.storyboard */; }; + 5A21930E1BE64863008B2BEE /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 5A21930D1BE64863008B2BEE /* Assets.xcassets */; }; + 5A2193111BE64863008B2BEE /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 5A21930F1BE64863008B2BEE /* LaunchScreen.storyboard */; }; + 5A21931C1BE64863008B2BEE /* TaskListTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A21931B1BE64863008B2BEE /* TaskListTests.m */; }; + 5A2193271BE64863008B2BEE /* TaskListUITests.m in Sources */ = {isa = PBXBuildFile; fileRef = 5A2193261BE64863008B2BEE /* TaskListUITests.m */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 5A2193181BE64863008B2BEE /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 5A2192F61BE64863008B2BEE /* Project object */; + proxyType = 1; + remoteGlobalIDString = 5A2192FD1BE64863008B2BEE; + remoteInfo = TaskList; + }; + 5A2193231BE64863008B2BEE /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 5A2192F61BE64863008B2BEE /* Project object */; + proxyType = 1; + remoteGlobalIDString = 5A2192FD1BE64863008B2BEE; + remoteInfo = TaskList; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + 5A2192FE1BE64863008B2BEE /* TaskList.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = TaskList.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 5A2193021BE64863008B2BEE /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; }; + 5A2193041BE64863008B2BEE /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; }; + 5A2193051BE64863008B2BEE /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; }; + 5A2193071BE64863008B2BEE /* ViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ViewController.h; sourceTree = ""; }; + 5A2193081BE64863008B2BEE /* ViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ViewController.m; sourceTree = ""; }; + 5A21930B1BE64863008B2BEE /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; }; + 5A21930D1BE64863008B2BEE /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 5A2193101BE64863008B2BEE /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; }; + 5A2193121BE64863008B2BEE /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 5A2193171BE64863008B2BEE /* TaskListTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = TaskListTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 5A21931B1BE64863008B2BEE /* TaskListTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = TaskListTests.m; sourceTree = ""; }; + 5A21931D1BE64863008B2BEE /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; + 5A2193221BE64863008B2BEE /* TaskListUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = TaskListUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 5A2193261BE64863008B2BEE /* TaskListUITests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = TaskListUITests.m; sourceTree = ""; }; + 5A2193281BE64863008B2BEE /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 5A2192FB1BE64863008B2BEE /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 5A2193141BE64863008B2BEE /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 5A21931F1BE64863008B2BEE /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 5A2192F51BE64863008B2BEE = { + isa = PBXGroup; + children = ( + 5A2193001BE64863008B2BEE /* TaskList */, + 5A21931A1BE64863008B2BEE /* TaskListTests */, + 5A2193251BE64863008B2BEE /* TaskListUITests */, + 5A2192FF1BE64863008B2BEE /* Products */, + ); + sourceTree = ""; + }; + 5A2192FF1BE64863008B2BEE /* Products */ = { + isa = PBXGroup; + children = ( + 5A2192FE1BE64863008B2BEE /* TaskList.app */, + 5A2193171BE64863008B2BEE /* TaskListTests.xctest */, + 5A2193221BE64863008B2BEE /* TaskListUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + 5A2193001BE64863008B2BEE /* TaskList */ = { + isa = PBXGroup; + children = ( + 5A2193041BE64863008B2BEE /* AppDelegate.h */, + 5A2193051BE64863008B2BEE /* AppDelegate.m */, + 5A2193071BE64863008B2BEE /* ViewController.h */, + 5A2193081BE64863008B2BEE /* ViewController.m */, + 5A21930A1BE64863008B2BEE /* Main.storyboard */, + 5A21930D1BE64863008B2BEE /* Assets.xcassets */, + 5A21930F1BE64863008B2BEE /* LaunchScreen.storyboard */, + 5A2193121BE64863008B2BEE /* Info.plist */, + 5A2193011BE64863008B2BEE /* Supporting Files */, + ); + path = TaskList; + sourceTree = ""; + }; + 5A2193011BE64863008B2BEE /* Supporting Files */ = { + isa = PBXGroup; + children = ( + 5A2193021BE64863008B2BEE /* main.m */, + ); + name = "Supporting Files"; + sourceTree = ""; + }; + 5A21931A1BE64863008B2BEE /* TaskListTests */ = { + isa = PBXGroup; + children = ( + 5A21931B1BE64863008B2BEE /* TaskListTests.m */, + 5A21931D1BE64863008B2BEE /* Info.plist */, + ); + path = TaskListTests; + sourceTree = ""; + }; + 5A2193251BE64863008B2BEE /* TaskListUITests */ = { + isa = PBXGroup; + children = ( + 5A2193261BE64863008B2BEE /* TaskListUITests.m */, + 5A2193281BE64863008B2BEE /* Info.plist */, + ); + path = TaskListUITests; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 5A2192FD1BE64863008B2BEE /* TaskList */ = { + isa = PBXNativeTarget; + buildConfigurationList = 5A21932B1BE64863008B2BEE /* Build configuration list for PBXNativeTarget "TaskList" */; + buildPhases = ( + 5A2192FA1BE64863008B2BEE /* Sources */, + 5A2192FB1BE64863008B2BEE /* Frameworks */, + 5A2192FC1BE64863008B2BEE /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = TaskList; + productName = TaskList; + productReference = 5A2192FE1BE64863008B2BEE /* TaskList.app */; + productType = "com.apple.product-type.application"; + }; + 5A2193161BE64863008B2BEE /* TaskListTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 5A21932E1BE64863008B2BEE /* Build configuration list for PBXNativeTarget "TaskListTests" */; + buildPhases = ( + 5A2193131BE64863008B2BEE /* Sources */, + 5A2193141BE64863008B2BEE /* Frameworks */, + 5A2193151BE64863008B2BEE /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 5A2193191BE64863008B2BEE /* PBXTargetDependency */, + ); + name = TaskListTests; + productName = TaskListTests; + productReference = 5A2193171BE64863008B2BEE /* TaskListTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + 5A2193211BE64863008B2BEE /* TaskListUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 5A2193311BE64863008B2BEE /* Build configuration list for PBXNativeTarget "TaskListUITests" */; + buildPhases = ( + 5A21931E1BE64863008B2BEE /* Sources */, + 5A21931F1BE64863008B2BEE /* Frameworks */, + 5A2193201BE64863008B2BEE /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 5A2193241BE64863008B2BEE /* PBXTargetDependency */, + ); + name = TaskListUITests; + productName = TaskListUITests; + productReference = 5A2193221BE64863008B2BEE /* TaskListUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 5A2192F61BE64863008B2BEE /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 0700; + ORGANIZATIONNAME = Anglet; + TargetAttributes = { + 5A2192FD1BE64863008B2BEE = { + CreatedOnToolsVersion = 7.0.1; + }; + 5A2193161BE64863008B2BEE = { + CreatedOnToolsVersion = 7.0.1; + TestTargetID = 5A2192FD1BE64863008B2BEE; + }; + 5A2193211BE64863008B2BEE = { + CreatedOnToolsVersion = 7.0.1; + TestTargetID = 5A2192FD1BE64863008B2BEE; + }; + }; + }; + buildConfigurationList = 5A2192F91BE64863008B2BEE /* Build configuration list for PBXProject "TaskList" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 5A2192F51BE64863008B2BEE; + productRefGroup = 5A2192FF1BE64863008B2BEE /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 5A2192FD1BE64863008B2BEE /* TaskList */, + 5A2193161BE64863008B2BEE /* TaskListTests */, + 5A2193211BE64863008B2BEE /* TaskListUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 5A2192FC1BE64863008B2BEE /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 5A2193111BE64863008B2BEE /* LaunchScreen.storyboard in Resources */, + 5A21930E1BE64863008B2BEE /* Assets.xcassets in Resources */, + 5A21930C1BE64863008B2BEE /* Main.storyboard in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 5A2193151BE64863008B2BEE /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 5A2193201BE64863008B2BEE /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 5A2192FA1BE64863008B2BEE /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 5A2193091BE64863008B2BEE /* ViewController.m in Sources */, + 5A2193061BE64863008B2BEE /* AppDelegate.m in Sources */, + 5A2193031BE64863008B2BEE /* main.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 5A2193131BE64863008B2BEE /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 5A21931C1BE64863008B2BEE /* TaskListTests.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 5A21931E1BE64863008B2BEE /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 5A2193271BE64863008B2BEE /* TaskListUITests.m in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 5A2193191BE64863008B2BEE /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 5A2192FD1BE64863008B2BEE /* TaskList */; + targetProxy = 5A2193181BE64863008B2BEE /* PBXContainerItemProxy */; + }; + 5A2193241BE64863008B2BEE /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 5A2192FD1BE64863008B2BEE /* TaskList */; + targetProxy = 5A2193231BE64863008B2BEE /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin PBXVariantGroup section */ + 5A21930A1BE64863008B2BEE /* Main.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 5A21930B1BE64863008B2BEE /* Base */, + ); + name = Main.storyboard; + sourceTree = ""; + }; + 5A21930F1BE64863008B2BEE /* LaunchScreen.storyboard */ = { + isa = PBXVariantGroup; + children = ( + 5A2193101BE64863008B2BEE /* Base */, + ); + name = LaunchScreen.storyboard; + sourceTree = ""; + }; +/* End PBXVariantGroup section */ + +/* Begin XCBuildConfiguration section */ + 5A2193291BE64863008B2BEE /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + }; + name = Debug; + }; + 5A21932A1BE64863008B2BEE /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; + CLANG_CXX_LIBRARY = "libc++"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + GCC_C_LANGUAGE_STANDARD = gnu99; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 9.0; + MTL_ENABLE_DEBUG_INFO = NO; + SDKROOT = iphoneos; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 5A21932C1BE64863008B2BEE /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + INFOPLIST_FILE = TaskList/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = Anglet.TaskList; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Debug; + }; + 5A21932D1BE64863008B2BEE /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + INFOPLIST_FILE = TaskList/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = Anglet.TaskList; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 5A21932F1BE64863008B2BEE /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + INFOPLIST_FILE = TaskListTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = Anglet.TaskListTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/TaskList.app/TaskList"; + }; + name = Debug; + }; + 5A2193301BE64863008B2BEE /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + BUNDLE_LOADER = "$(TEST_HOST)"; + INFOPLIST_FILE = TaskListTests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = Anglet.TaskListTests; + PRODUCT_NAME = "$(TARGET_NAME)"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/TaskList.app/TaskList"; + }; + name = Release; + }; + 5A2193321BE64863008B2BEE /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + INFOPLIST_FILE = TaskListUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = Anglet.TaskListUITests; + PRODUCT_NAME = "$(TARGET_NAME)"; + TEST_TARGET_NAME = TaskList; + USES_XCTRUNNER = YES; + }; + name = Debug; + }; + 5A2193331BE64863008B2BEE /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INFOPLIST_FILE = TaskListUITests/Info.plist; + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks"; + PRODUCT_BUNDLE_IDENTIFIER = Anglet.TaskListUITests; + PRODUCT_NAME = "$(TARGET_NAME)"; + TEST_TARGET_NAME = TaskList; + USES_XCTRUNNER = YES; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 5A2192F91BE64863008B2BEE /* Build configuration list for PBXProject "TaskList" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 5A2193291BE64863008B2BEE /* Debug */, + 5A21932A1BE64863008B2BEE /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 5A21932B1BE64863008B2BEE /* Build configuration list for PBXNativeTarget "TaskList" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 5A21932C1BE64863008B2BEE /* Debug */, + 5A21932D1BE64863008B2BEE /* Release */, + ); + defaultConfigurationIsVisible = 0; + }; + 5A21932E1BE64863008B2BEE /* Build configuration list for PBXNativeTarget "TaskListTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 5A21932F1BE64863008B2BEE /* Debug */, + 5A2193301BE64863008B2BEE /* Release */, + ); + defaultConfigurationIsVisible = 0; + }; + 5A2193311BE64863008B2BEE /* Build configuration list for PBXNativeTarget "TaskListUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 5A2193321BE64863008B2BEE /* Debug */, + 5A2193331BE64863008B2BEE /* Release */, + ); + defaultConfigurationIsVisible = 0; + }; +/* End XCConfigurationList section */ + }; + rootObject = 5A2192F61BE64863008B2BEE /* Project object */; +} diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList.xcodeproj/project.xcworkspace/contents.xcworkspacedata" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList.xcodeproj/project.xcworkspace/contents.xcworkspacedata" new file mode 100755 index 0000000..0024132 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList.xcodeproj/project.xcworkspace/contents.xcworkspacedata" @@ -0,0 +1,7 @@ + + + + + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/AppDelegate.h" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/AppDelegate.h" new file mode 100755 index 0000000..b1c4da5 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/AppDelegate.h" @@ -0,0 +1,26 @@ +// +// AppDelegate.h +// TaskList +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import + +NSString *docPath(void); + +@interface AppDelegate : UIResponder +{ + UITableView *taskTable; + UITextField *taskField; + UIButton *insertButton; + NSMutableArray *tasks; +} + +-(void)addTask:(id)sender; +@property (strong, nonatomic) UIWindow *window; +@property (strong, nonatomic) UIViewController *controller; + +@end + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/AppDelegate.m" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/AppDelegate.m" new file mode 100755 index 0000000..50a9e70 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/AppDelegate.m" @@ -0,0 +1,125 @@ +// +// AppDelegate.m +// TaskList +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + + +#import "AppDelegate.h" +#import "ViewController.h" + +NSString *docPath(){ + NSArray *pathList = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); + return [[pathList objectAtIndex:0]stringByAppendingPathComponent:@"data.txt"]; +} + +@interface AppDelegate () + +@end + +@implementation AppDelegate + + +- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { + // Override point for customization after application launch. + [UIApplication sharedApplication].networkActivityIndicatorVisible = YES; + + NSArray *plist = [NSArray arrayWithContentsOfFile:docPath()]; + if (plist) { + tasks = [plist mutableCopy]; + } else { + tasks = [[NSMutableArray alloc]init]; + } + if ([tasks count] == 0) { + [tasks addObject:@"吃饭"]; + [tasks addObject:@"睡觉"]; + [tasks addObject:@"洗衣服"]; + } + +// + CGRect windowFrame = [[UIScreen mainScreen]bounds]; + self.window = [[UIWindow alloc]initWithFrame:windowFrame]; +// UIWindow *theWindow = [[UIWindow alloc]initWithFrame:windowFrame]; +// [self setWindow:theWindow]; +// theWindow.rootViewController = [[ViewController alloc]init]; + self.controller = [[ViewController alloc]init]; + self.window.rootViewController = self.controller; + + CGRect tableFrame = CGRectMake(0, 80, 320, 380); + CGRect fieldFrame = CGRectMake(20, 40, 200, 31); + CGRect buttonFrame = CGRectMake(228, 40, 72, 31); + + taskTable = [[UITableView alloc]initWithFrame:tableFrame style:UITableViewStylePlain]; + [taskTable setSeparatorStyle:UITableViewCellSeparatorStyleNone]; + [taskTable setDataSource:self]; + + taskField = [[UITextField alloc]initWithFrame:fieldFrame]; + [taskField setBorderStyle:UITextBorderStyleRoundedRect]; + [taskField setPlaceholder:@"请输入任务"]; + + insertButton = [UIButton buttonWithType:UIButtonTypeRoundedRect]; + [insertButton setFrame:buttonFrame]; + [insertButton setTitle:@"添加" forState:UIControlStateNormal]; + [insertButton addTarget:self action:@selector(addTask:) forControlEvents:UIControlEventTouchUpInside]; + + [[[self controller] view]addSubview:taskTable]; + [[[self controller] view]addSubview:taskField]; + [[[self controller] view]addSubview:insertButton]; + + [[self window]setBackgroundColor:[UIColor whiteColor]]; + [[self window]makeKeyAndVisible]; + + return YES; +} + +- (void)applicationWillResignActive:(UIApplication *)application { + // 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. + // 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. +} + +- (void)applicationDidEnterBackground:(UIApplication *)application { + // 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. + // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits. + [tasks writeToFile:docPath() atomically:YES]; +} + +- (void)applicationWillEnterForeground:(UIApplication *)application { + // 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. +} + +- (void)applicationDidBecomeActive:(UIApplication *)application { + // 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. +} + +- (void)applicationWillTerminate:(UIApplication *)application { + // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:. +} + +- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { + return [tasks count]; +} + +- (UITableViewCell*)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { + UITableViewCell *cell = [taskTable dequeueReusableCellWithIdentifier:@"Cell"]; + if (!cell) { + cell = [[UITableViewCell alloc]initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"Cell"]; + } + NSString *item = [tasks objectAtIndex:[indexPath row]]; + [[cell textLabel]setText:item]; + return cell; +} + +- (void)addTask:(id)sender { + NSString *text = [taskField text]; + if ([text isEqualToString:@""]) { + return; + } + [tasks addObject:text]; + [taskTable reloadData]; + [taskField setText:@""]; + [taskField resignFirstResponder]; +} + +@end diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Assets.xcassets/AppIcon.appiconset/Contents.json" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Assets.xcassets/AppIcon.appiconset/Contents.json" new file mode 100755 index 0000000..118c98f --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Assets.xcassets/AppIcon.appiconset/Contents.json" @@ -0,0 +1,38 @@ +{ + "images" : [ + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "29x29", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "40x40", + "scale" : "3x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "2x" + }, + { + "idiom" : "iphone", + "size" : "60x60", + "scale" : "3x" + } + ], + "info" : { + "version" : 1, + "author" : "xcode" + } +} \ No newline at end of file diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Base.lproj/LaunchScreen.storyboard" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Base.lproj/LaunchScreen.storyboard" new file mode 100755 index 0000000..ad296b4 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Base.lproj/LaunchScreen.storyboard" @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Base.lproj/Main.storyboard" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Base.lproj/Main.storyboard" new file mode 100755 index 0000000..f93063b --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Base.lproj/Main.storyboard" @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Info.plist" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Info.plist" new file mode 100755 index 0000000..fb4115c --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/Info.plist" @@ -0,0 +1,36 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1 + LSRequiresIPhoneOS + + UIRequiredDeviceCapabilities + + armv7 + + UISupportedInterfaceOrientations + + UIInterfaceOrientationPortrait + UIInterfaceOrientationLandscapeLeft + UIInterfaceOrientationLandscapeRight + + + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/ViewController.h" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/ViewController.h" new file mode 100755 index 0000000..efa1fff --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/ViewController.h" @@ -0,0 +1,20 @@ +// +// ViewController.h +// TaskList +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + + +#import + +@interface ViewController : UIViewController{ + UITableView *taskTable; + UITextField *taskField; + UIButton *insertButton; +} + + +@end + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/ViewController.m" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/ViewController.m" new file mode 100755 index 0000000..4e2c8b4 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/ViewController.m" @@ -0,0 +1,28 @@ +// +// ViewController.m +// TaskList +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + + +#import "ViewController.h" + +@interface ViewController () + +@end + +@implementation ViewController + +- (void)viewDidLoad { + [super viewDidLoad]; + // Do any additional setup after loading the view, typically from a nib. +} + +- (void)didReceiveMemoryWarning { + [super didReceiveMemoryWarning]; + // Dispose of any resources that can be recreated. +} + +@end diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/main.m" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/main.m" new file mode 100755 index 0000000..6321b7b --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskList/main.m" @@ -0,0 +1,20 @@ +// +// main.m +// TaskList +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + + +#import +#import "AppDelegate.h" + + +int main(int argc, char * argv[]) { + + + @autoreleasepool { + return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); + } +} diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListTests/Info.plist" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListTests/Info.plist" new file mode 100755 index 0000000..ba72822 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListTests/Info.plist" @@ -0,0 +1,24 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1 + + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListTests/TaskListTests.m" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListTests/TaskListTests.m" new file mode 100755 index 0000000..0105121 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListTests/TaskListTests.m" @@ -0,0 +1,40 @@ +// +// TaskListTests.m +// TaskListTests +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + + +#import + +@interface TaskListTests : XCTestCase + +@end + +@implementation TaskListTests + +- (void)setUp { + [super setUp]; + // Put setup code here. This method is called before the invocation of each test method in the class. +} + +- (void)tearDown { + // Put teardown code here. This method is called after the invocation of each test method in the class. + [super tearDown]; +} + +- (void)testExample { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. +} + +- (void)testPerformanceExample { + // This is an example of a performance test case. + [self measureBlock:^{ + // Put the code you want to measure the time of here. + }]; +} + +@end diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListUITests/Info.plist" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListUITests/Info.plist" new file mode 100755 index 0000000..ba72822 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListUITests/Info.plist" @@ -0,0 +1,24 @@ + + + + + CFBundleDevelopmentRegion + en + CFBundleExecutable + $(EXECUTABLE_NAME) + CFBundleIdentifier + $(PRODUCT_BUNDLE_IDENTIFIER) + CFBundleInfoDictionaryVersion + 6.0 + CFBundleName + $(PRODUCT_NAME) + CFBundlePackageType + BNDL + CFBundleShortVersionString + 1.0 + CFBundleSignature + ???? + CFBundleVersion + 1 + + diff --git "a/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListUITests/TaskListUITests.m" "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListUITests/TaskListUITests.m" new file mode 100755 index 0000000..3b1cea9 --- /dev/null +++ "b/21651118\347\216\213\346\265\267\345\267\236/project03/TaskList/TaskListUITests/TaskListUITests.m" @@ -0,0 +1,40 @@ +// +// TaskListUITests.m +// TaskListUITests +// +// Created by Envaka on 16/10/26. +// Copyright © 2016年 Envaka. All rights reserved. +// + +#import + +@interface TaskListUITests : XCTestCase + +@end + +@implementation TaskListUITests + +- (void)setUp { + [super setUp]; + + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + self.continueAfterFailure = NO; + // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method. + [[[XCUIApplication alloc] init] launch]; + + // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this. +} + +- (void)tearDown { + // Put teardown code here. This method is called after the invocation of each test method in the class. + [super tearDown]; +} + +- (void)testExample { + // Use recording to get started writing UI tests. + // Use XCTAssert and related functions to verify your tests produce the correct results. +} + +@end