private static void OnIsViewRobotPropertyChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e) { LabyrinthControl s = sender as LabyrinthControl; if (s.Robot != null) { s.HasChanges = true; } }
private static void OnRobotPropertyChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e) { LabyrinthControl s = sender as LabyrinthControl; s.robot = (Robot)e.NewValue; if (s.IsViewRobot) { s.HasChanges = true; } }
private static void OnLabyrinthPropertyChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e) { LabyrinthControl s = sender as LabyrinthControl; Labyrinth value = (Labyrinth)e.NewValue; if (value != null) { foreach (SearchView search in s.Searches) { search.Labyrinth = value; } } s.HasChanges = true; }