| 386 | | win.addWindowListener(new WindowAdapter() { |
|---|
| 387 | | public void windowClosing(WindowEvent e) { |
|---|
| 388 | | System.exit(0); |
|---|
| 389 | | } |
|---|
| 390 | | }); |
|---|
| 391 | | |
|---|
| 392 | | win.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); |
|---|
| | 386 | if (System.getProperty("os.name").toLowerCase().indexOf("mac os x") >= 0) { |
|---|
| | 387 | win.setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE); |
|---|
| | 388 | } else { |
|---|
| | 389 | win.addWindowListener(new WindowAdapter() { |
|---|
| | 390 | public void windowClosing(WindowEvent e) { |
|---|
| | 391 | System.exit(0); |
|---|
| | 392 | } |
|---|
| | 393 | }); |
|---|
| | 394 | |
|---|
| | 395 | win.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); |
|---|
| | 396 | } |
|---|
| | 397 | |
|---|