Use Swing dialog instead of System.out