This repository was archived by the owner on Feb 7, 2019. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +14
-14
lines changed
app/App_Resources/Android
native-src/ios/PushPlugin Expand file tree Collapse file tree 3 files changed +14
-14
lines changed Original file line number Diff line number Diff line change 11
11
android:xlargeScreens=" true" />
12
12
13
13
<uses-sdk
14
- android:minSdkVersion=" 17 "
14
+ android:minSdkVersion=" 19 "
15
15
android:targetSdkVersion=" __APILEVEL__" />
16
16
17
17
<uses-permission android : name =" android.permission.READ_EXTERNAL_STORAGE" />
Original file line number Diff line number Diff line change 29
29
"nativescript-dev-typescript" : " ~0.6.0" ,
30
30
"nativescript-dev-webpack" : " ~0.14.0" ,
31
31
"tslint" : " ^5.8.0" ,
32
- "typescript" : " ~2.7.2 "
32
+ "typescript" : " ~2.8.1 "
33
33
},
34
34
"scripts" : {
35
35
"build.plugin" : " cd ../src && npm run build" ,
Original file line number Diff line number Diff line change @@ -143,18 +143,18 @@ - (void)my_application:(UIApplication *)application didReceiveRemoteNotification
143
143
}
144
144
NSLog (@" didReceiveNotification" );
145
145
146
- UIApplicationState appState = UIApplicationStateActive;
147
- if ([application respondsToSelector: @selector (applicationState )]) {
148
- appState = application.applicationState ;
149
- }
150
-
151
- if (appState == UIApplicationStateActive) {
152
- [Push sharedInstance ].notificationMessage = userInfo;
153
- [Push sharedInstance ].isInline = YES ;
154
- [[Push sharedInstance ] notificationReceived ];
155
- } else {
156
- [Push sharedInstance ].launchNotification = userInfo;
157
- }
146
+ UIApplicationState appState = UIApplicationStateActive;
147
+ if ([application respondsToSelector: @selector (applicationState )]) {
148
+ appState = application.applicationState ;
149
+ }
150
+
151
+ if (appState == UIApplicationStateActive || appState == UIApplicationStateBackground ) {
152
+ [Push sharedInstance ].notificationMessage = userInfo;
153
+ [Push sharedInstance ].isInline = appState == UIApplicationStateActive ;
154
+ [[Push sharedInstance ] notificationReceived ];
155
+ } else {
156
+ [Push sharedInstance ].launchNotification = userInfo;
157
+ }
158
158
}
159
159
160
160
- (void )my_application : (UIApplication *)application didFailToRegisterForRemoteNotificationsWithError : (NSError *)error {
You can’t perform that action at this time.
0 commit comments