void PathMouseLeave(object sender, MouseEventArgs e) { if (sender.GetType() == typeof(Path)) { Path thing = (Path)sender; if (currentPathInfo != null) { thing.Fill = currentPathInfo.baseColor; currentPathInfo = null; } } else if (sender.GetType() == typeof(Rectangle)) { Rectangle thing = (Rectangle)sender; if (currentPathInfo != null) { thing.Fill = currentPathInfo.baseColor; currentPathInfo = null; } } }
void PathMouseEnter(object sender, MouseEventArgs e) { //int[] magnifications = { (int)xMagSlider.Value, (int)yMagSlider.Value, (int)zMagSlider.Value }; if(sender.GetType() == typeof(Path)){ Path thing = (Path)sender; if (currentPathInfo == null) { currentPathInfo = new GUIDriveUIDParser(thing.Uid,magnifications); } thing.Fill = new SolidColorBrush(Color.FromRgb(100, 100, 100)); } else if (sender.GetType() == typeof(Rectangle)) { Rectangle thing = (Rectangle)sender; if (currentPathInfo == null) { currentPathInfo = new GUIDriveUIDParser(thing.Uid, magnifications); } thing.Fill = new SolidColorBrush(Color.FromRgb(100, 100, 100)); } }