Ejemplo n.º 1
0
 protected override void OnNavigatedTo(NavigationEventArgs e)
 {
     TheMainPage?.SelectNavPlaceholder(GetResourceString("UserDetailPagePlain"));
     userid      = (int)e.Parameter;
     itemsSource = new UserIllustsCollection(userid.ToString());
     itemsSource.CollectionChanged += ItemsSource_CollectionChanged;
     WaterfallListView.ItemsSource  = itemsSource;
     base.OnNavigatedTo(e);
     _ = loadContents();
 }
        protected override void OnNavigatedTo(NavigationEventArgs e)
        {
            TheMainPage?.SelectNavPlaceholder(GetResourceString("UserDetailPagePlain"));

            //治标不治本的加载逻辑……反正个人插画也不会太多,全部重载就好)
            if (e.Parameter is ValueTuple <int, bool> tuple)
            {
                Data.OverAll.UserList?.StopLoading();
                userid = tuple.Item1;
                _      = loadContents();
                //Data.OverAll.RefreshUserList(userid.ToString()); 治 本 (需删除85行并修改Collection中的瀑布流控制逻辑)
            }
            else if (e.Parameter is int id)
            {
                userid = id;
                grdDetail.Visibility = Visibility.Collapsed;
            }
            Data.OverAll.RefreshUserList(userid.ToString()); //治 标
            Data.OverAll.UserList.ResumeLoading();
            itemsSource = OverAll.UserList;
            itemsSource.CollectionChanged += ItemsSource_CollectionChanged;
            WaterfallListView.ItemsSource  = itemsSource;
            base.OnNavigatedTo(e);
        }
Ejemplo n.º 3
0
 protected override void OnNavigatedTo(NavigationEventArgs e)
 {
     base.OnNavigatedTo(e);
     TheMainPage?.SelectNavPlaceholder(GetResourceString("SettingsPagePlain"));
 }