我有一个全屏主场景。然后我有一个扩展舞台的警报对话框。它充满了自定义文本,定位在屏幕上并显示出来。
问题是当我触摸我的屏幕时,会出现这个错误:
Exception in thread "JavaFX Application Thread" java.lang.RuntimeException: Too many touch points reported
at javafx.scene.Scene$ScenePeerListener.touchEventNext(Scene.java:2626)
at com.sun.javafx.tk.quantum.GlassViewEventHandler$10.run(GlassViewEventHandler.java:985)
at com.sun.javafx.tk.quantum.GlassViewEventHandler$10.run(GlassViewEventHandler.java:964)
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.javafx.tk.quantum.GlassViewEventHandler.handleNextTouchEvent(GlassViewEventHandler.java:964)
at com.sun.glass.ui.View.handleNextTouchEvent(View.java:549)
at com.sun.glass.ui.View.notifyNextTouchEvent(View.java:1004)
at com.sun.glass.ui.TouchInputSupport.notifyNextTouchEvent(TouchInputSupport.java:117)
at com.sun.glass.ui.win.WinGestureSupport.notifyNextTouchEvent(WinGestureSupport.java:58)
at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
at com.sun.glass.ui.win.WinApplication.access$300(WinApplication.java:39)
at com.sun.glass.ui.win.WinApplication$4$1.run(WinApplication.java:112)
at java.lang.Thread.run(Thread.java:724)
一切正常,但在所有触摸事件期间都会显示此错误。
我应该如何正确实施警报对话框?谢谢。
警报对话框的实现是这样的 - http://tech.chitgoks.com/2013/06/19/how-to-create-alert-dialog-like-joptionpane-in-java-fx-2/。