Пример #1
0
        public override bool OpenUrl(UIApplication app, NSUrl url, NSDictionary options)
        {
            // Convert NSUrl to Uri
            var uri = new Uri(url.AbsoluteString);

            // Load redirectUrl page
            AuthenticationState.Authenticator.OnPageLoading(uri);
            return(FacebookClientManager.OpenUrl(app, url, options));
        }
        public override bool OpenUrl(UIApplication app, NSUrl url, NSDictionary options)
        {
            switch (WelcomePage.LoginType)
            {
            case "facebook":
                return(FacebookClientManager.OpenUrl(app, url, options));

            case "google":
                return(GoogleClientManager.OnOpenUrl(app, url, options));
            }
            return(false);
        }
Пример #3
0
 public override bool OpenUrl(UIApplication application, NSUrl url, string sourceApplication, NSObject annotation)
 {
     return(FacebookClientManager.OpenUrl(application, url, sourceApplication, annotation));
 }
Пример #4
0
 public override bool OpenUrl(UIApplication app, NSUrl url, NSDictionary options)
 {
     return(FacebookClientManager.OpenUrl(app, url, options));
 }
Пример #5
0
        //gg login
        public override bool OpenUrl(UIApplication app, NSUrl url, NSDictionary options)
        {
            switch (url.Scheme)
            {
            case "fb764532897311608":
                return(FacebookClientManager.OpenUrl(app, url, options));

            case "com.googleusercontent.apps.607579750145-7jckghtgn6mhqva1o7762ouceng4mh1k":
                // Convert NSUrl to Uri
                var uri = new Uri(url.AbsoluteString);

                // Load redirectUrl page
                AuthenticationState.Authenticator.OnPageLoading(uri);

                return(true);

            case "sundihome":
                string fullUrl = url.ToString();
                if (fullUrl.StartsWith("sundihome://postitem", StringComparison.OrdinalIgnoreCase))
                {
                    string postItemId = fullUrl.Replace("sundihome://postitem/", null);
                    App.GoToPostItemPage(postItemId);
                }
                else if (fullUrl.StartsWith("sundihome://post", StringComparison.OrdinalIgnoreCase))
                {
                    var postId = fullUrl.Replace("sundihome://post/", null);
                    App.GoToPostDetailPage(Guid.Parse(postId));
                }
                else if (fullUrl.StartsWith("sundihome://product", StringComparison.OrdinalIgnoreCase))
                {
                    var productId = fullUrl.Replace("sundihome://product/", null);
                    App.GoToFurnitureProductDetailPage(Guid.Parse(productId));
                }
                else if (fullUrl.StartsWith("sundihome://furniture/postitem", StringComparison.OrdinalIgnoreCase))
                {
                    var furniturePostItemId = fullUrl.Replace("sundihome://furniture/postitem/", null);
                    App.GoToFurniturePostItemDetailPage(furniturePostItemId);
                }
                else if (fullUrl.StartsWith("sundihome://liquidation/postitem", StringComparison.OrdinalIgnoreCase))
                {
                    var liquidationId = fullUrl.Replace("sundihome://liquidation/postitem/", null);
                    App.GoToLiquidationPostItemDetailPage(liquidationId);
                }
                else if (fullUrl.StartsWith("sundihome://liquidation/today", StringComparison.OrdinalIgnoreCase))
                {
                    var liquidationId = fullUrl.Replace("sundihome://liquidation/today/", null);
                    App.GoToLiquidationToDayDetailPage(Guid.Parse(liquidationId));
                }
                else if (fullUrl.StartsWith("sundihome://liquidation", StringComparison.OrdinalIgnoreCase))
                {
                    var liquidationId = fullUrl.Replace("sundihome://liquidation/", null);
                    App.GoToLiquidationDetailPage(Guid.Parse(liquidationId));
                }
                else if (fullUrl.StartsWith("sundihome://moigioi/information", StringComparison.OrdinalIgnoreCase))
                {
                    var moigioiId = fullUrl.Replace("sundihome://moigioi/information/", null);
                    App.GoToThongTinMoiGioiPage(Guid.Parse(moigioiId));
                }
                else if (fullUrl.StartsWith("sundihome://company/b2bpostitem", StringComparison.OrdinalIgnoreCase))
                {
                    var postItemId = fullUrl.Replace("sundihome://company/b2bpostitem/", null);
                    App.GoToB2BDetailPage(postItemId);
                }
                else if (fullUrl.StartsWith("sundihome://company", StringComparison.OrdinalIgnoreCase))
                {
                    var companyId = fullUrl.Replace("sundihome://company/", null);
                    App.GoToCompanyDetailPage(Guid.Parse(companyId));
                }
                return(true);
            }
            return(base.OpenUrl(app, url, options));
        }