Exemplo n.º 1
0
        private void PresentationsQueryComplete_Handler(object sender, APIQueryArgs e)
        {
            if (e.Presentations != null)
            {
                Presentations        = new ObservableCollection <Presentation>(e.Presentations);
                _isPresentationReady = true;
            }
            else
            {
                _isPresentationReady = false;
            }

            CheckInitializationComplete();
        }
Exemplo n.º 2
0
        async private void Failure_Handler(object sender, APIQueryArgs e)
        {
            AsyncLock mutex = new AsyncLock();

            using (await mutex.LockAsync())
            {
                if (!_errorInitializing)
                {
                    _errorInitializing = true;
                    IsUpdating         = false;


                    if (InitializationError != null)
                    {
                        InitializationError.Invoke(this, null);
                    }
                }
            }

            //TODO: Display something useful.  Cached data for example.

            System.Diagnostics.Debug.WriteLine(string.Format("Initialization error. [{0}]", e.Error.Message));
        }