AppDelegate.cs 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using Foundation;
  5. using UIKit;
  6. namespace TwitterSearch.iOS
  7. {
  8. // The UIApplicationDelegate for the application. This class is responsible for launching the
  9. // User Interface of the application, as well as listening (and optionally responding) to
  10. // application events from iOS.
  11. [Register("AppDelegate")]
  12. public partial class AppDelegate : UIApplicationDelegate
  13. {
  14. // class-level declarations
  15. public override UIWindow Window
  16. {
  17. get;
  18. set;
  19. }
  20. public override bool FinishedLaunching(UIApplication application, NSDictionary launchOptions)
  21. {
  22. UINavigationBar.Appearance.BarTintColor = UIColor.FromRGB(17, 113, 197); //bar background
  23. UINavigationBar.Appearance.TintColor = UIColor.White; //Tint color of button items
  24. UINavigationBar.Appearance.SetTitleTextAttributes(new UITextAttributes()
  25. {
  26. Font = UIFont.FromName("HelveticaNeue-Light", 20f),
  27. TextColor = UIColor.White
  28. });
  29. return true;
  30. }
  31. //
  32. // This method is invoked when the application is about to move from active to inactive state.
  33. //
  34. // OpenGL applications should use this method to pause.
  35. //
  36. public override void OnResignActivation(UIApplication application)
  37. {
  38. }
  39. // This method should be used to release shared resources and it should store the application state.
  40. // If your application supports background exection this method is called instead of WillTerminate
  41. // when the user quits.
  42. public override void DidEnterBackground(UIApplication application)
  43. {
  44. }
  45. // This method is called as part of the transiton from background to active state.
  46. public override void WillEnterForeground(UIApplication application)
  47. {
  48. }
  49. // This method is called when the application is about to terminate. Save data, if needed.
  50. public override void WillTerminate(UIApplication application)
  51. {
  52. }
  53. }
  54. }