From b9e8931ab0673e4ea837a264d0ab867b3f06467c Mon Sep 17 00:00:00 2001 From: Ryan Lepinski Date: Wed, 7 Sep 2016 14:34:41 -0700 Subject: [PATCH] Release SDK 8.0.0 (#1084) --- .../AirshipKit.xcodeproj/project.pbxproj | 8 +- .../AirshipLib.xcodeproj/project.pbxproj | 10 +- .../xcschemes/AirshipLib.xcscheme | 4 +- AirshipLib/Config.xcconfig | 6 +- CHANGELOG | 41 +----- README.md | 125 +++--------------- scripts/configure_xcode_version.sh | 3 +- 7 files changed, 40 insertions(+), 157 deletions(-) diff --git a/AirshipKit/AirshipKit.xcodeproj/project.pbxproj b/AirshipKit/AirshipKit.xcodeproj/project.pbxproj index 33f228497..0bd7b1c6f 100644 --- a/AirshipKit/AirshipKit.xcodeproj/project.pbxproj +++ b/AirshipKit/AirshipKit.xcodeproj/project.pbxproj @@ -13,7 +13,7 @@ 494DD95D1B0EB677009C134E /* AirshipKit.h in Headers */ = {isa = PBXBuildFile; fileRef = 494DD95C1B0EB677009C134E /* AirshipKit.h */; settings = {ATTRIBUTES = (Public, ); }; }; 494DDC261B0FD6A1009C134E /* libsqlite3.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 494DDC251B0FD6A1009C134E /* libsqlite3.dylib */; }; 494DDC281B0FD6A6009C134E /* libz.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 494DDC271B0FD6A6009C134E /* libz.dylib */; }; - 49D5281D1B17DFE7006E35FB /* libUAirship-8.0.0.dp4.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 49D5281C1B17DFE7006E35FB /* libUAirship-8.0.0.dp4.a */; }; + 49D5281D1B17DFE7006E35FB /* libUAirship-8.0.0.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 49D5281C1B17DFE7006E35FB /* libUAirship-8.0.0.a */; }; /* End PBXBuildFile section */ /* Begin PBXFileReference section */ @@ -25,7 +25,7 @@ 494DD95C1B0EB677009C134E /* AirshipKit.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AirshipKit.h; sourceTree = ""; }; 494DDC251B0FD6A1009C134E /* libsqlite3.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libsqlite3.dylib; path = usr/lib/libsqlite3.dylib; sourceTree = SDKROOT; }; 494DDC271B0FD6A6009C134E /* libz.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libz.dylib; path = usr/lib/libz.dylib; sourceTree = SDKROOT; }; - 49D5281C1B17DFE7006E35FB /* libUAirship-8.0.0.dp4.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = "libUAirship-8.0.0.dp4.a"; path = "../Airship/libUAirship-8.0.0.dp4.a"; sourceTree = ""; }; + 49D5281C1B17DFE7006E35FB /* libUAirship-8.0.0.a */ = {isa = PBXFileReference; lastKnownFileType = archive.ar; name = "libUAirship-8.0.0.a"; path = "../Airship/libUAirship-8.0.0.a"; sourceTree = ""; }; /* End PBXFileReference section */ /* Begin PBXFrameworksBuildPhase section */ @@ -35,7 +35,7 @@ files = ( 494DDC281B0FD6A6009C134E /* libz.dylib in Frameworks */, 494DDC261B0FD6A1009C134E /* libsqlite3.dylib in Frameworks */, - 49D5281D1B17DFE7006E35FB /* libUAirship-8.0.0.dp4.a in Frameworks */, + 49D5281D1B17DFE7006E35FB /* libUAirship-8.0.0.a in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -46,7 +46,7 @@ isa = PBXGroup; children = ( 492051421C0D176400A7B36D /* AirshipResources.bundle */, - 49D5281C1B17DFE7006E35FB /* libUAirship-8.0.0.dp4.a */, + 49D5281C1B17DFE7006E35FB /* libUAirship-8.0.0.a */, 494DDC271B0FD6A6009C134E /* libz.dylib */, 494DDC251B0FD6A1009C134E /* libsqlite3.dylib */, 494DD9591B0EB677009C134E /* AirshipKit */, diff --git a/AirshipLib/AirshipLib.xcodeproj/project.pbxproj b/AirshipLib/AirshipLib.xcodeproj/project.pbxproj index 2f345afa7..87348d216 100644 --- a/AirshipLib/AirshipLib.xcodeproj/project.pbxproj +++ b/AirshipLib/AirshipLib.xcodeproj/project.pbxproj @@ -7,7 +7,7 @@ objects = { /* Begin PBXBuildFile section */ - 1F4230C016C09876004B52C1 /* libUAirship-8.0.0.dp4.a in Frameworks */ = {isa = PBXBuildFile; fileRef = BB88612C159A7E9600584445 /* libUAirship-8.0.0.dp4.a */; }; + 1F4230C016C09876004B52C1 /* libUAirship-8.0.0.a in Frameworks */ = {isa = PBXBuildFile; fileRef = BB88612C159A7E9600584445 /* libUAirship-8.0.0.a */; }; 1F4EDB3C1831839A00F77343 /* UAAction+Internal.h in Headers */ = {isa = PBXBuildFile; fileRef = 4995C62217FA3D71004F8724 /* UAAction+Internal.h */; }; 1F55FB6D181A34DD002AA192 /* UABeveledLoadingIndicator.h in Headers */ = {isa = PBXBuildFile; fileRef = 1F55FB6B181A34DD002AA192 /* UABeveledLoadingIndicator.h */; }; 1F55FB6F181A34DD002AA192 /* UABeveledLoadingIndicator.m in Sources */ = {isa = PBXBuildFile; fileRef = 1F55FB6C181A34DD002AA192 /* UABeveledLoadingIndicator.m */; }; @@ -704,7 +704,7 @@ B69DB4C812533B280037AF7F /* UA_Base64.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = UA_Base64.h; sourceTree = ""; }; B69DB4C912533B280037AF7F /* UA_Base64.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UA_Base64.m; sourceTree = ""; }; BB13C4241575706100541EF3 /* UABase64Test.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = UABase64Test.m; sourceTree = ""; }; - BB88612C159A7E9600584445 /* libUAirship-8.0.0.dp4.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libUAirship-8.0.0.dp4.a"; sourceTree = BUILT_PRODUCTS_DIR; }; + BB88612C159A7E9600584445 /* libUAirship-8.0.0.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libUAirship-8.0.0.a"; sourceTree = BUILT_PRODUCTS_DIR; }; BB926B3C1540D1D000003975 /* UAAnalytics+Internal.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UAAnalytics+Internal.h"; sourceTree = ""; }; BBB87D661505758100971CEC /* CoreLocation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreLocation.framework; path = System/Library/Frameworks/CoreLocation.framework; sourceTree = SDKROOT; }; BBB87E0B15057C7F00971CEC /* UALocationEvent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; lineEnding = 0; path = UALocationEvent.h; sourceTree = ""; xcLanguageSpecificationIdentifier = xcode.lang.objcpp; }; @@ -945,7 +945,7 @@ 49C6721E1857CE840088F210 /* JavaScriptCore.framework in Frameworks */, 760D14BA17C2C9E600BBE6E6 /* XCTest.framework in Frameworks */, CC523FC317BA8AC200233005 /* CoreData.framework in Frameworks */, - 1F4230C016C09876004B52C1 /* libUAirship-8.0.0.dp4.a in Frameworks */, + 1F4230C016C09876004B52C1 /* libUAirship-8.0.0.a in Frameworks */, BBB87E5115057EEA00971CEC /* libOCMock.a in Frameworks */, BBB87E4F15057EC400971CEC /* CoreLocation.framework in Frameworks */, 7B909D431429363300D0AB36 /* Security.framework in Frameworks */, @@ -976,7 +976,7 @@ isa = PBXGroup; children = ( 7BB679061429288D00B877DB /* AirshipLogicTests.xctest */, - BB88612C159A7E9600584445 /* libUAirship-8.0.0.dp4.a */, + BB88612C159A7E9600584445 /* libUAirship-8.0.0.a */, 4920512C1C0D0C0A00A7B36D /* AirshipResources.bundle */, ); name = Products; @@ -2100,7 +2100,7 @@ ); name = AirshipLib; productName = AirshipLib; - productReference = BB88612C159A7E9600584445 /* libUAirship-8.0.0.dp4.a */; + productReference = BB88612C159A7E9600584445 /* libUAirship-8.0.0.a */; productType = "com.apple.product-type.library.static"; }; /* End PBXNativeTarget section */ diff --git a/AirshipLib/AirshipLib.xcodeproj/xcshareddata/xcschemes/AirshipLib.xcscheme b/AirshipLib/AirshipLib.xcodeproj/xcshareddata/xcschemes/AirshipLib.xcscheme index 588c9a879..b49b6e64f 100644 --- a/AirshipLib/AirshipLib.xcodeproj/xcshareddata/xcschemes/AirshipLib.xcscheme +++ b/AirshipLib/AirshipLib.xcodeproj/xcshareddata/xcschemes/AirshipLib.xcscheme @@ -15,7 +15,7 @@ @@ -66,7 +66,7 @@ diff --git a/AirshipLib/Config.xcconfig b/AirshipLib/Config.xcconfig index 740d60e6f..845f66ada 100644 --- a/AirshipLib/Config.xcconfig +++ b/AirshipLib/Config.xcconfig @@ -21,10 +21,10 @@ // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE // OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF // ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// -CURRENT_PROJECT_VERSION = 8.0.0.dp4 +// +CURRENT_PROJECT_VERSION = 8.0.0 RELEASE_OTHER_CFLAGS = $(inherited) -fembed-bitcode // Uncomment to include the preview build warning -OTHER_CFLAGS = $(inherited) -DUA_PREVIEW=1 +// OTHER_CFLAGS = $(inherited) -DUA_PREVIEW=1 diff --git a/CHANGELOG b/CHANGELOG index 6be609a5f..6eeaa8c6d 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -3,46 +3,19 @@ iOS Changelog Migration Guide: http://docs.urbanairship.com/topic_guides/ios_migration.html. -Version 8.0.0 Developer Previews +Version 8.0.0 - September 7, 2016 ================================= -THIS URBAN AIRSHIP SDK IS RELEASED AS A DEVELOPER PREVIEW VERSION AND MAY CONTAIN BUGS, -ERRORS, DEFECTS, HARMFUL COMPONENTS AND MAY NOT BE COMPATIBLE WITH THE FINAL VERSION OF -THE APPLICABLE THIRD PARTY OPERATING SYSTEM. ACCORDINGLY, URBAN AIRSHIP IS PROVIDING -THE LICENSE ON AN “AS IS” BASIS AND NOT FOR USE IN PRODUCTION. - -Preview 4 - September 2, 2016 ------------------------------ -- Fixed default foreground presentation options sometimes defaulting to displaying an alert. -- Fixed compiler warnings. -- Fixed SwiftSample's UAPushNotificationDelegate implementation. +- iOS 10 compatible release. +- Dropped support for iOS 7. - Removed deprecated APIs from 7.x. - -Preview 3 - August 26, 2016 ---------------------------- -- Added support for media attachments. Requires applications to provide a notification extension. +- Added support for media attachments. Requires applications to provide a notification extension that + extends the class `UAMediaAttachmentExtension` that is provided in the AirshipAppExtensions.framework. - UAPushNotificationDelegate has been rewritten to be more aligned with iOS 10. - Manual application integration methods have been moved to UAAppIntegration. - -Preview 2 - August 2, 2016 --------------------------- +- Added foreground presentation flag (UAActionMetadataForegroundPresentationKey) to action arguments + when running actions in situation UASituationForegroundPush - Added support for foreground presentation options. Default options can be set on UAPush, or per notification with presentationOptionsForNotification: method on the UAPushNotificationDelegate. -- Added foreground presentation flag (UAActionMetadataForegroundPresentationKey) to action arguments - when running actions in situation UASituationForegroundPush. -- UAAutoAppDelegate no longer replaces the UNNotificationDelegate, instead it will either set - a delegate if one is not already set or swizzle the existing delegate. -- Updated to build with Xcode 8 beta 4. - -Preview 1 - July 6, 2016 ------------------------- -- First iOS 10 compatibility release. -- Added support for new UNNotification classes. -- New simplified location module. Previous location module has been deprecated and will be removed in a future developer preview. -- Fixed Channel Capture for iOS 10 devices. -- Updated SwiftSample to Swift 3.0. - -Developer preview APIs may not be final. Please see the README.md for migration guide -and known issues. Version 7.3.0 - August 31, 2016 =============================== diff --git a/README.md b/README.md index 0c067c078..e3c0154bb 100644 --- a/README.md +++ b/README.md @@ -1,108 +1,4 @@ -# iOS 10 Urban Airship Developer Preview Release - -THIS URBAN AIRSHIP SDK IS RELEASED AS A DEVELOPER PREVIEW VERSION AND MAY CONTAIN BUGS, -ERRORS, DEFECTS, HARMFUL COMPONENTS AND MAY NOT BE COMPATIBLE WITH THE FINAL VERSION OF -THE APPLICABLE THIRD PARTY OPERATING SYSTEM. ACCORDINGLY, URBAN AIRSHIP IS PROVIDING -THE LICENSE ON AN “AS IS” BASIS AND NOT FOR USE IN PRODUCTION. - -## Developer Preview Migration Guide - -### SDK 8.0.0 DP 1 to 8.0.0 DP 3 - -#### Package changes - -In order to take advantage of iOS 10 notification attachments, you will need to create a notification service extension -alongside your main application. Most of the work is already done for you, but since this involves creating a new target there -are a few additional steps: - -* Create a new iOS target in Xcode and select the "Notification Service Extension" type -* Drag the new AirshipAppExtensions.framework into your app project -* Link against AirshipAppExtensions.framework in your extension's Build Phases -* Add a Copy Files phase for AirshipAppExtensions.framework and select "Frameworks" as the destination -* Delete all dummy source code for your new extension -* Import `` if using Objective-C, or `AirshipAppExtensions` if using Swift, in `NotificationService` -* Inherit from `UAMediaAttachmentExtension` in `NotificationService` - -For a concrete example see the SampleServiceExtension bundled with the Sample and SwiftSample applications provided in this distribution. - - -#### Application Integration Changes - -All application integration points have been moved to `UAAppIntegration`. If your application disabled -automatic integration, it will need to be updated to call the new methods: - -UIApplicationDelegate methods: -```obj-c -+ (void)application:(UIApplication *)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken; -+ (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo fetchCompletionHandler:(void (^)(UIBackgroundFetchResult))completionHandler; -+ (void)application:(UIApplication *)application didRegisterUserNotificationSettings:(UIUserNotificationSettings *)notificationSettings; -+ (void)application:(UIApplication *)application handleActionWithIdentifier:(NSString *)identifier forRemoteNotification:(NSDictionary *)userInfo completionHandler:(void (^)())handler; -``` - -UNUserNotificationDelegate methods: -```obj-c -+ (void)userNotificationCenter:(UNUserNotificationCenter *)center - didReceiveNotificationResponse:(UNNotificationResponse *)response - withCompletionHandler:(void(^)())completionHandler; -+ (void)userNotificationCenter:(UNUserNotificationCenter *)center - willPresentNotification:(UNNotification *)notification - withCompletionHandler:(void (^)(UNNotificationPresentationOptions options))completionHandler; -``` - -#### UAPush Changes - -The property `launchNotification` has been replaced with `launchNotificationResponse` and will contain a `UANotificationResponse`. - -#### UAPushNotificationDelegate Changes - -The UAPushNotificationDelegate has been rewritten to be more inline with iOS 10. The following methods are provided: - -```obj-c --(void)receivedForegroundNotification:(UANotificationContent *)notificationContent completionHandler:(void (^)())completionHandler; --(void)receivedBackgroundNotification:(UANotificationContent *)notificationContent completionHandler:(void (^)(UIBackgroundFetchResult))completionHandler; --(void)receivedNotificationResponse:(UANotificationResponse *)notificationResponse completionHandler:(void (^)())completionHandler; -- (UNNotificationPresentationOptions)presentationOptionsForNotification:(UNNotification *)notification; -``` - -All methods are backwards compatible with iOS 8 & 9, with the exception of `presentationOptionsForNotification`. - - - - -### SDK 7.2.0 to 8.0.0 DP 1 - -#### Integration Changes - -Auto integration now automatically swizzles and sets the UNNotificationCenter delegate. Applications can -still set a delegate on UNNotificationCenter without conflicting with Urban Airship. If automatic -integration is disabled, UAPush needs to be either set as the UNNotificationCenter delegate or -the application must forward calls to UAPush. - -#### Push Changes - -Notification categories and types have been removed. Instead you can set UANotificationOptions -and UANotificationCategory and the SDK will automatically convert the properties to the -appropriate types depending on the OS version. - -```obj-c - // Old - - (UIUserNotificationType)currentEnabledNotificationTypes; - @property (nonatomic, assign) UIUserNotificationType userNotificationTypes; - @property (nonatomic, strong) NSSet *userNotificationCategories; -``` - -```obj-c - // New - @property (nonatomic, assign) UANotificationOptions notificationOptions; - @property (nonatomic, assign, readonly) UANotificationOptions authorizedNotificationOptions; - @property (nonatomic, strong) NSSet customCategories; -```` - -#### Location Changes - -The old location module has been deprecated and will be removed in the next preview. A new simplified location module has been added -and can be accessed directly from UAirship - [UAirship location]. The new location module only supports significant location change and -contains a simplified interface to disable/enable location updates and allow location to update in the background. +# iOS Urban Airship Library ## Overview @@ -124,9 +20,9 @@ reporting for applications using interactive notifications. - Background refresh always appears to be enabled in an application even when disabled in settings and background push will not be delivered. Push registration will consider a device in this situation able to receive a background notification when it cannot. (Radar #18298439) -- Registering for UIUserNotificationTypeNone will prevent a re-registration until the device +- **Resolved in iOS 10** Registering for UIUserNotificationTypeNone will prevent a re-registration until the device has been restarted and the settings are manually updated in Settings.app. There is a -workaround for this issue in UA SDK 5.0.0. (Radar #17878212) +workaround for this issue in UA SDK 5.0.0. (Radar #17878212). - **Resolved in iOS 9** The boolean properties on UIUserNotificationAction are mutated in the UIUserNotificationCategory isEqual: method, so the authorizationRequired and destructive properties on an action may receive values from actions in other categories @@ -141,7 +37,7 @@ or authorization required status (Radar #18385104). ## Quickstart -Xcode 6.4+ is required for all projects and the static library. Projects must target >= iOS6. +Xcode 8.0+ is required for all projects and the static library. Projects must target >= iOS8. [Download](https://bintray.com/urbanairship/iOS/urbanairship-sdk/_latestVersion) and unzip the latest version of libUAirship. If you are using one of our sample projects, copy the ``Airship`` directory @@ -185,6 +81,19 @@ library>/libUAirship-.a` may be used in instances where using the -ObjC - Add the bridging header located in Airship/UI, named "UA-UI-Bridging-Header.h" to use the sample UI. +### Notification Service Extension +In order to take advantage of iOS 10 notification attachments, you will need to create a notification service extension +alongside your main application. Most of the work is already done for you, but since this involves creating a new target there +are a few additional steps: + +* Create a new iOS target in Xcode and select the "Notification Service Extension" type +* Drag the new AirshipAppExtensions.framework into your app project +* Link against AirshipAppExtensions.framework in your extension's Build Phases +* Add a Copy Files phase for AirshipAppExtensions.framework and select "Frameworks" as the destination +* Delete all dummy source code for your new extension +* Import `` if using Objective-C, or `AirshipAppExtensions` if using Swift, in `NotificationService` +* Inherit from `UAMediaAttachmentExtension` in `NotificationService` + #### Adding an Airship Config File The library uses a .plist configuration file named `AirshipConfig.plist` to manage your production and development diff --git a/scripts/configure_xcode_version.sh b/scripts/configure_xcode_version.sh index 9263fe49e..f3f368eba 100755 --- a/scripts/configure_xcode_version.sh +++ b/scripts/configure_xcode_version.sh @@ -16,6 +16,7 @@ # XCODE_7_1_1_APP # XCODE_7_2_APP # XCODE_8_BETA_APP +# XCODE_8_GM_APP @@ -25,7 +26,7 @@ # export XCODE_5_1_1_APP=/Applications/Xcode-5.1.1.app # export XCODE_6_BETA_5_APP=/Applications/Xcode6-Beta5.app -XCODE_APP=$XCODE_8_BETA_APP +XCODE_APP=$XCODE_8_GM_APP # Destination for tests TEST_DESTINATION='platform=iOS Simulator,OS=latest,name=iPhone SE'