Exemple #1
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void JobListView_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (sender is ListView jobListView)
     {
         string    jobId     = jobListView.SelectedItem as string;
         JobConfig jobConfig = MyJobManager.GetJobConfig(jobId);
         OpenJob(jobConfig);
     }
 }
Exemple #2
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 private void TabControl_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (sender is TabControl tabControl && tabControl.SelectedItem is FrameTabItem selectedItem)
     {
         MyFrameManager.ActiveTab = selectedItem;
         HighlightNavigationButton(MyFrameManager.ActiveTab.SelectedPage);
         if (selectedItem.IsJobPage)
         {
             JobConfig jobConfig = MyJobManager.GetJobConfig(selectedItem.Header);
             MyJobManager.SelectedJobConfig = jobConfig;
             SwitchJobButtonsVisibility(jobConfig != null);
         }
     }
 }