--- /dev/null
+/*
+ * To change this template, choose Tools | Templates
+ * and open the template in the editor.
+ */
+
+/*
+ * PasswordTypingComponent.java
+ *
+ * Created on 1 juil. 2011, 14:02:10
+ */
+package com.axyus.swing.components;
+
+/**
+ *
+ * @author stephane.melois
+ */
+public class PasswordTypingComponent extends javax.swing.JDialog {
+
+ /** Creates new form PasswordTypingComponent */
+ public PasswordTypingComponent(java.awt.Frame parent, boolean modal) {
+ super(parent, modal);
+ initComponents();
+ pack();
+ setLocationRelativeTo(parent);
+ getRootPane().setDefaultButton(jButtonValider);
+ }
+
+ /** This method is called from within the constructor to
+ * initialize the form.
+ * WARNING: Do NOT modify this code. The content of this method is
+ * always regenerated by the Form Editor.
+ */
+ @SuppressWarnings("unchecked")
+ // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
+ private void initComponents() {
+
+ jLabel1 = new javax.swing.JLabel();
+ jButtonValider = new javax.swing.JButton();
+ jPasswordField1 = new javax.swing.JPasswordField();
+
+ setBounds(new java.awt.Rectangle(0, 0, 0, 0));
+
+ jLabel1.setText("Mot de passe :");
+
+ jButtonValider.setText("Valider");
+ jButtonValider.addActionListener(new java.awt.event.ActionListener() {
+ public void actionPerformed(java.awt.event.ActionEvent evt) {
+ jButtonValiderActionPerformed(evt);
+ }
+ });
+
+ javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
+ getContentPane().setLayout(layout);
+ layout.setHorizontalGroup(
+ layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(layout.createSequentialGroup()
+ .addContainerGap()
+ .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(layout.createSequentialGroup()
+ .addComponent(jPasswordField1, javax.swing.GroupLayout.PREFERRED_SIZE, 295, javax.swing.GroupLayout.PREFERRED_SIZE)
+ .addGap(18, 18, 18)
+ .addComponent(jButtonValider))
+ .addComponent(jLabel1))
+ .addContainerGap(58, Short.MAX_VALUE))
+ );
+ layout.setVerticalGroup(
+ layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
+ .addGroup(layout.createSequentialGroup()
+ .addContainerGap()
+ .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
+ .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
+ .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
+ .addComponent(jButtonValider)
+ .addComponent(jPasswordField1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
+ .addContainerGap(33, Short.MAX_VALUE))
+ );
+ }// </editor-fold>//GEN-END:initComponents
+
+ private void jButtonValiderActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButtonValiderActionPerformed
+ // TODO add your handling code here:
+ }//GEN-LAST:event_jButtonValiderActionPerformed
+
+ // Variables declaration - do not modify//GEN-BEGIN:variables
+ private javax.swing.JButton jButtonValider;
+ private javax.swing.JLabel jLabel1;
+ private javax.swing.JPasswordField jPasswordField1;
+ // End of variables declaration//GEN-END:variables
+
+ public char[] getPassword() {
+ return jPasswordField1.getPassword();
+ }
+
+ public javax.swing.JButton getButtonValider() {
+ return jButtonValider;
+ }
+
+}