如题 片段代码如下
JButton receivequest = new JButton("Receive Quests");
receivequest.addMouseListener(new MouseAdapter() {
public void mouseClicked(MouseEvent e){
try{
object.wait();
} catch (InterruptedException e) {e.printStackTrace();}
然后程序执行到.wait()就卡死了……JButton是个陷下去的状态……
JButton receivequest = new JButton("Receive Quests");
receivequest.addMouseListener(new MouseAdapter() {
public void mouseClicked(MouseEvent e){
try{
object.wait();
} catch (InterruptedException e) {e.printStackTrace();}
然后程序执行到.wait()就卡死了……JButton是个陷下去的状态……