Hello Guest

Cant seem to detect scrolling

  • 2 Replies
  • 801 Views
Cant seem to detect scrolling
« on: July 08, 2017, 22:03:29 »
Hiah!

Just tried out this little snippet earlier:
Code: [Select]
        GLFW.glfwSetScrollCallback( handle, new GLFWScrollCallback() {

@Override
public void invoke(long window, double arg1, double arg2) {
System.out.println("window " + window + " / " + arg1 + " / " + arg2);
}

@Override
public void callback(long arg0) {
//
}

@Override
public String getSignature() {
return "Scroll Callback";
}

@Override
public void close() {
//
}
       
        });

Nothing seems to print when I scroll the mouse. Am I doing something incorrectly?

*

Offline spasi

  • *****
  • 2009
    • WebHotelier
Re: Cant seem to detect scrolling
« Reply #1 on: July 08, 2017, 22:17:41 »
Yes, do not override the methods callback, getSignature and close.

Re: Cant seem to detect scrolling
« Reply #2 on: July 08, 2017, 23:07:03 »
Perfect! Thank you, Spasi!