JFileChooser scrollbar gives error

When I use JFileChooser, the first time I use its scroll bar, I get two or four copies of the following error message:

2016-01-08 18:37:17.706 java[14158:2289154] inOptions: { JavaCUIThumbStartKey = 0; "is.flipped" = 0; kCUIOrientationKey = kCUIOrientVertical; kCUIThumbProportionKey = "0.497863233089447"; max = 0; pressedpart = 0; state = normal; value = 0; widget = scrollbar; 

Here is an example of code that has this behavior:

 package tests; import java.awt.event.*; import javax.swing.*; public class SwingTest extends JFrame { public SwingTest() { JButton button = new JButton("Choose files"); add(button); button.addActionListener(new ActionListener() { public void actionPerformed(ActionEvent e) { chooseFile(); } }); } private void chooseFile() { JFileChooser chooser = new JFileChooser(); chooser.showOpenDialog(this); } public static void main(String[] args) { SwingTest test = new SwingTest(); test.pack(); test.setVisible(true); } } 

My Swing programs continue to work (mostly), but it bothers me. What causes this, and how can I avoid it?

Mac OS X 10.11.2 El Capitan
java version "1.8.0_66"
Java (TM) SE Runtime Environment (build 1.8.0_66-b17)
Java HotSpot (TM) 64-bit server VM (build 25.66-b17, mixed mode)
Eclipse IDE for Java Developers, Luna Service Release 2 (4.4.2)

+5
source share
1 answer

This is a closed (not reproducible) Java error:

It was closed because there was no test case, and not because it was not a mistake.

+1
source

Source: https://habr.com/ru/post/1240208/


All Articles