/// <summary>
 /// Initializes a new instance of the <see cref="MultiPlayerDetailsViewModel"/> class.
 /// </summary>
 /// <param name="model">The model.</param>
 public MultiPlayerDetailsViewModel(IMultiPlayerModel model)
 {
     this.model             = model;
     model.PropertyChanged += delegate(Object sender, PropertyChangedEventArgs e){
         if (e.PropertyName == "Maze")
         {
             MultiPlayer mp = new MultiPlayer(model);
             mp.Show();
             NotifyPropertyChanged("VM_" + e.PropertyName);
         }
     };
 }
Ejemplo n.º 2
0
        /// <summary>
        /// Handles the <see cref="E:LostConnectionPropertyChanged" /> event.
        /// </summary>
        /// <param name="d">The d.</param>
        /// <param name="e">The <see cref="DependencyPropertyChangedEventArgs"/> instance containing the event data.</param>
        private static void OnLostConnectionPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            MultiPlayer win = (MultiPlayer)d;

            win.OnLostConnectionPropertyChanged();
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Handles the <see cref="E:ExitGamePropertyChanged" /> event.
        /// </summary>
        /// <param name="d">The d.</param>
        /// <param name="e">The <see cref="DependencyPropertyChangedEventArgs"/> instance containing the event data.</param>
        private static void OnExitGamePropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            MultiPlayer win = (MultiPlayer)d;

            win.OnExitGamePropertyChanged();
        }