Пример #1
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());
        }
Пример #2
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();
        }