ExitOnClosingWindowAdapter.java :  » Game » easy-game-client » com » croftsoft » core » gui » Java Open Source

Java Open Source » Game » easy game client 
easy game client » com » croftsoft » core » gui » ExitOnClosingWindowAdapter.java
     package com.croftsoft.core.gui;

     import java.awt.*;
     import java.awt.event.*;

     /*********************************************************************
     *
     * @version
     *   1998-11-01
     * @author
     *   <a href="http://www.CroftSoft.com/">David Wallace Croft</a>
     *********************************************************************/

     public class  ExitOnClosingWindowAdapter extends WindowAdapter
     //////////////////////////////////////////////////////////////////////
     //////////////////////////////////////////////////////////////////////
     {

     public void  windowClosing ( WindowEvent  windowEvent )
     //////////////////////////////////////////////////////////////////////
     {
       Window  window = windowEvent.getWindow ( );
       window.dispose ( );
       System.exit ( 0 );
     }

     //////////////////////////////////////////////////////////////////////
     //////////////////////////////////////////////////////////////////////
     }
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.