Manage Legal Notices - Description
[habeas.git] / src / habeas / MainFrame.java
1 /*
2 * To change this license header, choose License Headers in Project Properties.
3 * To change this template file, choose Tools | Templates
4 * and open the template in the editor.
5 */
6 package habeas;
7
8 /**
9 *
10 * @author hari
11 */
12 public class MainFrame extends javax.swing.JFrame {
13
14 /**
15 * Creates new form MainFrame
16 */
17 public MainFrame() {
18 initComponents();
19 }
20
21 /**
22 * This method is called from within the constructor to initialize the form.
23 * WARNING: Do NOT modify this code. The content of this method is always
24 * regenerated by the Form Editor.
25 */
26 @SuppressWarnings("unchecked")
27 // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
28 private void initComponents() {
29
30 jMenuBar1 = new javax.swing.JMenuBar();
31 menuMaster = new javax.swing.JMenu();
32 menuClientMaster = new javax.swing.JMenuItem();
33 menuLawyerNotices = new javax.swing.JMenu();
34 menuCreateNotice = new javax.swing.JMenuItem();
35 menuManageNotices = new javax.swing.JMenuItem();
36 menuSettings = new javax.swing.JMenu();
37 menuDatabaseSettings = new javax.swing.JMenuItem();
38
39 setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
40 setTitle("Habeas - Law Office Manager");
41 setLocationByPlatform(true);
42
43 menuMaster.setMnemonic('M');
44 menuMaster.setText("Master");
45
46 menuClientMaster.setText("Client Master...");
47 menuClientMaster.addActionListener(new java.awt.event.ActionListener() {
48 public void actionPerformed(java.awt.event.ActionEvent evt) {
49 menuClientMasterActionPerformed(evt);
50 }
51 });
52 menuMaster.add(menuClientMaster);
53
54 jMenuBar1.add(menuMaster);
55
56 menuLawyerNotices.setMnemonic('L');
57 menuLawyerNotices.setText("Lawyer Notices");
58
59 menuCreateNotice.setMnemonic('C');
60 menuCreateNotice.setText("Create New...");
61 menuCreateNotice.addActionListener(new java.awt.event.ActionListener() {
62 public void actionPerformed(java.awt.event.ActionEvent evt) {
63 menuCreateNoticeActionPerformed(evt);
64 }
65 });
66 menuLawyerNotices.add(menuCreateNotice);
67
68 menuManageNotices.setMnemonic('M');
69 menuManageNotices.setText("Manage Notices...");
70 menuManageNotices.addActionListener(new java.awt.event.ActionListener() {
71 public void actionPerformed(java.awt.event.ActionEvent evt) {
72 menuManageNoticesActionPerformed(evt);
73 }
74 });
75 menuLawyerNotices.add(menuManageNotices);
76
77 jMenuBar1.add(menuLawyerNotices);
78
79 menuSettings.setMnemonic('S');
80 menuSettings.setText("Settings");
81
82 menuDatabaseSettings.setMnemonic('D');
83 menuDatabaseSettings.setText("Database...");
84 menuDatabaseSettings.addActionListener(new java.awt.event.ActionListener() {
85 public void actionPerformed(java.awt.event.ActionEvent evt) {
86 menuDatabaseSettingsActionPerformed(evt);
87 }
88 });
89 menuSettings.add(menuDatabaseSettings);
90
91 jMenuBar1.add(menuSettings);
92
93 setJMenuBar(jMenuBar1);
94
95 javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
96 getContentPane().setLayout(layout);
97 layout.setHorizontalGroup(
98 layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
99 .addGap(0, 586, Short.MAX_VALUE)
100 );
101 layout.setVerticalGroup(
102 layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
103 .addGap(0, 292, Short.MAX_VALUE)
104 );
105
106 pack();
107 }// </editor-fold>//GEN-END:initComponents
108
109 private void menuDatabaseSettingsActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_menuDatabaseSettingsActionPerformed
110 // TODO add your handling code here:
111 DatabaseSettingsDialog frm = new DatabaseSettingsDialog (this, true);
112 frm.setVisible(true);
113 }//GEN-LAST:event_menuDatabaseSettingsActionPerformed
114
115 private void menuClientMasterActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_menuClientMasterActionPerformed
116 // TODO add your handling code here:
117 ClientMasterDialog frm = new ClientMasterDialog (this, true);
118 frm.setVisible(true);
119 }//GEN-LAST:event_menuClientMasterActionPerformed
120
121 private void menuCreateNoticeActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_menuCreateNoticeActionPerformed
122 // TODO add your handling code here:
123 CreateNoticeDialog frm = new CreateNoticeDialog(this, true);
124 frm.setVisible(true);
125 }//GEN-LAST:event_menuCreateNoticeActionPerformed
126
127 private void menuManageNoticesActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_menuManageNoticesActionPerformed
128 // TODO add your handling code here:
129 ManageNoticesDialog frm = new ManageNoticesDialog(this, true);
130 frm.setVisible(true);
131 }//GEN-LAST:event_menuManageNoticesActionPerformed
132
133 /**
134 * @param args the command line arguments
135 */
136 public static void main(String args[]) {
137 /* Set the Nimbus look and feel */
138 //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
139 /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
140 * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html
141 */
142 try {
143 for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
144 if ("Nimbus".equals(info.getName())) {
145 javax.swing.UIManager.setLookAndFeel(info.getClassName());
146 break;
147 }
148 }
149 } catch (ClassNotFoundException ex) {
150 java.util.logging.Logger.getLogger(MainFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
151 } catch (InstantiationException ex) {
152 java.util.logging.Logger.getLogger(MainFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
153 } catch (IllegalAccessException ex) {
154 java.util.logging.Logger.getLogger(MainFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
155 } catch (javax.swing.UnsupportedLookAndFeelException ex) {
156 java.util.logging.Logger.getLogger(MainFrame.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
157 }
158 //</editor-fold>
159
160 /* Create and display the form */
161 java.awt.EventQueue.invokeLater(new Runnable() {
162 public void run() {
163 new MainFrame().setVisible(true);
164 }
165 });
166 }
167
168 // Variables declaration - do not modify//GEN-BEGIN:variables
169 private javax.swing.JMenuBar jMenuBar1;
170 private javax.swing.JMenuItem menuClientMaster;
171 private javax.swing.JMenuItem menuCreateNotice;
172 private javax.swing.JMenuItem menuDatabaseSettings;
173 private javax.swing.JMenu menuLawyerNotices;
174 private javax.swing.JMenuItem menuManageNotices;
175 private javax.swing.JMenu menuMaster;
176 private javax.swing.JMenu menuSettings;
177 // End of variables declaration//GEN-END:variables
178 }