예제 #1
0
 public LoginViewModel()
 {
     InicioSesion        = new Command(() => InicioSesionCommand(), () => true);
     InicioSesionNormal  = new Command(async() => await IniciarSesionNavegacion(), () => true);
     ContarLogin         = 0;
     googleClientManager = CrossGoogleClient.Current;
 }
 public LoginPageViewModel()
 {
     LoginCommand        = new Command(LoginAsync);
     LogoutCommand       = new Command(Logout);
     googleClientManager = CrossGoogleClient.Current;
     IsLoggedIn          = false;
 }
예제 #3
0
        public static void SetInstance(IGoogleClientManager googleClientManager)
        {
            if (instance != null)
            {
                return;
            }

            instance = googleClientManager;
        }
예제 #4
0
        public LoginViewModel(ILoginService loginService)
        {
            _loginService       = loginService;
            GoogleLoginCommand  = new Command(GoogleLoginAsync);
            GoogleLogoutCommand = new Command(GoogleLogout);

            _googleClientManager = CrossGoogleClient.Current;


            IsLoggedIn = false;
        }
예제 #5
0
        public LoginViewModel()
        {
            InicioSesion        = new Command(InicioSesionCommand);
            googleClientManager = CrossGoogleClient.Current;
            loadDataHandler     = new LoadDataHandler();
            string urlCretateUsuario = Endpoints.URL_SERVIDOR + Endpoints.CREATE_USUARIO;
            string urlGetUsuario     = Endpoints.URL_SERVIDOR + Endpoints.GET_USUARIO;


            CreateUsuario = new SelectRequest <UsuarioModel>();
            CreateUsuario.SelectStrategy("POST", urlCretateUsuario);
            GetUsuario = new SelectRequest <UsuarioModel>();
            GetUsuario.SelectStrategy("GET", urlGetUsuario);
            PopUp = new MessagePopupView();
        }
예제 #6
0
        /// <summary>
        /// Initializes a new instance for the <see cref="NoInternetConnectionPageViewModel" /> class.
        /// </summary>
        public LoginPageViewModel(INavigationService navigationService, IDialogService dialogService, IThemeService themeService)
            : base(navigationService)
        {
            this._googleService            = CrossGoogleClient.Current;
            this._facebookService          = CrossFacebookClient.Current;
            this.dialogService             = dialogService;
            this._themeService             = themeService;
            this.LoginCommand              = new Command(this.Login);
            this.PushForgotPasswordCommand = new Command(this.ForgotPassword);
            this.PushRegisterCommand       = new Command(this.PushRegisterPage);
            this.LoginWithFaceBookCommand  = new Command(this.LoginWithFacebook);
            this.LoginWithGoogleCommand    = new Command(this.LoginWithGoogle);

            InitValidations();
        }
 protected ViewController(IntPtr handle) : base(handle)
 {
     _googleClientManager = CrossGoogleClient.Current;
 }
예제 #8
0
 public LoginViewModel()
 {
     LoginViewModelInit();
     _googleClientManager = CrossGoogleClient.Current;
 }
예제 #9
0
 public FlyoutHeader()
 {
     InitializeComponent();
     _googleClientManager = CrossGoogleClient.Current;
     BindingContext       = new FlyoutHeaderViewModel();
 }
예제 #10
0
 public GoogleAuthTokenProvider(IGoogleClientManager googleClientManager) => _googleClientManager = googleClientManager;