private void OnListLoaded(Model.List list)
        {
            // Load the actual data context!
            List = list;

            if (_list != null && _list.ListItems != null)
            {
                foreach (var item in _list.ListItems)
                {
                    if (item.Id == _listItemId)
                    {
                        Item = item;

                        if (item.Tip != null && item.Tip.TipId != null)
                        {
                            Listed = DataManager.Current.Load <Model.TipListedLists>(item.Tip.TipId, OnListedLoaded, OnListedFailed);
                        }
                        else
                        {
                            Listed = null;
                        }

                        break;
                    }
                }
            }

            UpdateAppBar();
        }
        private void OnTipLoaded(Model.DetailedTip tip)
        {
            var item = Model.CompactListItem.CreateTipFaçade(tip.CompactTip);

            if (item != null)
            {
                Item = item;
                UpdateAppBar();
            }

            // TODO: "Listed"

            // NOTE: A potential crash is here.

            /*
             *
             * NullReferenceException
             * System.NullReferenceException
             * at JeffWilcox.FourthAndMayor.Model.CompactListItem.CreateTipFaçade(Tip tip)
             * at JeffWilcox.FourthAndMayor.Lists.ListItem.OnTipLoaded(DetailedTip tip)
             * at AgFx.DataManager.<>c__DisplayClass69`1.<SetupCompletedCallback>b__68()
             * at AgFx.CacheEntry.<>c__DisplayClass5.<NotifyCompletion>b__4()
             * at System.Reflection.RuntimeMethodInfo.InternalInvoke(RuntimeMethodInfo rtmi, Object obj, BindingFlags invokeAttr, Binder binder, Object parameters, CultureInfo culture, Boolean isBinderDefault, Assembly caller, Boolean verifyAccess, StackCrawlMark& stackMark)
             * at System.Reflection.RuntimeMethodInfo.InternalInvoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, StackCrawlMark& stackMark)
             * at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
             *
             *
             * Navigating to: /JeffWilcox.FourthAndMayor.Lists;component/ListItem.xaml?id=4e90d5b56da174e28e710fe4&tipId=4e90d5b56da174e28e710fe4
             */
        }
Пример #3
0
        private void OnListLoaded(Model.List list)
        {
            // Load the actual data context!
            List = list;

            if (_list != null && _list.ListItems != null)
            {
                foreach (var item in _list.ListItems)
                {
                    if (item.Id == _listItemId)
                    {
                        Item = item;

                        if (item.Tip != null && item.Tip.TipId != null)
                        {
                            Listed = DataManager.Current.Load<Model.TipListedLists>(item.Tip.TipId, OnListedLoaded, OnListedFailed);
                        }
                        else
                        {
                            Listed = null;
                        }

                        break;
                    }
                }
            }

            UpdateAppBar();
        }
Пример #4
0
        private void OnTipLoaded(Model.DetailedTip tip)
        {
            var item = Model.CompactListItem.CreateTipFaçade(tip.CompactTip);
            if (item != null)
            {
                Item = item;
                UpdateAppBar();
            }

            // TODO: "Listed"

            // NOTE: A potential crash is here.
            /*
             * 
             NullReferenceException
System.NullReferenceException
   at JeffWilcox.FourthAndMayor.Model.CompactListItem.CreateTipFaçade(Tip tip)
   at JeffWilcox.FourthAndMayor.Lists.ListItem.OnTipLoaded(DetailedTip tip)
   at AgFx.DataManager.<>c__DisplayClass69`1.<SetupCompletedCallback>b__68()
   at AgFx.CacheEntry.<>c__DisplayClass5.<NotifyCompletion>b__4()
   at System.Reflection.RuntimeMethodInfo.InternalInvoke(RuntimeMethodInfo rtmi, Object obj, BindingFlags invokeAttr, Binder binder, Object parameters, CultureInfo culture, Boolean isBinderDefault, Assembly caller, Boolean verifyAccess, StackCrawlMark& stackMark)
   at System.Reflection.RuntimeMethodInfo.InternalInvoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, StackCrawlMark& stackMark)
   at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
             * 
             * 
             * Navigating to: /JeffWilcox.FourthAndMayor.Lists;component/ListItem.xaml?id=4e90d5b56da174e28e710fe4&tipId=4e90d5b56da174e28e710fe4
             */
        }