Uploaded image for project: 'AeroGear'
  1. AeroGear
  2. AEROGEAR-5152

Xcode template: use iOS7 specific method for remote notifications

XMLWordPrintable

    • Icon: Feature Request Feature Request
    • Resolution: Done
    • Icon: Major Major
    • 1.5.0
    • 1.4.0
    • None
    • None

      since we are focusing on iOS7, or more supporting iOS7 only, we should polish the push related part of the template for iOS7.

      Currently we generate the following methods, if push is enabled:

      - (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo {
      ....    
      }
       
      - (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo fetchCompletionHandler:(void (^)(UIBackgroundFetchResult))completionHandler {
      .....
      }
      

      However, with iOS7 - if both are present, only the application:didReceiveRemoteNotification:fetchCompletionHandler: is invoked.

      Relevant Apple documentation:
      https://developer.apple.com/library/ios/documentation/uikit/reference/UIApplicationDelegate_Protocol/Reference/Reference.html#//apple_ref/doc/uid/TP40006786-CH3-SW16

      The solution for this ticket is to only generate the application:didReceiveRemoteNotification:fetchCompletionHandler: method

              Unassigned Unassigned
              mwessend@redhat.com Matthias Wessendorf
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: