예제 #1
0
 public OnThumbDragDelta2Slider()
 {
     OnThumbDragStarted(new global::System.Windows.Controls.Primitives.DragStartedEventArgs(0, 0));
     global::System.Windows.Controls.Primitives.DragDeltaEventArgs e = new global::System.Windows.Controls.Primitives.DragDeltaEventArgs(10, 0);
     OnThumbDragDelta(e);
     Assert.AreEqual(Value, 0);
     e.Source = GetTemplateChild("Thumb");
     OnThumbDragDelta(e);
     Assert.AreEqual(Value, 0);
 }
예제 #2
0
        protected virtual void OnThumbDragDelta(global::System.Windows.Controls.Primitives.DragDeltaEventArgs e)
        {
            if (e.Source == null)
            {
                return;
            }
            double value_from_distance = track.ValueFromDistance(e.HorizontalChange, e.VerticalChange);

            if (double.IsNaN(value_from_distance))
            {
                return;
            }
            Value = GetValueAdjustedForTicks(Value + value_from_distance);
            //FIXME: Auto tool tip does not move. I suspect this is done with an internal member.
            if (auto_tool_tip != null)
            {
                SetAutoToolTipContent();
            }
        }
예제 #3
0
 public OnThumbDragDeltaSlider()
 {
     global::System.Windows.Controls.Primitives.DragDeltaEventArgs e = new global::System.Windows.Controls.Primitives.DragDeltaEventArgs(10, 0);
     OnThumbDragDelta(e);
     Assert.AreEqual(Value, 0);
 }
예제 #4
0
			public OnThumbDragDelta2Slider ()
			{
				OnThumbDragStarted (new global::System.Windows.Controls.Primitives.DragStartedEventArgs (0, 0));
				global::System.Windows.Controls.Primitives.DragDeltaEventArgs e = new global::System.Windows.Controls.Primitives.DragDeltaEventArgs (10, 0);
				OnThumbDragDelta (e);
				Assert.AreEqual (Value, 0);
				e.Source = GetTemplateChild ("Thumb");
				OnThumbDragDelta (e);
				Assert.AreEqual (Value, 0);
			}
예제 #5
0
			public OnThumbDragDeltaSlider ()
			{
				global::System.Windows.Controls.Primitives.DragDeltaEventArgs e = new global::System.Windows.Controls.Primitives.DragDeltaEventArgs (10, 0);
				OnThumbDragDelta (e);
				Assert.AreEqual (Value, 0);
			}