home *** CD-ROM | disk | FTP | other *** search
- $$IF(Comments)
- //******************************************************************************
- // $$AppName$$Frame.java:
- //
- //******************************************************************************
- $$ENDIF
- import java.awt.*;
-
- $$IF(Comments)
- //==============================================================================
- // STANDALONE APPLICATION SUPPORT
- // This frame class acts as a top-level window in which the applet appears
- // when it's run as a standalone application.
- //==============================================================================
- $$ENDIF
- class $$AppName$$Frame extends Frame
- {
- $$IF(Comments)
- // $$AppName$$Frame constructor
- //--------------------------------------------------------------------------
- $$ENDIF
- public $$AppName$$Frame(String str)
- {
- $$IF(TODOComments)
- // TODO: Add additional construction code here
- $$ENDIF
- super (str);
- }
-
- $$IF(Comments)
- // The handleEvent() method receives all events generated within the frame
- // window. You can use this method to respond to window events. To respond
- // to events generated by menus, buttons, etc. or other controls in the
- // frame window but not managed by the applet, override the window's
- // action() method.
- //--------------------------------------------------------------------------
- $$ENDIF
- public boolean handleEvent(Event evt)
- {
- switch (evt.id)
- {
- $$IF(Comments)
- // Application shutdown (e.g. user chooses Close from the system menu).
- //------------------------------------------------------------------
- $$ENDIF
- case Event.WINDOW_DESTROY:
- $$IF(TODOComments)
- // TODO: Place additional clean up code here
- $$ENDIF
- dispose();
- System.exit(0);
- return true;
-
- default:
- return super.handleEvent(evt);
- }
- }
- }
-