Export to GitHub

controlp5 - issue #95

DropdownList setIndex throws Exception


Posted on May 17, 2015 by Helpful Rabbit

Setting the Index of a DropdownList works fine, but I get the following Exception Thrown:

d1.setIndex(17);

What am I missing, please? Mai 17, 2015 11:51:13 AM controlP5.ControlBroadcaster printMethodError SEVERE: An error occured while forwarding a Controller event, please check your code at controlEvent java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at controlP5.ControlBroadcaster.invokeMethod(Unknown Source) at controlP5.ControlBroadcaster.broadcast(Unknown Source) at controlP5.DropdownList.setValue(Unknown Source) at controlP5.DropdownList.setIndex(Unknown Source) at MIDI_Scale_1.initMIDIInputDropDown(MIDI_Scale_1.java:140) at MIDI_Scale_1.setup(MIDI_Scale_1.java:410) at processing.core.PApplet.handleDraw(PApplet.java:2361) at processing.opengl.PJOGL$PGLListener.display(PJOGL.java:862) at jogamp.opengl.GLDrawableHelper.displayImpl(GLDrawableHelper.java:665) at jogamp.opengl.GLDrawableHelper.display(GLDrawableHelper.java:649) at javax.media.opengl.awt.GLCanvas$10.run(GLCanvas.java:1289) at jogamp.opengl.GLDrawableHelper.invokeGLImpl(GLDrawableHelper.java:1119) at jogamp.opengl.GLDrawableHelper.invokeGL(GLDrawableHelper.java:994) at javax.media.opengl.awt.GLCanvas$11.run(GLCanvas.java:1300) at javax.media.opengl.Threading.invoke(Threading.java:193) at javax.media.opengl.awt.GLCanvas.display(GLCanvas.java:541) at javax.media.opengl.awt.GLCanvas.paint(GLCanvas.java:595) at sun.awt.RepaintArea.paintComponent(Unknown Source) at sun.awt.RepaintArea.paint(Unknown Source) at sun.awt.windows.WComponentPeer.handleEvent(Unknown Source) at java.awt.Component.dispatchEventImpl(Unknown Source) at java.awt.Component.dispatchEvent(Unknown Source) at java.awt.EventQueue.dispatchEventImpl(Unknown Source) at java.awt.EventQueue.access$200(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue$4.run(Unknown Source) at java.awt.EventQueue$4.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue.dispatchEvent(Unknown Source) at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.run(Unknown Source) Caused by: java.lang.NullPointerException at MIDI_Scale_1.controlEvent(MIDI_Scale_1.java:85) ... 44 more

Comment #1

Posted on May 17, 2015 by Helpful Rabbit

Comment deleted

Comment #2

Posted on May 17, 2015 by Helpful Rabbit

the error is thrown after I call: myBus.clearInputs();

Status: New

Labels:
Type-Defect Priority-Medium