|
| 1 | + |
| 2 | +import java.awt.Toolkit; |
| 3 | + |
| 4 | +/* |
| 5 | + * To change this license header, choose License Headers in Project Properties. |
| 6 | + * To change this template file, choose Tools | Templates |
| 7 | + * and open the template in the editor. |
| 8 | + */ |
| 9 | + |
| 10 | +/** |
| 11 | + * |
| 12 | + * @author root |
| 13 | + */ |
| 14 | +public class About_Us_Page extends javax.swing.JFrame { |
| 15 | + |
| 16 | + /** |
| 17 | + * Creates new form About_Us_Page |
| 18 | + */ |
| 19 | + public About_Us_Page() { |
| 20 | + initComponents(); |
| 21 | + setIcon(); |
| 22 | + setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE); |
| 23 | + } |
| 24 | + |
| 25 | + /** |
| 26 | + * This method is called from within the constructor to initialize the form. |
| 27 | + * WARNING: Do NOT modify this code. The content of this method is always |
| 28 | + * regenerated by the Form Editor. |
| 29 | + */ |
| 30 | + @SuppressWarnings("unchecked") |
| 31 | + // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents |
| 32 | + private void initComponents() { |
| 33 | + |
| 34 | + jLabel1 = new javax.swing.JLabel(); |
| 35 | + jLabel2 = new javax.swing.JLabel(); |
| 36 | + jButton1 = new javax.swing.JButton(); |
| 37 | + jButton2 = new javax.swing.JButton(); |
| 38 | + |
| 39 | + setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE); |
| 40 | + setTitle("PassBox | About Us"); |
| 41 | + setResizable(false); |
| 42 | + |
| 43 | + jLabel1.setFont(new java.awt.Font("Yu Gothic UI", 1, 20)); // NOI18N |
| 44 | + jLabel1.setText("This software is developed by Ismail Taşdelen."); |
| 45 | + |
| 46 | + jLabel2.setFont(new java.awt.Font("Yu Gothic UI", 1, 30)); // NOI18N |
| 47 | + jLabel2.setText("PassBox"); |
| 48 | + |
| 49 | + jButton1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/logo/PassBox.png"))); // NOI18N |
| 50 | + |
| 51 | + jButton2.setFont(new java.awt.Font("Tahoma", 1, 11)); // NOI18N |
| 52 | + jButton2.setIcon(new javax.swing.ImageIcon(getClass().getResource("/ico/turnback_ico.png"))); // NOI18N |
| 53 | + jButton2.setText("Turn Back"); |
| 54 | + jButton2.addActionListener(new java.awt.event.ActionListener() { |
| 55 | + public void actionPerformed(java.awt.event.ActionEvent evt) { |
| 56 | + jButton2ActionPerformed(evt); |
| 57 | + } |
| 58 | + }); |
| 59 | + |
| 60 | + javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane()); |
| 61 | + getContentPane().setLayout(layout); |
| 62 | + layout.setHorizontalGroup( |
| 63 | + layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) |
| 64 | + .addGroup(layout.createSequentialGroup() |
| 65 | + .addContainerGap(91, Short.MAX_VALUE) |
| 66 | + .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) |
| 67 | + .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() |
| 68 | + .addComponent(jButton1, javax.swing.GroupLayout.PREFERRED_SIZE, 338, javax.swing.GroupLayout.PREFERRED_SIZE) |
| 69 | + .addGap(128, 128, 128)) |
| 70 | + .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() |
| 71 | + .addComponent(jLabel2, javax.swing.GroupLayout.PREFERRED_SIZE, 124, javax.swing.GroupLayout.PREFERRED_SIZE) |
| 72 | + .addGap(225, 225, 225)) |
| 73 | + .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() |
| 74 | + .addComponent(jLabel1) |
| 75 | + .addGap(78, 78, 78)) |
| 76 | + .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() |
| 77 | + .addComponent(jButton2) |
| 78 | + .addGap(229, 229, 229)))) |
| 79 | + ); |
| 80 | + layout.setVerticalGroup( |
| 81 | + layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) |
| 82 | + .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() |
| 83 | + .addContainerGap() |
| 84 | + .addComponent(jButton1, javax.swing.GroupLayout.PREFERRED_SIZE, 321, javax.swing.GroupLayout.PREFERRED_SIZE) |
| 85 | + .addGap(1, 1, 1) |
| 86 | + .addComponent(jLabel2) |
| 87 | + .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) |
| 88 | + .addComponent(jLabel1) |
| 89 | + .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) |
| 90 | + .addComponent(jButton2, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) |
| 91 | + .addContainerGap()) |
| 92 | + ); |
| 93 | + |
| 94 | + pack(); |
| 95 | + }// </editor-fold>//GEN-END:initComponents |
| 96 | + |
| 97 | + private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton2ActionPerformed |
| 98 | + // TODO add your handling code here: |
| 99 | + this.setVisible(false); |
| 100 | + }//GEN-LAST:event_jButton2ActionPerformed |
| 101 | + |
| 102 | + /** |
| 103 | + * @param args the command line arguments |
| 104 | + */ |
| 105 | + public static void main(String args[]) { |
| 106 | + /* Set the Nimbus look and feel */ |
| 107 | + //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> |
| 108 | + /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. |
| 109 | + * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html |
| 110 | + */ |
| 111 | + try { |
| 112 | + for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) { |
| 113 | + if ("Nimbus".equals(info.getName())) { |
| 114 | + javax.swing.UIManager.setLookAndFeel(info.getClassName()); |
| 115 | + break; |
| 116 | + } |
| 117 | + } |
| 118 | + } catch (ClassNotFoundException ex) { |
| 119 | + java.util.logging.Logger.getLogger(About_Us_Page.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); |
| 120 | + } catch (InstantiationException ex) { |
| 121 | + java.util.logging.Logger.getLogger(About_Us_Page.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); |
| 122 | + } catch (IllegalAccessException ex) { |
| 123 | + java.util.logging.Logger.getLogger(About_Us_Page.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); |
| 124 | + } catch (javax.swing.UnsupportedLookAndFeelException ex) { |
| 125 | + java.util.logging.Logger.getLogger(About_Us_Page.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); |
| 126 | + } |
| 127 | + //</editor-fold> |
| 128 | + |
| 129 | + /* Create and display the form */ |
| 130 | + java.awt.EventQueue.invokeLater(new Runnable() { |
| 131 | + public void run() { |
| 132 | + new About_Us_Page().setVisible(true); |
| 133 | + } |
| 134 | + }); |
| 135 | + } |
| 136 | + |
| 137 | + // Variables declaration - do not modify//GEN-BEGIN:variables |
| 138 | + private javax.swing.JButton jButton1; |
| 139 | + private javax.swing.JButton jButton2; |
| 140 | + private javax.swing.JLabel jLabel1; |
| 141 | + private javax.swing.JLabel jLabel2; |
| 142 | + // End of variables declaration//GEN-END:variables |
| 143 | + |
| 144 | + private void setIcon() { |
| 145 | + setIconImage(Toolkit.getDefaultToolkit().getImage(getClass().getResource("passbox_ico.png"))); |
| 146 | + } |
| 147 | +} |
0 commit comments