我想禁用report_unlock。有人可以解释一下吗?
private void report_unlockMouseClicked(java.awt.event.MouseEvent evt) {
String password=JOptionPane.showInputDialog("Enter the security key:");
if(password.contains("xxxxxxx")){
reports.setEnabled(true);
JOptionPane.showMessageDialog(null, "Login success ", "Report Unlock",JOptionPane.PLAIN_MESSAGE);
report_unlock.setEnabled(false);
}
else{
reports.setEnabled(false);
JOptionPane.showMessageDialog(null, "Login unsuccess ", "Report Unlock",JOptionPane.PLAIN_MESSAGE);
}