Exemplo n.º 1
0
        public void StartAuthentication()
        {
            auth = new OAuth2Authenticator
                   (
                clientId: "1819301671524550",
                scope: "",
                authorizeUrl: new Uri("https://m.facebook.com/dialog/oauth/"),
                redirectUrl: new Uri("https://www.facebook.com/connect/login_success.html"),
                isUsingNativeUI: false
                   );

            auth.Completed += (sender, eventArgs) =>
            {
                AuthCompleted?.Invoke(this, eventArgs);
            };
        }
Exemplo n.º 2
0
        private void CompleteCallback(object sender, GenericSdkEventArgs <string> e)
        {
            _authCompleted = true;

            Browser.Visibility = Visibility.Hidden;

            BusyIndicator.BusyContent = LocalizedStrings.Str1574;
            BusyIndicator.IsBusy      = true;

            Task.Factory
            .StartNew(() => AuthCompleted.SafeInvoke(this, new GenericSdkEventArgs <string>(e.Result)))
            .ContinueWith(res =>
            {
                BusyIndicator.IsBusy = false;
                Close();
            }, TaskScheduler.FromCurrentSynchronizationContext());
        }
Exemplo n.º 3
0
 public static void Completed(AuthToken token)
 {
     AuthCompleted?.Invoke(token);
 }