From 32244da39d02b943d5d5c66405ae16e0c9981104 Mon Sep 17 00:00:00 2001 From: Ilya Grechuhin Date: Fri, 31 Jul 2015 16:56:23 +0300 Subject: [PATCH] [ios] Added push notification processing ability. --- iphone/Maps/Classes/MapsAppDelegate.mm | 3 ++- iphone/Maps/MAPSME.plist | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/iphone/Maps/Classes/MapsAppDelegate.mm b/iphone/Maps/Classes/MapsAppDelegate.mm index 38caf2d9ec..6117ca1723 100644 --- a/iphone/Maps/Classes/MapsAppDelegate.mm +++ b/iphone/Maps/Classes/MapsAppDelegate.mm @@ -155,9 +155,10 @@ void InitLocalizedStrings() [Alohalytics logEvent:kPushDeviceTokenLogEvent withValue:currentInstallation.deviceToken]; } -- (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo +- (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo fetchCompletionHandler:(void (^)(UIBackgroundFetchResult))completionHandler { [PFPush handlePush:userInfo]; + completionHandler(UIBackgroundFetchResultNoData); } - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions diff --git a/iphone/Maps/MAPSME.plist b/iphone/Maps/MAPSME.plist index d2bd4cdedf..db70c673bc 100644 --- a/iphone/Maps/MAPSME.plist +++ b/iphone/Maps/MAPSME.plist @@ -96,6 +96,7 @@ MainWindow-iPad UIBackgroundModes + remote-notification fetch UIFileSharingEnabled