Exemple #1
0
        private void drvInfo_Click(object sender, RoutedEventArgs e)
        {
            drvInfo infoWindow = new drvInfo(dsrsrc);

            frameInfo.Content      = infoWindow;
            drvInfo.Background     = new SolidColorBrush(Color.FromRgb(20, 126, 245));
            carInfo.Background     = new SolidColorBrush(Color.FromRgb(217, 223, 239));
            trainerInfo.Background = new SolidColorBrush(Color.FromRgb(217, 223, 239));
        }
Exemple #2
0
 private void DazzleTabControl_SelectionChanged(object sender, SelectionChangedEventArgs e)
 {
     if (e.Source is TabControl)
     {
         if ((e.Source as TabControl).SelectedIndex == 0)
         {
             stuManage stuwindow = new stuManage(dsrsrc);
             this.frameStu.Content  = stuwindow;
             serstudent.Background  = new SolidColorBrush(Color.FromRgb(20, 126, 245));
             meuRecharge.Background = new SolidColorBrush(Color.FromRgb(217, 223, 239));
             serManage.Background   = new SolidColorBrush(Color.FromRgb(217, 223, 239));
         }
         else if ((e.Source as TabControl).SelectedIndex == 1)
         {
             bookMange bookwindow = new bookMange(dsrsrc);
             this.frameBook.Content = bookwindow;
             perBook.Background     = new SolidColorBrush(Color.FromRgb(20, 126, 245));
             muiBook.Background     = new SolidColorBrush(Color.FromRgb(217, 223, 239));
         }
         else if ((e.Source as TabControl).SelectedIndex == 2)
         {
             serTraResult serWindow = new serTraResult(dsrsrc);
             this.frameSer.Content = serWindow;
         }
         else if ((e.Source as TabControl).SelectedIndex == 3)
         {
             drvInfo infoWindow = new drvInfo(dsrsrc);
             frameInfo.Content      = infoWindow;
             drvInfo.Background     = new SolidColorBrush(Color.FromRgb(20, 126, 245));
             carInfo.Background     = new SolidColorBrush(Color.FromRgb(217, 223, 239));
             trainerInfo.Background = new SolidColorBrush(Color.FromRgb(217, 223, 239));
         }
         else
         {
             userInfo infoWindow = new userInfo(dsrsrc);
             frameUser.Content   = infoWindow;
             userInfo.Background = new SolidColorBrush(Color.FromRgb(20, 126, 245));
             baseInfo.Background = new SolidColorBrush(Color.FromRgb(217, 223, 239));
         }
     }
 }