コード例 #1
0
 /// <summary>
 /// Called to update the brush used to stroke this wire
 /// </summary>
 /// <param name="state">The current wire state</param>
 protected override void UpdateStrokeBrush(WirePathPresentationState state)
 {
     if (ViewModel.IsSelected)
     {
         Stroke = Brushes.Orange;
     }
     else
     {
         Stroke = Brushes.Blue;
     }
 }
コード例 #2
0
 /// <summary>
 /// Called to update the stroke thickness of this wire.  In this case it is always a constant value.
 /// </summary>
 /// <param name="state"></param>
 protected override void UpdateStrokeThickness(WirePathPresentationState state)
 {
     InnerWireStrokeThickness = 3;
     OuterWireStrokeThickness = 5;
 }