Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add abstraction over scroll wheel #10

Closed
Apostolique opened this issue Jan 19, 2021 · 1 comment
Closed

Add abstraction over scroll wheel #10

Apostolique opened this issue Jan 19, 2021 · 1 comment

Comments

@Apostolique
Copy link
Owner

Apostolique commented Jan 19, 2021

The current way to use the scroll wheel looks like this:

int scrollDelta = InputHelper.NewMouse.ScrollWheelValue - InputHelper.OldMouse.ScrollWheelValue;
if (scrollDelta != 0) {
    // Do something with the delta.
}

It would be nice to provide an abstraction over this pattern. It would also be nice to be able to use this in the context of the tracking system.

Possible API:

if (MouseCondition.Scrolled()) {
    // MouseCondition.ScrollDelta
}
@Apostolique
Copy link
Owner Author

Closed in 68af16f.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant