Пример #1
0
        public override bool ContinueUserActivity(UIApplication application, NSUserActivity userActivity, UIApplicationRestorationHandler completionHandler)
        {
            var handle = StartCallRequest.CallHandleFromActivity(userActivity);

            // Found?
            if (handle == null)
            {
                // No, report to system
                Console.WriteLine("Unable to get call handle from User Activity: {0}", userActivity);
                return(false);
            }
            else
            {
                // Yes, start call and inform system
                CallManager.StartCall(handle);
                return(true);
            }
            // return base.ContinueUserActivity(application, userActivity, completionHandler);
        }
Пример #2
0
        public override bool OpenUrl(UIApplication app, NSUrl url, NSDictionary options)
        {
            // Get handle from url
            var handle = StartCallRequest.CallHandleFromURL(url);

            // Found?
            if (handle == null)
            {
                // No, report to system
                Console.WriteLine("Unable to get call handle from URL: {0}", url);
                return(false);
            }
            else
            {
                // Yes, start call and inform system
                CallManager.StartCall(handle);
                return(true);
            }

            // return base.OpenUrl(app, url, options);
        }