问题
I have a JFrame which pops up when the event occurs. I am having a functionality which when the event occurs the JFrame pops up and if we click on that Frame it will open the corresponding frame, but the issue is when I am not clicking the popped up frame when the event occurs, if another event comes its displays the frame in the taskbar in a blinking state but not in an open state, I want to display the frame as it is without the frame blinking in the taskbar???? Any suggestions???
回答1:
I already had such problem. try to call
frame.setAlwaysOnTop(true);
Then if you do not need this frame to appear on top always call
frame.setAlwaysOnTop(false);
来源:https://stackoverflow.com/questions/4023281/jframe-to-be-displayed-when-the-event-occurs