Пример #1
0
 protected override void Dispose(bool disposing)
 {
     base.Dispose(disposing);
     if (disposing)
     {
         if (FlyingObjects != null)
         {
             FlyingObjects.Dispose();
             FlyingObjects = null;
         }
         if (DestinationViewController != null)
         {
             DestinationViewController.Dispose();
             DestinationViewController = null;
         }
         if (DidEnterBackgroundToken != null)
         {
             DidEnterBackgroundToken.Dispose();
             DidEnterBackgroundToken = null;
         }
         if (WillEnterForgroundToken != null)
         {
             WillEnterForgroundToken.Dispose();
             WillEnterForgroundToken = null;
         }
     }
 }
 public override void ViewDidLoad()
 {
     base.ViewDidLoad();

     FlyingObjects = new FlyingObjectsView(View.Frame);
            View.InsertSubview(FlyingObjects, 0);

     AddChildViewController(ContainerNavigationController);
     ContainerView.AddSubview(ContainerNavigationController.View);
     ContainerView.AddConstraint(NSLayoutConstraint.Create(ContainerNavigationController.View, NSLayoutAttribute.Top, NSLayoutRelation.Equal, ContainerView, NSLayoutAttribute.Top, 1, 0));
     ContainerView.AddConstraint(NSLayoutConstraint.Create(ContainerNavigationController.View, NSLayoutAttribute.Right, NSLayoutRelation.Equal, ContainerView, NSLayoutAttribute.Right, 1, 0));
     ContainerView.AddConstraint(NSLayoutConstraint.Create(ContainerNavigationController.View, NSLayoutAttribute.Bottom, NSLayoutRelation.Equal, ContainerView, NSLayoutAttribute.Bottom, 1, 0));
     ContainerView.AddConstraint(NSLayoutConstraint.Create(ContainerNavigationController.View, NSLayoutAttribute.Left, NSLayoutRelation.Equal, ContainerView, NSLayoutAttribute.Left, 1, 0));
            ContainerNavigationController.View.TranslatesAutoresizingMaskIntoConstraints = false;

            ContainerViewTopMarginConstraint.Constant = UIApplication.SharedApplication.StatusBarFrame.Height;

           
        }
Пример #3
0
        public override void ViewDidLoad()
        {
            base.ViewDidLoad();

            var service    = ServiceLocator.Instance.Resolve <IPersistantStorage>();
            var designType = service.GetDesignType();

            FlyingObjects = new FlyingObjectsView(View.Frame);
            FlyingObjects.StartAnimationLoop(FlyingObjectsView.AnimationDirection.left, designType, 20, 100, 1);
            View.InsertSubview(FlyingObjects, 0);
        }
        protected override void Dispose(bool disposing)
        {
            base.Dispose(disposing);
            if (disposing)
            {
                FlyingObjects?.Dispose();
                FlyingObjects = null;

                ContainerNavigationController?.Dispose();
                ContainerNavigationController = null;

                DidEnterBackgroundToken?.Dispose();
                DidEnterBackgroundToken = null;

                WillEnterForgroundToken?.Dispose();
                WillEnterForgroundToken = null;

                DesignChangedToken?.Dispose();
                DesignChangedToken = null;
            }
        }


       
        void ShowBanner(Dictionary<string, string> advertisingTargetInfo)