Exemplo n.º 1
0
        public async Task LoadSmiliesAsync()
        {
            if (WebManager == null)
            {
                LoginUser();
            }

            _smileManager = new SmileManager(WebManager);
            if (!SmileCategoryList.Any())
            {
                IsLoading = true;
                var result = await _smileManager.GetSmileListAsync();

                FullSmileCategoryEntities = result.ToObservableCollection();
                foreach (var item in result)
                {
                    SmileCategoryList.Add(item);
                }
                IsLoading = false;
            }

            if (SmiliesView != null)
            {
                SmiliesView.Init();
            }
            //if (SmiliesXboxView != null) SmiliesXboxView.Init();
        }
Exemplo n.º 2
0
        public async Task Initialize()
        {
            if (!SmileCategoryList.Any())
            {
                IsLoading = true;
                var list = await _smileManager.GetSmileList();

                FullSmileCategoryEntities = list.ToObservableCollection();
                foreach (var item in list)
                {
                    SmileCategoryList.Add(item);
                }
                IsLoading = false;
            }
            OnPropertyChanged("SmileCategoryList");
        }