Guest User

Untitled

a guest
Jul 22nd, 2018
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.24 KB | None | 0 0
  1. //
  2. // DMB_Live_SetlistAppDelegate.m
  3. // DMB Live Setlist
  4. //
  5. // Created by Matt Yette on 1/25/10.
  6. // Copyright __MyCompanyName__ 2010. All rights reserved.
  7. //
  8.  
  9. #import "DMB_Live_SetlistAppDelegate.h"
  10. #import "DMB_Live_SetlistViewController.h"
  11.  
  12. @implementation DMB_Live_SetlistAppDelegate
  13.  
  14. @synthesize window;
  15. @synthesize viewController;
  16.  
  17.  
  18. - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
  19. [application registerForRemoteNotificationTypes:(UIRemoteNotificationTypeBadge |
  20. UIRemoteNotificationTypeSound |
  21. UIRemoteNotificationTypeAlert)];
  22.  
  23. // Override point for customization after application launch
  24. [window addSubview:viewController.view];
  25. [window makeKeyAndVisible];
  26.  
  27. return YES;
  28. }
  29.  
  30. // Delegation methods
  31. - (void)application:(UIApplication *)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)devToken {
  32. NSLog(@"success");
  33. }
  34.  
  35. - (void)application:(UIApplication *)application didFailToRegisterForRemoteNotificationsWithError:(NSError *)err {
  36. NSLog(@"Error in registration. Error: %@", err);
  37. }
  38. - (void)dealloc {
  39. [viewController release];
  40. [window release];
  41. [super dealloc];
  42. }
  43.  
  44.  
  45. @end
Add Comment
Please, Sign In to add comment