Compare commits

...

2 Commits

Author SHA1 Message Date
e84ad59e10 Merge pull request 'jffConnexion et jffProfession différence' (#12) from jave.Emile into main
Reviewed-on: #12
2025-03-12 11:57:02 +01:00
002e6597c6 jffConnexion et jffProfession différence
entre médecin et visiteur medical
2025-03-12 11:56:00 +01:00
3 changed files with 17 additions and 4 deletions

View File

@ -9,12 +9,13 @@ package presentation;
* @author emile.lalorcey * @author emile.lalorcey
*/ */
public class jffConnexion extends javax.swing.JFrame { public class jffConnexion extends javax.swing.JFrame {
int profession;
/** /**
* Creates new form jffConnexion * Creates new form jffConnexion
*/ */
public jffConnexion() { public jffConnexion(int indice) {
initComponents(); initComponents();
this.profession = indice;
} }
/** /**
@ -191,7 +192,7 @@ public class jffConnexion extends javax.swing.JFrame {
/* Create and display the form */ /* Create and display the form */
java.awt.EventQueue.invokeLater(new Runnable() { java.awt.EventQueue.invokeLater(new Runnable() {
public void run() { public void run() {
new jffConnexion().setVisible(true); new jffConnexion(1).setVisible(true);
} }
}); });
} }

View File

@ -95,6 +95,9 @@
<Properties> <Properties>
<Property name="text" type="java.lang.String" value="visiteur medical"/> <Property name="text" type="java.lang.String" value="visiteur medical"/>
</Properties> </Properties>
<Events>
<EventHandler event="actionPerformed" listener="java.awt.event.ActionListener" parameters="java.awt.event.ActionEvent" handler="jBvisiteurMedicalActionPerformed"/>
</Events>
</Component> </Component>
<Component class="javax.swing.JButton" name="jBquitter"> <Component class="javax.swing.JButton" name="jBquitter">
<Properties> <Properties>

View File

@ -45,6 +45,11 @@ public class jffProfession extends javax.swing.JFrame {
}); });
jBvisiteurMedical.setText("visiteur medical"); jBvisiteurMedical.setText("visiteur medical");
jBvisiteurMedical.addActionListener(new java.awt.event.ActionListener() {
public void actionPerformed(java.awt.event.ActionEvent evt) {
jBvisiteurMedicalActionPerformed(evt);
}
});
jBquitter.setIcon(new javax.swing.ImageIcon(getClass().getResource("/img/quitter.png"))); // NOI18N jBquitter.setIcon(new javax.swing.ImageIcon(getClass().getResource("/img/quitter.png"))); // NOI18N
jBquitter.setText("Quitter"); jBquitter.setText("Quitter");
@ -103,13 +108,17 @@ public class jffProfession extends javax.swing.JFrame {
}// </editor-fold>//GEN-END:initComponents }// </editor-fold>//GEN-END:initComponents
private void jBpraticienActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jBpraticienActionPerformed private void jBpraticienActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jBpraticienActionPerformed
// TODO add your handling code here: new jffConnexion(0).setVisible(true);
}//GEN-LAST:event_jBpraticienActionPerformed }//GEN-LAST:event_jBpraticienActionPerformed
private void jBquitterActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jBquitterActionPerformed private void jBquitterActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jBquitterActionPerformed
System.exit(0); System.exit(0);
}//GEN-LAST:event_jBquitterActionPerformed }//GEN-LAST:event_jBquitterActionPerformed
private void jBvisiteurMedicalActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jBvisiteurMedicalActionPerformed
new jffConnexion(1).setVisible(true);
}//GEN-LAST:event_jBvisiteurMedicalActionPerformed
/** /**
* @param args the command line arguments * @param args the command line arguments
*/ */