Exemple #1
0
 protected override void OnNavigatedTo(NavigationEventArgs e)
 {
     base.OnNavigatedTo(e);
     KeyDown       += OnKeyDownHandler;
     NavigationMode = e.NavigationMode;
     if (e.NavigationMode == NavigationMode.New)
     {
         GetType().RemovePageFromBackStack();
         MultiplePostVM?.ResetCache();
     }
     try
     {
         if (e.Parameter != null && e.Parameter is InstaChannel channel)
         {
             Channel = channel;
         }
     }
     catch { }
 }
Exemple #2
0
 private void MultiplePostViewLoaded(object sender, RoutedEventArgs e)
 {
     if (NavigationMode == NavigationMode.Back && MultiplePostVM.ChannelId != null)
     {
         if (MultiplePostVM.ChannelId.ToLower().TrimAnyBullshits() == Channel.ChannelId.ToLower().TrimAnyBullshits())
         {
             return;
         }
     }
     else if (NavigationMode == NavigationMode.New)
     {
         NavigationCacheMode = NavigationCacheMode.Enabled;
         CanLoadFirstPopUp   = false;
     }
     if (!CanLoadFirstPopUp)
     {
         MultiplePostVM.ResetCache();
         MultiplePostVM.ChannelId    = Channel.ChannelId;
         MultiplePostVM.FirstMediaId = Channel.Media.InstaIdentifier;
         MultiplePostVM.Title        = Channel.Title;
         MultiplePostVM.RunLoadMore(true);
         CanLoadFirstPopUp = true;
     }
 }