home *** CD-ROM | disk | FTP | other *** search
/ Chip 2004 April / CMCD0404.ISO / Software / Freeware / Programare / Sharpdev / 099bsetup.exe / JavaApplication.xft < prev    next >
Extensible Markup Language  |  2003-09-21  |  5KB  |  147 lines

  1. <?xml version="1.0"?>
  2. <Template Originator="Gary Gray" Language="JAVA" Created="09/05/2001" LastModified="09/05/2001">
  3.     
  4.     <TemplateConfiguration>
  5.            <Name>${res:Templates.File.Java.JavaAWTApp.Name}</Name>
  6.            <Icon>Java.File.FullFile</Icon>
  7.            <Category>Java</Category>
  8.            <LanguageName>Java</LanguageName>
  9.            <Description>${res:Templates.File.Java.JavaAWTApp.Description}</Description>
  10.     </TemplateConfiguration>
  11.     
  12.     <TemplateFiles>
  13.            <File DefaultExtension=".java" DefaultName="Application">
  14.  
  15. <![CDATA[
  16. /*
  17.  * application.java
  18.  *
  19.  * created on ${Date} at ${Time}
  20.  */
  21.  
  22. public class application extends javax.swing.JFrame {
  23.  
  24.     /** Creates new form application */
  25.     public application() {
  26.         initComponents();
  27.     }
  28.  
  29.     /** This method is called from within the constructor to
  30.      * initialize the form.
  31.      * WARNING: Do NOT modify this code. The content of this method is
  32.      * always regenerated by the Form Editor.
  33.      */
  34.     private void initComponents() {//GEN-BEGIN:initComponents
  35.         menuBar = new javax.swing.JMenuBar();
  36.  
  37.         fileMenu = new javax.swing.JMenu();
  38.         fileMenu.setText("File");
  39.  
  40.         openMenuItem = new javax.swing.JMenuItem();
  41.         openMenuItem.setText("Open");
  42.  
  43.         fileMenu.add(openMenuItem);
  44.         saveMenuItem = new javax.swing.JMenuItem();
  45.         saveMenuItem.setText("Save");
  46.  
  47.         fileMenu.add(saveMenuItem);
  48.         saveAsMenuItem = new javax.swing.JMenuItem();
  49.         saveAsMenuItem.setText("Save As ...");
  50.  
  51.         fileMenu.add(saveAsMenuItem);
  52.         exitMenuItem = new javax.swing.JMenuItem();
  53.         exitMenuItem.setText("Exit");
  54.         exitMenuItem.addActionListener(new java.awt.event.ActionListener() {
  55.                                            public void actionPerformed(java.awt.event.ActionEvent evt) {
  56.                                                exitMenuItemActionPerformed(evt);
  57.                                            }
  58.                                        }
  59.                                       );
  60.  
  61.         fileMenu.add(exitMenuItem);
  62.         menuBar.add(fileMenu);
  63.         editMenu = new javax.swing.JMenu();
  64.         editMenu.setText("Edit");
  65.  
  66.         cutMenuItem = new javax.swing.JMenuItem();
  67.         cutMenuItem.setText("Cut");
  68.  
  69.         editMenu.add(cutMenuItem);
  70.         copyMenuItem = new javax.swing.JMenuItem();
  71.         copyMenuItem.setText("Copy");
  72.  
  73.         editMenu.add(copyMenuItem);
  74.         pasteMenuItem = new javax.swing.JMenuItem();
  75.         pasteMenuItem.setText("Paste");
  76.  
  77.         editMenu.add(pasteMenuItem);
  78.         deleteMenuItem = new javax.swing.JMenuItem();
  79.         deleteMenuItem.setText("Delete");
  80.  
  81.         editMenu.add(deleteMenuItem);
  82.         menuBar.add(editMenu);
  83.         helpMenu = new javax.swing.JMenu();
  84.         helpMenu.setText("Help");
  85.  
  86.         contentsMenuItem = new javax.swing.JMenuItem();
  87.         contentsMenuItem.setText("Contents");
  88.  
  89.         helpMenu.add(contentsMenuItem);
  90.         aboutMenuItem = new javax.swing.JMenuItem();
  91.         aboutMenuItem.setText("About");
  92.  
  93.         helpMenu.add(aboutMenuItem);
  94.         menuBar.add(helpMenu);
  95.         addWindowListener(new java.awt.event.WindowAdapter() {
  96.                               public void windowClosing(java.awt.event.WindowEvent evt) {
  97.                                   exitForm(evt);
  98.                               }
  99.                           }
  100.                          );
  101.  
  102.         setJMenuBar(menuBar);
  103.  
  104.         pack();
  105.     }//GEN-END:initComponents
  106.  
  107.     private void exitMenuItemActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_exitMenuItemActionPerformed
  108.         System.exit(0);
  109.     }//GEN-LAST:event_exitMenuItemActionPerformed
  110.  
  111.     /** Exit the Application */
  112.     private void exitForm(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_exitForm
  113.         System.exit(0);
  114.     }//GEN-LAST:event_exitForm
  115.  
  116.     /**
  117.     * param args the command line arguments
  118.     */
  119.     public static void main(String args[]) {
  120.         new application().show();
  121.     }
  122.  
  123.     // Variables declaration - do not modify//GEN-BEGIN:variables
  124.     private javax.swing.JMenuBar menuBar;
  125.     private javax.swing.JMenu fileMenu;
  126.     private javax.swing.JMenuItem openMenuItem;
  127.     private javax.swing.JMenuItem saveMenuItem;
  128.     private javax.swing.JMenuItem saveAsMenuItem;
  129.     private javax.swing.JMenuItem exitMenuItem;
  130.     private javax.swing.JMenu editMenu;
  131.     private javax.swing.JMenuItem cutMenuItem;
  132.     private javax.swing.JMenuItem copyMenuItem;
  133.     private javax.swing.JMenuItem pasteMenuItem;
  134.     private javax.swing.JMenuItem deleteMenuItem;
  135.     private javax.swing.JMenu helpMenu;
  136.     private javax.swing.JMenuItem contentsMenuItem;
  137.     private javax.swing.JMenuItem aboutMenuItem;
  138.     // End of variables declaration//GEN-END:variables
  139.  
  140. }]]>
  141.         </File>        
  142.     </TemplateFiles>
  143.     
  144.     <FileOptions/>
  145.     
  146. </Template>
  147.