diff --git a/doc/iOS_install.md b/doc/iOS_install.md index 8d5582b..83bc997 100644 --- a/doc/iOS_install.md +++ b/doc/iOS_install.md @@ -1,27 +1,29 @@ ## iOS 手动安装 -不建议使用手动安装,请参照 README.md 进行自动安装。 +> **不建议使用手动安装,请参照 README.md 进行自动安装。** + + 1. 下载 JPush PhoneGap Plugin 插件,并解压 2. 将 [/src/ios](/src/ios) 文件夹及内容在 xcode 中拖到你的工程里,并配置 [/src/ios/PushConfig.plist](/src/ios/PushConfig.plist) 中相应参数: - Appkey: 应用标识 - Channel: 渠道标识 - IsProduction:是否生产环境 - IsIDFA: 是否使用 IDFA 启动 sdk + Appkey: 应用标识 + Channel: 渠道标识 + IsProduction:是否生产环境 + IsIDFA: 是否使用 IDFA 启动 sdk 3. 打开 xcode,点击工程目录中顶部的 工程,选择(Target -> Build Phases -> Link Binary With Libraries),添加以下框架: - CFNetwork.framework - CoreFoundation.framework - CoreTelephony.framework - SystemConfiguration.framework - CoreGraphics.framework - Foundation.framework - UIKit.framework - AdSupport.framework - libz.tbd(若存在 libz.dylib 则替换为 libz.tbd) - UserNotifications.framework - libresolv.tbd + CFNetwork.framework + CoreFoundation.framework + CoreTelephony.framework + SystemConfiguration.framework + CoreGraphics.framework + Foundation.framework + UIKit.framework + AdSupport.framework + libz.tbd(若存在 libz.dylib 则替换为 libz.tbd) + UserNotifications.framework + libresolv.tbd 4. 修改 phonegap config.xml 文件以添加 JPushPlugin 插件 ```xml diff --git a/plugin.xml b/plugin.xml index ba51f47..05e1464 100644 --- a/plugin.xml +++ b/plugin.xml @@ -30,14 +30,17 @@ + - + - + + + diff --git a/src/ios/lib/JPUSHService.h b/src/ios/lib/JPUSHService.h index e5424a3..13cb9d4 100644 --- a/src/ios/lib/JPUSHService.h +++ b/src/ios/lib/JPUSHService.h @@ -9,7 +9,7 @@ * Copyright (c) 2011 ~ 2015 Shenzhen HXHG. All rights reserved. */ -#define JPUSH_VERSION_NUMBER 2.2.0 +#define JPUSH_VERSION_NUMBER 3.0.0 #import @@ -31,6 +31,13 @@ extern NSString *const kJPFNetworkDidLoginNotification; // 登录成功 extern NSString *const kJPFNetworkDidReceiveMessageNotification; // 收到消息(非APNS) extern NSString *const kJPFServiceErrorNotification; // 错误提示 +typedef NS_OPTIONS(NSUInteger, JPAuthorizationOptions) { + JPAuthorizationOptionNone = 0, // the application may not present any UI upon a notification being received + JPAuthorizationOptionBadge = (1 << 0), // the application may badge its icon upon a notification being received + JPAuthorizationOptionSound = (1 << 1), // the application may play a sound upon a notification being received + JPAuthorizationOptionAlert = (1 << 2), // the application may display an alert upon a notification being received +}; + /*! * 通知注册实体类 */ @@ -186,7 +193,7 @@ extern NSString *const kJPFServiceErrorNotification; // 错误提示 /*! * 下面的接口是可选的 - * 设置标签和(或)别名(若参数为nil,则忽略;若是空对象,则清空;详情请参考文档:http://docs.jiguang.cn/client/ios_api/#api-ios) + * 设置标签和(或)别名(若参数为nil,则忽略;若是空对象,则清空;详情请参考文档:https://docs.jiguang.cn/jpush/client/iOS/ios_api/) * setTags:alias:fetchCompletionHandle:是新的设置标签别名的方法,不再需要显示声明回调函数,只需要在block里面处理设置结果即可. * WARN: 使用block时需要注意循环引用问题 */ @@ -243,7 +250,7 @@ callbackSelector:(SEL)cbSelector + (void)stopLogPageView:(NSString *)pageName; /*! - * @abstract 直接上报在页面的停留时工 + * @abstract 直接上报在页面的停留时间 * * @param pageName 页面 * @param seconds 停留的秒数 @@ -364,7 +371,6 @@ callbackSelector:(SEL)cbSelector * @abstract 删除本地推送定义 * * @param notificationKey 本地推送标示符 - * @param myUILocalNotification 本地推送对象 * @discussion 此方法被[removeNotification:]方法取代 */ + (void)deleteLocalNotificationWithIdentifierKey:(NSString *)notificationKey __attribute__((deprecated("JPush 2.1.9 版本已过期"))); diff --git a/src/ios/lib/jpush-ios-2.2.0.a b/src/ios/lib/jcore-ios-1.0.0.a similarity index 59% rename from src/ios/lib/jpush-ios-2.2.0.a rename to src/ios/lib/jcore-ios-1.0.0.a index 9e48b2d..dfc687d 100644 Binary files a/src/ios/lib/jpush-ios-2.2.0.a and b/src/ios/lib/jcore-ios-1.0.0.a differ diff --git a/src/ios/lib/jpush-ios-3.0.0.a b/src/ios/lib/jpush-ios-3.0.0.a new file mode 100644 index 0000000..74f2dc9 Binary files /dev/null and b/src/ios/lib/jpush-ios-3.0.0.a differ