public void setToNull(object sender, EventArgs e)
 {
     if (sender is ScoreRecoView)
     {
         _scoreRecoView = null;
     }
     else if (sender is BaseActionConsultation)
     {
         _consultation = null;
     }
     else if (sender is RecoView)
     {
         _recommandation = null;
     }
     else if (sender is RepartitionView)
     {
         _repartition = null;
     }
     else if (sender is RepartitionValeurView)
     {
         _repartitionValeur = null;
     }
     else if (sender is SimulationScoreView)
     {
         _simulation = null;
     }
     else if (sender is DoublonsView)
     {
         _doublons = null;
     }
     else if (sender is ScoreChangeView)
     {
         _changementsScores = null;
     }
 }
        private void StackPanel_MouseDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
        {
            StackPanel obj = sender as StackPanel;

            if (!_doublonsDone)
            {
                MessageBox.Show("Test sur les doublons en cours, veuillez patienter.");
                return;
            }
            if (obj.Name == "Scores")
            {
                ScoreRecoMenu_Click(null, null);
            }
            else if (obj.Name == "Consult")
            {
                ConsultationMenu_Click(null, null);
            }
            else if (obj.Name == "Recommandation")
            {
                Reco_Click(null, null);
            }
            else if (obj.Name == "RepartitionG")
            {
                Repartition_Click(null, null);
            }
            else if (obj.Name == "RepartitionV")
            {
                RepartitionValues_Click(null, null);
            }
            else if (obj.Name == "DoublonsT")
            {
                Doublons_Click(null, null);
            }
            else if (obj.Name == "ChangeScore")
            {
                ChangesScore_Click(null, null);
            }
            else if (obj.Name == "NotifScores")
            {
                if (_changementsScores == null)
                {
                    _changementsScores = new ScoreChangeView();
                    _changementsScores.preLoad();
                    _changementsScores.Show();
                    _changementsScores.Closed += new EventHandler(setToNull);
                }
                else
                {
                    _changementsScores.Focus();
                }
            }
            else if (obj.Name == "NotifDoublons")
            {
                Doublons_Click(null, null);
            }
        }
 private void ChangesScore_Click(object sender, RoutedEventArgs e)
 {
     if (_changementsScores == null)
     {
         _changementsScores = new ScoreChangeView();
         _changementsScores.Show();
         _changementsScores.Closed += new EventHandler(setToNull);
     }
     else
     {
         _changementsScores.Focus();
     }
 }
Esempio n. 4
0
        private void RadMenuItem_Click(object sender, Telerik.Windows.RadRoutedEventArgs e)
        {
            ScoreChangeView scoreChange = new ScoreChangeView();

            scoreChange.Show();
        }