How it have to be done when I close console with X program would stop building? :)
In graphics it's window.setDefaultCloseOperation(JFrame.EXIT_ON_CLO SE);