Exemplo n.º 1
0
        /// <summary>
        /// The application is getting warning that a Handoff continuation is about occur.
        /// </summary>
        /// <returns><c>true</c>, if continue user activity was willed, <c>false</c> otherwise.</returns>
        /// <param name="application">Application.</param>
        /// <param name="userActivityType">User activity type.</param>
        public override bool WillContinueUserActivity(UIApplication application, string userActivityType)
        {
            // Report Activity
            Console.WriteLine("Will Continue Activity: {0}", userActivityType);

            // Take action based on the user activity type
            switch (userActivityType)
            {
            case "com.xamarin.monkeybrowser.tab1":
                // Inform view that it's going to be modified
                Tab1.PreparingToHandoff();
                break;

            case "com.xamarin.monkeybrowser.tab2":
                // Inform view that it's going to be modified
                Tab2.PreparingToHandoff();
                break;

            case "com.xamarin.monkeybrowser.tab3":
                // Inform view that it's going to be modified
                Tab3.PreparingToHandoff();
                break;

            case "com.xamarin.monkeybrowser.tab4":
                // Inform view that it's going to be modified
                Tab4.PreparingToHandoff();
                break;
            }

            // Inform system we handled this
            return(true);
        }