コード例 #1
0
        protected override void LimparMemoria()
        {
            _teeService      = null;
            _handicapService = null;
            _generoService   = null;
            _cameraService   = null;

            TeesExistentes    = null;
            GenerosExistentes = null;
            HandicapMinimo    = null;
            HandicapMaximo    = null;

            _jogador = null;
            Nome     = null;
            Email    = null;
            Foto     = null;
            Genero   = null;
            Tee      = null;
            Handicap = null;

            TirarFotoCommand      = null;
            GuardarDadosCommand   = null;
            RemoverJogadorCommand = null;
            CancelarEdicaoCommand = null;
            ResetEmailCommand     = null;

            base.LimparMemoria();
        }
コード例 #2
0
        public JogoConfiguracaoViewModel(
            INavigationService navigationService,
            IDialogService dialogService,
            ICampoService campoService,
            IModoJogoService modoJogoService,
            IMetricoService metricoService,
            IBuracosService buracoService,
            ITeeService teeService,
            ITeeDistanciaService teeDistanciaService)
            : base(navigationService, dialogService)
        {
            _campoService        = campoService;
            _modoJogoService     = modoJogoService;
            _metricoService      = metricoService;
            _buracoService       = buracoService;
            _teeService          = teeService;
            _teeDistanciaService = teeDistanciaService;

            ActivityIndicatorTool = new ActivityIndicatorTool(activityIndicatorCor: "#11990f", mensagemAMostrar: "Creating the game...", backgroundCorVisivel: "#CC000000", backgroundCorEscondido: "#00000000");

            Jogadores = new ObservableCollection <JogadorWrapperViewModel>();

            InicializarComunicacaoMediadorMensagens();

            //Preencher Pickers.
            Task.Run(async() => await InicializarDados());
        }
コード例 #3
0
        public EditarJogadorPopupViewModel(INavigationService navigationService,
                                           IDialogService dialogService,
                                           ITeeService teeService,
                                           IHandicapService handicapService,
                                           IGeneroService generoService,
                                           ICameraService cameraService)
            : base(navigationService, dialogService)
        {
            _teeService      = teeService;
            _handicapService = handicapService;
            _generoService   = generoService;
            _cameraService   = cameraService;

            InicializarComunicacaoMediador();

            Task.Run(async() => await InicializarDados());

            Email = new ValidatableObject <string>();
            Email.RegrasValidacao.AddRange(new List <IValidationRule <string> >()
            {
                new EmailValidationRule <string>(), new EspacoEmBrancoValidationRule <string>(), new EmptyValidationRule <string>()
            });

            Nome = new ValidatableObject <string>();
            Nome.RegrasValidacao.AddRange(new List <IValidationRule <string> >()
            {
                new EspacoEmBrancoValidationRule <string>(), new EmptyValidationRule <string>()
            });
        }
コード例 #4
0
        protected override void LimparMemoria()
        {
            _campoService        = null;
            _modoJogoService     = null;
            _metricoService      = null;
            _buracoService       = null;
            _teeDistanciaService = null;
            _teeService          = null;

            CamposExistentes    = null;
            CampoSelecionado    = null;
            ModosJogoExistentes = null;
            ModoJogoSelecionado = null;
            MetricosExistentes  = null;
            MetricoSelecionado  = null;
            TeesExistentes      = null;
            TeeSelecionado      = null;
            Jogadores           = null;

            ComecarJogoCommand  = null;
            CancelarJogoCommand = null;

            base.LimparMemoria();
        }