Mouse ScrollWheelValue Property Delta Engine Documentation
Total accumulated mouse scroll wheel value. Compare with last frame to see the change (see MouseZoomTrigger). Will not use multipliers like 120 to report one mouse wheel up change. One mouse wheel up change results in a value change of +1, down is -1. View code on GitHub

Namespace: DeltaEngine.Input
Assembly: DeltaEngine.Input (in DeltaEngine.Input.dll) Version: 1.1.1.0 (1.1.1)
Syntax

public int ScrollWheelValue { get; protected set; }

Property Value

Type: Int32
Remarks

Tests: DeltaEngine.Input.Tests.MouseTests
Examples

2 unit tests call DeltaEngine.Input.Mouse.ScrollWheelValue
[Test, CloseAfterFirstFrame]
public void ScrollWheelUpAndDown()
{
    var mockMouse = Resolve<Mouse>() as MockMouse;
    if (mockMouse == null)
        return; //ncrunch: no coverage
    Assert.AreEqual(0, mockMouse.ScrollWheelValue);
    mockMouse.ScrollUp();
    Assert.AreEqual(1, mockMouse.ScrollWheelValue);
    mockMouse.ScrollDown();
    Assert.AreEqual(0, mockMouse.ScrollWheelValue);
}
[Test]
public void ShowScrollWheelValue()
{
    var mouse = Resolve<Mouse>();
    var text = new FontText(Font.Default, "Scroll Mouse Wheel!", Rectangle.One);
    new Command(() => text.Text = "Scroll Wheel Value: " + mouse.ScrollWheelValue).Add(
        new MouseZoomTrigger());
}
See Also