Exemplo n.º 1
0
        private async Task loadComments(StackPanel sp, ProgressRing pr, SampleDataItem feedItem)
        {
            if (feedItem.aComments.Count == 0)
            {
                sp.Visibility = Windows.UI.Xaml.Visibility.Visible;
                pr.IsActive   = true;

                await SampleDataSource.ParseCommentsAsync(feedItem);

                //await SampleDataSource.ParseComments(feedItem);

                sp.Visibility = Windows.UI.Xaml.Visibility.Collapsed;
                pr.IsActive   = false;


                //feedItem.aComments.Clear();
                if (feedItem.aComments.Count == 0)
                {
                    await SampleDataSource.AddChildren(feedItem, feedItem.Comments);

                    //feedItem.Comments.Clear();
                }
            }
        }