I'm trying to simulate a wait in a java swing application, so basically it is like this: the user presses a button (an actionlistener has already been added), then the program basically pauses for 5 seconds while working in the background, and then, when 5 seconds have passed, appears window. (I know how to make a window). Mostly I ask, how do you work with a swing? Is there a command like pause () that can be called?
source share